summaryrefslogtreecommitdiffstats
path: root/perl-install/install_steps.pm
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>2000-04-05 17:24:05 +0000
committerFrancois Pons <fpons@mandriva.com>2000-04-05 17:24:05 +0000
commitc3de4c115afa51c96bdd3684644cae2176f015b4 (patch)
tree98eebc1de911977e1861bafaa2fb3515ce5b1b2e /perl-install/install_steps.pm
parentdebc157ddf436583fd777e33829c8609a65e0c67 (diff)
downloaddrakx-c3de4c115afa51c96bdd3684644cae2176f015b4.tar
drakx-c3de4c115afa51c96bdd3684644cae2176f015b4.tar.gz
drakx-c3de4c115afa51c96bdd3684644cae2176f015b4.tar.bz2
drakx-c3de4c115afa51c96bdd3684644cae2176f015b4.tar.xz
drakx-c3de4c115afa51c96bdd3684644cae2176f015b4.zip
*** empty log message ***
Diffstat (limited to 'perl-install/install_steps.pm')
-rw-r--r--perl-install/install_steps.pm33
1 files changed, 16 insertions, 17 deletions
diff --git a/perl-install/install_steps.pm b/perl-install/install_steps.pm
index bc4d623f3..6d13edf22 100644
--- a/perl-install/install_steps.pm
+++ b/perl-install/install_steps.pm
@@ -436,31 +436,30 @@ sub pppConfig {
#------------------------------------------------------------------------------
sub installCrypto {
my ($o) = @_;
- return; #TODO broken for now
my $u = $o->{crypto} or return; $u->{mirror} or return;
my ($packages, %done);
my $dir = "$o->{prefix}/tmp";
modules::write_conf("$o->{prefix}/etc/conf.modules");
network::up_it($o->{prefix}, $o->{intf}) if $o->{intf};
+ require pkgs;
+ foreach (values %{$u->{packages}}) {
+ pkgs::selectPackage($o->{packages}, $_->{pkg}) if $_->{selected};
+ }
+
+ require crypto;
+ my $oldGetFile = \&install_any::getFile;
local *install_any::getFile = sub {
- local *F;
- open F, "$dir/$_[0]" or return;
- *F;
+ my ($rpmfile) = @_;
+ if ($rpmfile =~ /^(.*)-[^-]*-[^-]*$/) {
+ return crypto::getFile($rpmfile, $u->{mirror}) if $u->{packages}{$1};
+ }
+ #- use previous getFile typically if non cryptographic packages
+ #- have been selected by dependancies.
+ &$oldGetFile($rpmfile);
};
- require crypto;
- require pkgs;
- while (crypto::get($u->{mirror}, $dir,
- grep { !$done{$_} && ($done{$_} = $u->{packages}{$_}) } %{$u->{packages}})) {
-# $packages = pkgs::psUsingDirectory($dir);
-# foreach (values %$packages) {
-# foreach (c::headerGetEntry(pkgs::getHeader($_), 'requires')) {
-# my $r = quotemeta crypto::require2package($_);
-# /^$r-\d/ and $u->{packages}{$_} = 1 foreach keys %{$u->{packages}};
-# }
-# }
- }
- pkgs::install($o->{prefix}, $o->{isUpgrade}, [ values %$packages ]); #- TODO
+
+ $o->installPackages($o->{packages});
}
#------------------------------------------------------------------------------