aboutsummaryrefslogtreecommitdiffstats
path: root/URPM
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2004-11-10 17:14:17 +0000
committerRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2004-11-10 17:14:17 +0000
commit87acf07604389caa49fa55c2c824ccbe4f57a9f7 (patch)
tree086976df47b8aae08cb8196286487d69611a6b57 /URPM
parent8bfb4c1139d801ccd1ae1619023b723b8ed6ccce (diff)
downloadperl-URPM-87acf07604389caa49fa55c2c824ccbe4f57a9f7.tar
perl-URPM-87acf07604389caa49fa55c2c824ccbe4f57a9f7.tar.gz
perl-URPM-87acf07604389caa49fa55c2c824ccbe4f57a9f7.tar.bz2
perl-URPM-87acf07604389caa49fa55c2c824ccbe4f57a9f7.tar.xz
perl-URPM-87acf07604389caa49fa55c2c824ccbe4f57a9f7.zip
When resolving dependencies, keep track of the packages that we just
deselected because newer versions were found, but that were not actually installed.
Diffstat (limited to 'URPM')
-rw-r--r--URPM/Resolve.pm8
1 files changed, 7 insertions, 1 deletions
diff --git a/URPM/Resolve.pm b/URPM/Resolve.pm
index 5a5c436..67e9f55 100644
--- a/URPM/Resolve.pm
+++ b/URPM/Resolve.pm
@@ -579,7 +579,13 @@ sub resolve_requested {
#- unless urpmi was invoked with --allow-force (in which
#- case rpm could be invoked with --oldpackage)
if (!$urpm->{options}{'allow-force'}) {
- $urpm->disable_selected($db, $state, $pkg);
+ #- since the originally requested packages (or other
+ #- non-installed ones) could be unselected by the following
+ #- operation, remember them, to warn the user
+ my @unselected_uninstalled = grep {
+ !$_->flag_installed
+ } $urpm->disable_selected($db, $state, $pkg);
+ $state->{unselected_uninstalled} = \@unselected_uninstalled;
}
} elsif ($satisfied) {
$rv->{obsoleted} = 1;