diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2004-01-07 16:08:41 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2004-01-07 16:08:41 +0000 |
commit | 0bc655c8b88c9a2c92db66dc8b259c56ec53ee49 (patch) | |
tree | 8e42cc5a29d8ffed9f62f0766cebc1fcdc97fc34 /perl-install/bootloader.pm | |
parent | 231ceccbb97bb1f62c223cc5bf33046f67f1021b (diff) | |
download | drakx-0bc655c8b88c9a2c92db66dc8b259c56ec53ee49.tar drakx-0bc655c8b88c9a2c92db66dc8b259c56ec53ee49.tar.gz drakx-0bc655c8b88c9a2c92db66dc8b259c56ec53ee49.tar.bz2 drakx-0bc655c8b88c9a2c92db66dc8b259c56ec53ee49.tar.xz drakx-0bc655c8b88c9a2c92db66dc8b259c56ec53ee49.zip |
pass --splash <resolution> to mkinitrd
(so that make-boot-splash doesn't rely on lilo.conf or menu.lst)
Diffstat (limited to 'perl-install/bootloader.pm')
-rw-r--r-- | perl-install/bootloader.pm | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/perl-install/bootloader.pm b/perl-install/bootloader.pm index 6e86c0bef..25c352e5f 100644 --- a/perl-install/bootloader.pm +++ b/perl-install/bootloader.pm @@ -52,14 +52,19 @@ sub get_label { } sub mkinitrd { - my ($kernelVersion, $initrdImage) = @_; + my ($kernelVersion, $initrdImage, $o_vga) = @_; $::testing || -e "$::prefix/$initrdImage" and return 1; my $loop_boot = loopback::prepare_boot(); + my $o_resolution = $o_vga && do { + require Xconfig::resolution_and_depth; + my $res = Xconfig::resolution_and_depth::from_bios($o_vga); + $res && $res->{X}; + }; modules::load('loop'); - if (!run_program::rooted($::prefix, "mkinitrd", "-v", "-f", $initrdImage, "--ifneeded", $kernelVersion)) { + if (!run_program::rooted($::prefix, "mkinitrd", "-v", "-f", $initrdImage, "--ifneeded", $kernelVersion, if_($o_resolution, '--splash' => $o_resolution))) { unlink("$::prefix/$initrdImage"); die "mkinitrd failed"; } @@ -278,7 +283,7 @@ sub add_kernel { symlinkf("vmlinuz-$version", "$::prefix/boot/vmlinuz$ext") ? $ext : "-$version"); my $initrd = "/boot/initrd-$version.img"; - mkinitrd($version, $initrd) or undef $initrd; + mkinitrd($version, $initrd, $v->{vga}) or undef $initrd; if ($initrd && $ext ne "-$version") { $initrd = "/boot/initrd$ext.img"; symlinkf("initrd-$version.img", "$::prefix$initrd") or cp_af("$::prefix/boot/initrd-$version.img", "$::prefix$initrd"); @@ -384,7 +389,7 @@ sub configure_entry { if ($specific_version) { $entry->{initrd} or $entry->{initrd} = "/boot/initrd-$specific_version.img"; - mkinitrd($specific_version, $entry->{initrd}) or undef $entry->{initrd}; + mkinitrd($specific_version, $entry->{initrd}, $entry->{vga}) or undef $entry->{initrd}; } } $entry; |