summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS1
-rw-r--r--urpm/get_pkgs.pm10
2 files changed, 10 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index b69ec433..a324b05b 100644
--- a/NEWS
+++ b/NEWS
@@ -1,6 +1,7 @@
- urpmi:
o with rsync, use --copy-links (to have the same behaviour as http/ftp, and
so allow symlinks on the server)
+ o fix "urpmi --install-src" (regression introduced in 4.10.9)
Version 4.10.14 - 4 October 2007, by Pascal "Pixel" Rigaux
diff --git a/urpm/get_pkgs.pm b/urpm/get_pkgs.pm
index 401faa30..e688bc74 100644
--- a/urpm/get_pkgs.pm
+++ b/urpm/get_pkgs.pm
@@ -59,7 +59,15 @@ sub selected2list {
foreach my $id (values %fullname2id) {
my $pkg = $urpm->{depslist}[$id];
my $fullname = $pkg->fullname;
- my @pkgs = map { $_->id } grep { $fullname eq $_->fullname } $urpm->packages_by_name($pkg->name);
+ my @pkgs = $pkg->arch eq 'src' ? do {
+ # packages_by_name can't be used here since $urpm->{provides} doesn't have src.rpm
+ # so a full search is needed
+ my %requested;
+ urpm::select::search_packages($urpm, \%requested, [$pkg->name], src => 1);
+ map { split /\|/ } keys %requested;
+ } : do {
+ map { $_->id } grep { $fullname eq $_->fullname } $urpm->packages_by_name($pkg->name);
+ };
# id_map is a remapping of id.
# it is needed because @list must be [ { id => pkg } ] where id is one the selected id,