diff options
author | Pascal Rigaux <pixel@mandriva.com> | 1999-08-23 13:01:55 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 1999-08-23 13:01:55 +0000 |
commit | 673787cbdab4a47b0b3cb987866c57704d7bdee9 (patch) | |
tree | 32255ffefd59a78b5e798e18a4f790b032449c1b /perl-install/install_any.pm | |
parent | 57ea24fde5f61bb54bee187847f1119b5c79f9f3 (diff) | |
download | drakx-673787cbdab4a47b0b3cb987866c57704d7bdee9.tar drakx-673787cbdab4a47b0b3cb987866c57704d7bdee9.tar.gz drakx-673787cbdab4a47b0b3cb987866c57704d7bdee9.tar.bz2 drakx-673787cbdab4a47b0b3cb987866c57704d7bdee9.tar.xz drakx-673787cbdab4a47b0b3cb987866c57704d7bdee9.zip |
no_comment
Diffstat (limited to 'perl-install/install_any.pm')
-rw-r--r-- | perl-install/install_any.pm | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/perl-install/install_any.pm b/perl-install/install_any.pm index 1233b6e9e..9cf68eb7b 100644 --- a/perl-install/install_any.pm +++ b/perl-install/install_any.pm @@ -6,7 +6,7 @@ use vars qw(@ISA %EXPORT_TAGS @EXPORT_OK); @ISA = qw(Exporter); %EXPORT_TAGS = ( - all => [ qw(versionString getNextStep doSuspend spawnSync spawnShell) ], + all => [ qw(versionString getNextStep doSuspend spawnSync spawnShell addToBeDone) ], ); @EXPORT_OK = map { @$_ } values %EXPORT_TAGS; @@ -26,7 +26,7 @@ sub imageGetFile { } sub versionString { - my $kernel = $::o->{packages}->{kernel}; + my $kernel = $::o->{packages}{kernel}; $kernel && $kernel->{header} or die "I couldn't find the kernel package!"; c::headerGetEntry($kernel->{header}, 'version') . "-" . @@ -35,11 +35,9 @@ sub versionString { sub getNextStep { - my ($lastStep) = @_; - - $::o->{direction} = 1; - - return $::o->{lastChoice} = $::o->{steps}->{$lastStep}->{next}; + my ($s) = $::o->{steps}{first}; + $s = $::o->{steps}{$s}{next} while $::o->{steps}{$s}{done}; + $s; } sub doSuspend { @@ -92,11 +90,17 @@ sub mouse_detect() { sub shells($) { my ($o) = @_; - my @l = grep { -x "$o->{prefix}$_" } @{$o->{default}->{shells}}; + my @l = grep { 1 || -x "$o->{prefix}$_" } @{$o->{default}{shells}}; @l or die "no shell available"; @l; } +sub addToBeDone(&$) { + my ($f, $step) = @_; + + push @{$::o->{steps}{$step}{toBeDone}}, $f; +} + sub upgrFindInstall { # int rc; # |