summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2006-07-22 11:08:22 +0000
committerZac Medico <zmedico@gentoo.org>2006-07-22 11:08:22 +0000
commit8951547fe8f57962fef31cf7dac2a930a9305be9 (patch)
tree6e8d9e21e95e7d181b8e4443d3411c8297f316ed
parent655b89d9a1c5f7f3d3d3a5c1e62db82ec677bd89 (diff)
downloadportage-8951547fe8f57962fef31cf7dac2a930a9305be9.tar.gz
portage-8951547fe8f57962fef31cf7dac2a930a9305be9.tar.bz2
portage-8951547fe8f57962fef31cf7dac2a930a9305be9.zip
Use portage.best() to simplify package comparison.
svn path=/main/trunk/; revision=3988
-rwxr-xr-xbin/emerge8
1 files changed, 2 insertions, 6 deletions
diff --git a/bin/emerge b/bin/emerge
index 51f2e1981..e4fec2eeb 100755
--- a/bin/emerge
+++ b/bin/emerge
@@ -1108,13 +1108,9 @@ class depgraph:
print "ebuild:",myeb
print "binpkg:",myeb_pkg
- def cmpsplit(cpv):
- mysplit = portage.catpkgsplit(cpv)
- return [mysplit[0] + "/" + mysplit[1],
- mysplit[2], mysplit[3]]
-
if myeb and myeb_pkg:
- if portage.pkgcmp(cmpsplit(myeb), cmpsplit(myeb_pkg)) == 0:
+ bestmatch = portage.best([myeb, myeb_pkg])
+ if bestmatch == myeb_pkg:
myeb = None
else:
myeb_pkg = None