aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Iurt/Urpmi.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Iurt/Urpmi.pm')
-rw-r--r--lib/Iurt/Urpmi.pm14
1 files changed, 13 insertions, 1 deletions
diff --git a/lib/Iurt/Urpmi.pm b/lib/Iurt/Urpmi.pm
index 0f084c9..aec4f87 100644
--- a/lib/Iurt/Urpmi.pm
+++ b/lib/Iurt/Urpmi.pm
@@ -566,7 +566,19 @@ sub install_dynamic_buildrequires {
return 1;
}
- my $nosrc = $srpm =~ s/src.rpm$/buildreqs.nosrc.rpm/r;
+ if (!perform_command(qq(chroot $chroot_tmp su $luser -c "rpmspec -q --qf %{NVR}.src.rpm --srpm /home/$luser/rpmbuild/SPECS/$spec > /home/$luser/rpmbuild/SPECS/$spec.srpm_name"),
+ $run, $config,
+ use_iurt_root_command => 1,
+ hash => "identify_$srpm")) {
+ plog("ERROR: failed to get the name of the generated src.rpm");
+ return;
+ }
+ my $new_srpm = cat_("$chroot_tmp/home/$luser/rpmbuild/SPECS/$spec.srpm_name");
+ if (!$new_srpm) {
+ plog("ERROR: failed to get the name of the generated src.rpm");
+ return;
+ }
+ my $nosrc = $new_srpm =~ s/src.rpm$/buildreqs.nosrc.rpm/r;
while (1) {
# There is no way with perform_command to get the actual error code.