aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS3
-rw-r--r--URPM/Resolve.pm9
2 files changed, 8 insertions, 4 deletions
diff --git a/NEWS b/NEWS
index 5c44487..857a34b 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,6 @@
+- check for conflicting selected packages before selecting a package (#57224)
+ (by Anssi Hannula)
+
Version 3.33 - 5 October 2009, by Christophe Fergeau
- fix lookup of existing pubkeys (#53710) (by Pascal Terjan)
diff --git a/URPM/Resolve.pm b/URPM/Resolve.pm
index 4f8a9e1..3371991 100644
--- a/URPM/Resolve.pm
+++ b/URPM/Resolve.pm
@@ -968,6 +968,9 @@ sub resolve_requested__no_suggests_ {
_no_more_recent_installed_and_providing($urpm, $db, $state, $pkg, $dep->{required}) or next;
}
}
+
+ _handle_conflicts_with_selected($urpm, $db, $state, $pkg, $dep, \@properties, \@diff_provides, %options) or next;
+
$urpm->{debug_URPM}("selecting " . $pkg->fullname) if $urpm->{debug_URPM};
#- keep in mind the package has be selected, remove the entry in requested input hash,
@@ -990,8 +993,6 @@ sub resolve_requested__no_suggests_ {
_unselect_package_deprecated_by($urpm, $db, $state, \%diff_provides_h, $pkg);
}
- _handle_conflicts_with_selected($urpm, $db, $state, $pkg, $dep, \@properties, \@diff_provides, %options) or next;
-
#- all requires should be satisfied according to selected package, or installed packages.
if (my @l = unsatisfied_requires($urpm, $db, $state, $pkg)) {
$urpm->{debug_URPM}("requiring " . join(',', sort @l) . " for " . $pkg->fullname) if $urpm->{debug_URPM};
@@ -1045,7 +1046,7 @@ sub resolve_requested__no_suggests_ {
#- unselects $pkg if such a package is already selected
#- side-effects:
#- + those of _set_rejected_from ($state->{rejected})
-#- + those of disable_selected (flag_requested, flag_required, $state->{selected}, $state->{rejected}, $state->{whatrequires})
+#- + those of _remove_all_rejected_from ($state->{rejected})
#- + those of backtrack_selected ($state->{backtrack}, $state->{rejected}, $state->{selected}, $state->{whatrequires}, flag_requested, flag_required)
sub _handle_conflicts_with_selected {
my ($urpm, $db, $state, $pkg, $dep, $properties, $diff_provides, %options) = @_;
@@ -1056,7 +1057,7 @@ sub _handle_conflicts_with_selected {
$p->provides_overlap($_) or next;
if (exists $state->{selected}{$p->id}) {
$urpm->{debug_URPM}($pkg->fullname . " conflicts with already selected package " . $p->fullname) if $urpm->{debug_URPM};
- disable_selected($urpm, $db, $state, $pkg);
+ _remove_all_rejected_from($state, $pkg);
_set_rejected_from($state, $pkg, $p);
unshift @$properties, backtrack_selected($urpm, $db, $state, $dep, $diff_provides, %options);
return;