aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/Iurt/Chroot.pm9
1 files changed, 8 insertions, 1 deletions
diff --git a/lib/Iurt/Chroot.pm b/lib/Iurt/Chroot.pm
index 8509124..82840a1 100644
--- a/lib/Iurt/Chroot.pm
+++ b/lib/Iurt/Chroot.pm
@@ -375,7 +375,12 @@ sub clean_chroot_tmp {
foreach my $m ('proc', 'dev/pts', 'urpmi_medias', 'var/cache/icecream') {
if (system("$sudo umount $d/$m &>/dev/null") && $run->{verbose} > 1) {
- plog("ERROR: could not umount /$m in $d/");
+ plog("ERROR: could not umount /$m in $d/");
+ # FIXME: <mrl> We can't go on, otherelse we will remove something
+ # that we shouldn't. But for that, we should:
+ # a) Check for all mount-points inside the chroot
+ # b) Try to unmount only the needed ones, otherelse the errors
+ # can be misleading.
}
}
@@ -523,6 +528,7 @@ sub build_chroot {
@{$opt->{packages}}
);
+ # FIXME: <mrl> A proper warn could be given here, instead of aborting silently.
if (-f "$tmp_chroot/bin/rpm") {
system($sudo, 'sh', '-c', "chroot $tmp_chroot rpm -qa --qf '\%{NAME}-\%{VERSION}-\%{RELEASE}.\%{ARCH}.rpm\n' > $tmp_chroot/var/log/qa");
#
@@ -535,6 +541,7 @@ sub build_chroot {
sudo($run, $config, "--mkdir", "$tmp_chroot/home/builder/rpm/$p");
}
system($sudo, 'chown', '-R', 499, "$tmp_chroot/home/builder");
+ # FIXME: <mrl> Be careful! Damn ugly hack right below!
sudo($run, $config, "--rm", "$tmp_chroot/var/lib/rpm/__db*");
system("$sudo umount $tmp_chroot/proc &> /dev/null");
system("$sudo umount $tmp_chroot/dev/pts &> /dev/null");