extras-repoclosure rc-modified,1.20,1.21
Michael Schwendt (mschwendt)
fedora-extras-commits at redhat.com
Mon Mar 3 14:21:59 UTC 2008
Author: mschwendt
Update of /cvs/fedora/extras-repoclosure
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv5927
Modified Files:
rc-modified
Log Message:
rely on returnNewestByName for noarch<->arch evr comparison
Index: rc-modified
===================================================================
RCS file: /cvs/fedora/extras-repoclosure/rc-modified,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- rc-modified 27 Feb 2008 10:16:32 -0000 1.20
+++ rc-modified 3 Mar 2008 14:21:59 -0000 1.21
@@ -142,19 +142,6 @@
except AttributeError:
pass
- def isnotnewest(pkg):
- # Handle noarch<->arch switches in package updates, so any
- # old nevra returned by returnNewestByNameArch() are skipped.
- # TODO: There must be a more elegant/convenient way.
- if (pkg.pkgtup[1] == 'noarch'):
- if (pkg.pkgtup not in newestpkgtuplist):
- return True
- else:
- for p in self.pkgSack.returnNewestByName(pkg.pkgtup[0]):
- if (p.pkgtup[1] == 'noarch') and (p.pkgtup in newestpkgtuplist):
- return True
- return False
-
for (req, flags, (reqe, reqv, reqr)) in pkg.returnPrco('requires'):
if req.startswith('rpmlib'): continue # ignore rpmlib deps
@@ -167,7 +154,7 @@
pass
if len(resolve_sack) < 1:
- if newest and isnotnewest(pkg):
+ if newest and pkg.pkgtup not in newestpkgtuplist:
break
if not unresolved.has_key(pkg):
unresolved[pkg] = []
@@ -181,7 +168,7 @@
if newest and not kernelprovides and not req.startswith('kernel'): # we allow old kernels
resolved_by_newest = False
- for po in resolve_sack:# look through and make sure all our answers are newest-only
+ for po in resolve_sack:# look through and make sure any of our answers are newest-only
# 2nd stage handling of obsoletes. Only keep providers,
# which are not obsolete. If no provider is left, the
@@ -202,7 +189,7 @@
if resolved_by_newest:
resolved[(req,flags,ver)] = 1
else:
- if newest and isnotnewest(pkg):
+ if newest and pkg.pkgtup not in newestpkgtuplist:
break
if not unresolved.has_key(pkg):
unresolved[pkg] = []
More information about the fedora-extras-commits
mailing list