diff options
Diffstat (limited to 'perl-install/pkgs.pm')
-rw-r--r-- | perl-install/pkgs.pm | 28 |
1 files changed, 21 insertions, 7 deletions
diff --git a/perl-install/pkgs.pm b/perl-install/pkgs.pm index 8037c9fa2..077c1f5a4 100644 --- a/perl-install/pkgs.pm +++ b/perl-install/pkgs.pm @@ -225,7 +225,10 @@ sub packageCallbackChoices { } else { my @l = grep { #- or if a kernel has to be chosen, chose the basic one. - $_->arch ne 'src' && $_->name =~ /kernel-\d/ and return $_; + if ($_->arch ne 'src') { + $_->name =~ /kernel-\d/ and return $_; + $_->name =~ /kernel-i686/ and return $_; + } #- or even if a package requires a specific locales which #- is already selected. @@ -362,7 +365,7 @@ sub psUsingHdlists { chomp; s/\s*#.*$//; /^\s*$/ and next; - m/^\s*(noauto:)?(hdlist\S*\.cz2?)\s+(\S+)\s*(.*)$/ or die "invalid hdlist description \"$_\" in hdlists file"; + m/^\s*(noauto:)?(hdlist\S*\.cz2?)\s+(\S+)\s*(.*)$/ or die qq(invalid hdlist description "$_" in hdlists file); #- make sure the first medium is always selected! #- by default select all image. @@ -378,7 +381,7 @@ sub psUsingHdlists { } sub psUsingHdlist { - my ($prefix, $method, $packages, $hdlist, $medium, $rpmsdir, $descr, $selected, $o_fhdlist) = @_; + my ($prefix, $method, $packages, $hdlist, $medium, $rpmsdir, $descr, $selected, $o_fhdlist, $o_pubkey) = @_; my $fakemedium = "$descr ($method$medium)"; my $urpmidir = -w "$prefix/var/lib/urpmi" ? "$prefix/var/lib/urpmi" : "/tmp"; log::l("trying to read $hdlist for medium $medium"); @@ -416,8 +419,13 @@ sub psUsingHdlist { #- get all keys corresponding in the right pubkey file, #- they will be added in rpmdb later if not found. - my $pubkey = install_any::getFile("Mandrake/base/pubkey" . ($hdlist =~ /hdlist(\S*)\.cz2?/ && $1)); - $m->{pubkey} = [ $packages->parse_armored_file($pubkey) ]; + if (!$o_fhdlist || $o_pubkey) { + $m->{pubkey} = $o_pubkey; + unless ($m->{pubkey}) { + my $pubkey = install_any::getFile("Mandrake/base/pubkey" . ($hdlist =~ /hdlist(\S*)\.cz2?/ && $1)); + $m->{pubkey} = [ $packages->parse_armored_file($pubkey) ]; + } + } #- integrate medium in media list, only here to avoid download error (update) to be propagated. $packages->{mediums}{$medium} = $m; @@ -530,10 +538,16 @@ sub read_rpmsrate { sub readCompssUsers { my ($meta_class) = @_; - my (%compssUsers, @sorted, $l); my $file = 'Mandrake/base/compssUsers'; my $f = $meta_class && install_any::getFile("$file.$meta_class") || install_any::getFile($file) or die "can't find $file"; + readCompssUsers_raw($f); +} + +sub readCompssUsers_raw { + my ($f) = @_; + my (%compssUsers, @sorted, $l); + local $_; while (<$f>) { /^\s*$/ || /^#/ and next; @@ -1077,7 +1091,7 @@ sub install($$$;$$) { difference2([ $$, hashtree2list(getppid(), \%ppids) ], [ hashtree2list($$, \%ppids) ]) ]); - if (@killpid) { + if (@killpid && $::isInstall) { foreach (@killpid) { my ($prog, @para) = split("\0", cat_("/proc/$_/cmdline")); log::l("ERROR: DrakX should not have to clean the packages shit. Killing $_: " . join(' ', $prog, @para) . ".") if $prog ne '/usr/lib/gconfd-2'; |