diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2002-03-05 12:08:27 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2002-03-05 12:08:27 +0000 |
commit | df1468d3138a89ca912b43247020e5ff22432986 (patch) | |
tree | fc206e7efe9dba9a0a4afb6c8ff95cf72889f7e0 | |
parent | 074103348a5075041505f4d5240fa7fb3906f0d2 (diff) | |
download | drakx-backup-do-not-use-df1468d3138a89ca912b43247020e5ff22432986.tar drakx-backup-do-not-use-df1468d3138a89ca912b43247020e5ff22432986.tar.gz drakx-backup-do-not-use-df1468d3138a89ca912b43247020e5ff22432986.tar.bz2 drakx-backup-do-not-use-df1468d3138a89ca912b43247020e5ff22432986.tar.xz drakx-backup-do-not-use-df1468d3138a89ca912b43247020e5ff22432986.zip |
(extract_modules): created (was done in load_raw)
-rw-r--r-- | perl-install/modules.pm | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/perl-install/modules.pm b/perl-install/modules.pm index aa2188471..54bfbbe10 100644 --- a/perl-install/modules.pm +++ b/perl-install/modules.pm @@ -590,8 +590,8 @@ sub cz_file { "/lib/modules" . (arch() eq 'sparc64' && "64") . ".cz-" . c::kernel_version(); } -sub load_raw { - my @l = map { my ($i, @i) = @$_; [ $i, \@i ] } grep { $_->[0] !~ /ignore/ } @_; +sub extract_modules { + my ($dir, @modules) = @_; my $cz = cz_file(); if (!-e $cz) { unlink $_ foreach glob_("/lib/modules*.cz*"); @@ -601,8 +601,13 @@ sub load_raw { eval { require packdrake; my $packer = new packdrake($cz, quiet => 1); - $packer->extract_archive("/tmp", map { "$_->[0].o" } @l); + $packer->extract_archive($dir, map { "$_.o" } @modules); }; +} + +sub load_raw { + my @l = map { my ($i, @i) = @$_; [ $i, \@i ] } grep { $_->[0] !~ /ignore/ } @_; + extract_modules('/tmp', map { $_->[0] } @l); my @failed = grep { my $m = "/tmp/$_->[0].o"; if (-e $m && run_program::run(["/usr/bin/insmod_", "insmod"], '2>', '/dev/tty5', $m, @{$_->[1]})) { |