From 3e0c06ffc9c8e32dfeb433490f4e23b59144a48d Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Mon, 6 Jan 2003 20:46:54 +0000 Subject: selectInstallClass now automatically detect if an existing install is there, and propose update or install based on this --- perl-install/install_steps.pm | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) (limited to 'perl-install/install_steps.pm') diff --git a/perl-install/install_steps.pm b/perl-install/install_steps.pm index 7f20275cc..cc6bf5c9a 100644 --- a/perl-install/install_steps.pm +++ b/perl-install/install_steps.pm @@ -121,9 +121,7 @@ sub selectKeyboard { } #------------------------------------------------------------------------------ sub acceptLicence {} -sub selectPath {} -#------------------------------------------------------------------------------ -sub selectInstallClass {} + #------------------------------------------------------------------------------ sub setupSCSI { my ($o) = @_; @@ -131,6 +129,17 @@ sub setupSCSI { modules::load_ide(); modules::load_category('bus/firewire'); modules::load_category('disk/scsi|hardware_raid'); + + install_any::getHds($o, $o); +} + +#------------------------------------------------------------------------------ +sub selectInstallClass { + if ($o->{partitioning}{use_existing_root} || $o->{isUpgrade}) { + # either one root is defined (and all is ok), or we take the first one we find + my $p = fsedit::get_root_($o->{fstab}) || first(install_any::find_root_parts($o->{fstab}, $o->{prefix})) or die; + install_any::use_root_part($o->{all_hds}, $p, $o->{prefix}); + } } #------------------------------------------------------------------------------ @@ -183,13 +192,6 @@ sub doPartitionDisksAfter { sub doPartitionDisks { my ($o) = @_; - install_any::getHds($o); - - if ($o->{partitioning}{use_existing_root} || $o->{isUpgrade}) { - # either one root is defined (and all is ok), or we take the first one we find - my $p = fsedit::get_root_($o->{fstab}) || first(install_any::find_root_parts($o->{fstab}, $o->{prefix})) or die; - install_any::use_root_part($o->{all_hds}, $p, $o->{prefix}); - } if ($o->{partitioning}{auto_allocate}) { fsedit::auto_allocate($o->{all_hds}, $o->{partitions}); } -- cgit v1.2.1