diff options
-rw-r--r-- | perl-install/bootloader.pm | 7 | ||||
-rw-r--r-- | perl-install/install_steps_interactive.pm | 36 | ||||
-rw-r--r-- | rescue/list.ppc | 3 | ||||
-rwxr-xr-x | update_kernel | 12 |
4 files changed, 35 insertions, 23 deletions
diff --git a/perl-install/bootloader.pm b/perl-install/bootloader.pm index da26c5672..a7758e897 100644 --- a/perl-install/bootloader.pm +++ b/perl-install/bootloader.pm @@ -504,9 +504,12 @@ sub install_yaboot($$$) { } log::l("Installing boot loader..."); my $f = "$prefix/tmp/of_boot_dev"; - my $of_dev = get_of_dev($prefix, $lilo->{boot}); - output($f, "$of_dev\n"); + my $of_dev = get_of_dev($prefix, $lilo->{boot}); + output($f, "$of_dev\n"); $::testing and return; + if (defined $install_steps_interactive::new_bootstrap) { + run_program::run("hformat", "$lilo->{boot}") or die "hformat failed"; + } run_program::rooted($prefix, "/sbin/ybin", "2>", "/tmp/.error") or die "ybin failed"; unlink "$prefix/tmp/.error"; } diff --git a/perl-install/install_steps_interactive.pm b/perl-install/install_steps_interactive.pm index 20bcd80de..8a9ddf769 100644 --- a/perl-install/install_steps_interactive.pm +++ b/perl-install/install_steps_interactive.pm @@ -3,7 +3,7 @@ package install_steps_interactive; # $Id$ use diagnostics; use strict; -use vars qw(@ISA); +use vars qw(@ISA $new_bootstrap); @ISA = qw(install_steps); @@ -336,23 +336,23 @@ Do you agree to loose all the partitions? _("DiskDrake failed to read correctly the partition table. Continue at your own risk!")); - if (arch() =~ /ppc/ && !$::expert) { #- need to make bootstrap part if recommended install - thx Pixel ;^) - if (defined $partition_table_mac::bootstrap_part) { - #- don't do anything if we've got the bootstrap setup - #- otherwise, go ahead and create one somewhere in the drive free space - } else { - if (defined $partition_table_mac::freepart_start && $partition_table_mac::freepart_size >= 1) { - my ($hd) = $partition_table_mac::freepart_device; - log::l("creating bootstrap partition on drive /dev/$hd->{device}, block $partition_table_mac::freepart_start"); - $partition_table_mac::bootstrap_part = $partition_table_mac::freepart_part; - log::l("bootstrap now at $partition_table_mac::bootstrap_part"); - fsedit::add($hd, { start => $partition_table_mac::freepart_start, size => 1 << 11, type => 0x401, mntpoint => '' }, $o->{hds}, { force => 1, primaryOrExtended => 'Primary' }); - run_program::run("hformat", $partition_table_mac::bootstrap_part) or die "hformat of $partition_table_mac::bootstrap_part failed"; - } else { - die "no free space for 1MB bootstrap"; - } - } + if (arch() =~ /ppc/) { #- need to make bootstrap part if recommended install - thx Pixel ;^) + if (defined $partition_table_mac::bootstrap_part) { + #- don't do anything if we've got the bootstrap setup + #- otherwise, go ahead and create one somewhere in the drive free space + } else { + if (defined $partition_table_mac::freepart_start && $partition_table_mac::freepart_size >= 1) { + my ($hd) = $partition_table_mac::freepart_device; + log::l("creating bootstrap partition on drive /dev/$hd->{device}, block $partition_table_mac::freepart_start"); + $partition_table_mac::bootstrap_part = $partition_table_mac::freepart_part; + log::l("bootstrap now at $partition_table_mac::bootstrap_part"); + fsedit::add($hd, { start => $partition_table_mac::freepart_start, size => 1 << 11, type => 0x401, mntpoint => '' }, $o->{hds}, { force => 1, primaryOrExtended => 'Primary' }); + $new_bootstrap = 1; + } else { + die "no free space for 1MB bootstrap"; + } } + } if ($o->{isUpgrade}) { # either one root is defined (and all is ok), or we take the first one we find @@ -1027,7 +1027,7 @@ try to force installation even if that destroys the first partition?")); my $of_boot = cat_("$o->{prefix}/tmp/of_boot_dev") || die "Can't open $o->{prefix}/tmp/of_boot_dev"; chop($of_boot); unlink "$o->{prefix}/tmp/.error"; - $o->ask_warn('', _("You may need to change your Open Firmware boot-device to\n enable the bootloader. If you don't see the bootloader prompt at\n reboot, hold down Command-Option-O-F at reboot and enter:\n setenv boot-device $of_boot,\\\\tbxi\n Then type: shut-down\nAt your next boot you should see the bootloader prompt.")); + $o->ask_warn('', _("You may need to change your Open Firmware boot-device to\n enable the bootloader. If you don't see the bootloader prompt at\n reboot, hold down Command-Option-O-F at reboot and enter:\n setenv boot-device $of_boot,\\\\yaboot\n Then type: shut-down\nAt your next boot you should see the bootloader prompt.")); } } } diff --git a/rescue/list.ppc b/rescue/list.ppc index 47e1a2b90..3041c21b2 100644 --- a/rescue/list.ppc +++ b/rescue/list.ppc @@ -2,9 +2,10 @@ /usr/lib/perl5/site_perl/5.6.0/ppc-linux/packdrake.pm /sbin/pdisk /sbin/ybin +/sbin/mkofboot /usr/local/lib/yaboot/ofboot /usr/local/lib/yaboot/yaboot -/usr/local/sbin/mkofboot /usr/local/sbin/ofpath /sbin/nvsetenv /dev/nvram +/usr/bin/hformat diff --git a/update_kernel b/update_kernel index 2f5c51e52..7d4002b51 100755 --- a/update_kernel +++ b/update_kernel @@ -68,10 +68,18 @@ echo "done." NETWORK_MODULES=" $NETWORK_DRIVERS" CDROM_MODULES=" $CD_DRIVERS" -HD_MODULES=" $DOSMODULES $SCSI_DRIVERS $DISK_DRIVERS loop.o isofs.o reiserfs.o" +if [ "$ARCH" == "ppc" ]; then + HD_MODULES=" $DOSMODULES $SCSI_DRIVERS $DISK_DRIVERS loop.o isofs.o reiserfs.o hfs.o" +else + HD_MODULES=" $DOSMODULES $SCSI_DRIVERS $DISK_DRIVERS loop.o isofs.o reiserfs.o" +fi PCMCIA_MODULES=" $DOSMODULES $PCMCIA_DRIVERS" BIG_MODULES=" $BIG_DRIVERS" -ALL_MODULES=" $DOSMODULES $ALL_DRIVERS loop.o isofs.o reiserfs.o" +if [ "$ARCH" == "ppc" ]; then + ALL_MODULES=" $DOSMODULES $ALL_DRIVERS loop.o isofs.o reiserfs.o hfs.o" +else + ALL_MODULES=" $DOSMODULES $ALL_DRIVERS loop.o isofs.o reiserfs.o" +fi NOT_USEFULL_IN_STAGE1="nls_*.o parport_probe.o raid*.o serial.o smbfs.o usb-*.o" GENERIC_MODULES="isa-pnp.o floppy.o" |