From f5b6d853f3ed37cd88f4797f7bfb41fef7dd81ce Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Thu, 27 Jan 2000 22:15:55 +0000 Subject: no_comment --- perl-install/install_steps.pm | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) (limited to 'perl-install/install_steps.pm') diff --git a/perl-install/install_steps.pm b/perl-install/install_steps.pm index c8bcc2a64..84c4918c5 100644 --- a/perl-install/install_steps.pm +++ b/perl-install/install_steps.pm @@ -613,7 +613,13 @@ sub readBootloaderConfigBeforeInstall { sub setupBootloaderBefore { my ($o) = @_; - if (arch() =~ /^sparc/) { + if (arch() =~ /alpha/) { + if (my $dev = fsedit::get_root($o->{fstab})) { + $o->{bootloader}{boot} ||= "/dev/$dev->{rootDevice}"; + $o->{bootloader}{root} ||= "/dev/$dev->{device}"; + $o->{bootloader}{part_nb} ||= first($dev->{device} =~ /(\d+)/); + } + } elsif (arch() =~ /^sparc/) { require silo; silo::suggest($o->{prefix}, $o->{bootloader}, $o->{hds}, $o->{fstab}, install_any::kernelVersion()); } else { @@ -627,7 +633,18 @@ sub setupBootloader($) { my ($o) = @_; return if $::g_auto_install; - if (arch() =~ /^sparc/) { + if (arch() =~ /alpha/) { + return if $::testing; + my $b = $o->{bootloader}; + $b->{boot} or $o->ask_warn('', "Can't install aboot, not a bsd disklabel"), return; + + run_program::rooted($o->{prefix}, "swriteboot", $b->{boot}, "/boot/bootlx"); + run_program::rooted($o->{prefix}, "abootconf", $b->{boot}, $b->{part_nb}); + + output "$o->{prefix}/etc/aboot.conf", + map_index { "$::i:$b->{part_nb}$_ root=$b->{root} $b->{perImageAppend}\n" } + map { /$o->{prefix}(.*)/ } eval { glob_("$o->{prefix}/boot/vmlinux*") }; + } elsif (arch() =~ /^sparc/) { silo::install($o->{prefix}, $o->{bootloader}); } else { lilo::install($o->{prefix}, $o->{bootloader}); -- cgit v1.2.1