summaryrefslogtreecommitdiffstats
path: root/lib/MDV
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.com>2009-05-26 14:33:53 +0000
committerOlivier Blin <oblin@mandriva.com>2009-05-26 14:33:53 +0000
commit9fa9853f69095e001a7b7b57a7e2b53e84dc0154 (patch)
treed55d72b9012c4d850c2f6afd58a16cc725169663 /lib/MDV
parent90f36dface61fc5194f451bc07de77bb8c8e9866 (diff)
downloaddraklive-9fa9853f69095e001a7b7b57a7e2b53e84dc0154.tar
draklive-9fa9853f69095e001a7b7b57a7e2b53e84dc0154.tar.gz
draklive-9fa9853f69095e001a7b7b57a7e2b53e84dc0154.tar.bz2
draklive-9fa9853f69095e001a7b7b57a7e2b53e84dc0154.tar.xz
draklive-9fa9853f69095e001a7b7b57a7e2b53e84dc0154.zip
make sure /proc and /sys are available when building initrd (useful to see error messages at least, from Paulo Ricardo Zanoni)
Diffstat (limited to 'lib/MDV')
-rw-r--r--lib/MDV/Draklive/Initrd.pm4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/MDV/Draklive/Initrd.pm b/lib/MDV/Draklive/Initrd.pm
index da112a3..84d81f3 100644
--- a/lib/MDV/Draklive/Initrd.pm
+++ b/lib/MDV/Draklive/Initrd.pm
@@ -274,7 +274,11 @@ sub create_classical_initrd {
my $vmlinuz_long = '/boot/vmlinuz-' . $kernel;
my $vmlinuz_short = '/boot/vmlinuz';
my $root = $live->get_system_root;
+ run_({}, 'mount', '-t', 'proc', '/proc', $root . '/proc');
+ run_({}, 'mount', '-t', 'sysfs', '/sys', $root . '/sys');
run_({ root => $root }, 'mkinitrd', '-v', '-f', $initrd_long, $kernel);
+ run_({}, 'umount', $root . '/sys');
+ run_({}, 'umount', $root . '/proc');
symlinkf(basename($initrd_long), $root . $initrd_short);
symlinkf(basename($vmlinuz_long), $root . $vmlinuz_short);
if ($live->{system}{vga_mode} && $live->{system}{splash} ne 'no') {