aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS1
-rw-r--r--URPM/Resolve.pm12
2 files changed, 5 insertions, 8 deletions
diff --git a/NEWS b/NEWS
index 5303be6..e346f4f 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,6 @@
Version 4.11 - 21 Jan 2011, by Per Øyvind Karlsen
+- fix URPM::Resolve::*_overlap() for packages having disttag
- look for EVR of package at the first element @provides@ rather than the last
- replace incorrect usage of URPM::rpmvercmp on NVRA with rpmEVRcompare in
URPM::Resolve::provided_version_that_overlaps() &
diff --git a/URPM/Resolve.pm b/URPM/Resolve.pm
index 9e14819..31b9aab 100644
--- a/URPM/Resolve.pm
+++ b/URPM/Resolve.pm
@@ -1122,8 +1122,7 @@ sub _handle_conflicts {
sub _unselect_package_deprecated_by {
my ($urpm, $db, $state, $diff_provides_h, $pkg) = @_;
- _unselect_package_deprecated_by_property($urpm, $db, $state, $pkg, $diff_provides_h, $pkg->name, '<',
- $pkg->epoch . ":" . $pkg->version . "-" . $pkg->release . ($pkg->distepoch ? ":" . $pkg->distepoch : ""));
+ _unselect_package_deprecated_by_property($urpm, $db, $state, $pkg, $diff_provides_h, $pkg->name, '<', $pkg->evr);
foreach ($pkg->obsoletes) {
my ($n, $o, $v) = property2name_op_version($_) or next;
@@ -1234,8 +1233,7 @@ sub _find_packages_obsoleting {
!$_->flag_skip
&& $_->is_arch_compat
&& !exists $state->{rejected}{$_->fullname}
- && $_->obsoletes_overlap($p->name . " == " . $p->epoch . ":" . $p->version . "-" . $p->release .
- ($p->distepoch ? ":" . $p->distepoch : ""))
+ && $_->obsoletes_overlap($p->name . " == " . $p->evr)
&& $_->fullname ne $p->fullname
&& (!strict_arch($urpm) || strict_arch_check($p, $_));
} $urpm->packages_obsoleting($p->name);
@@ -1258,8 +1256,7 @@ sub _handle_diff_provides {
my @packages = find_candidate_packages_($urpm, $p->name, $state->{rejected});
@packages =
grep { ($_->name eq $p->name ? $p->compare_pkg($_) < 0 :
- $_->obsoletes_overlap($p->name . " == " . $p->epoch . ":" . $p->version . "-" . $p->release .
- ($p->distepoch ? ":" . $p->distepoch : "")))
+ $_->obsoletes_overlap($p->name . " == " . $p->evr))
&& (!strict_arch($urpm) || strict_arch_check($p, $_))
} @packages;
@@ -1314,8 +1311,7 @@ sub _handle_conflict {
#- the existing package will conflict with the selection; check
#- whether a newer version will be ok, else ask to remove the old.
- my $need_deps = $p->name . " > " . ($p->epoch ? $p->epoch . ":" : "") .
- $p->version . "-" . $p->release . ($p->distepoch ? ":" . $p->distepoch : "");
+ my $need_deps = $p->name . " > " . $p->evr;
my @packages = grep { $_->name eq $p->name } find_candidate_packages_($urpm, $need_deps, $state->{rejected});
@packages = grep { ! $_->provides_overlap($property) } @packages;