From 7ad0aa456700abec1a8f0ccbefe9ab14189c25ab Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Fri, 5 Oct 2007 02:50:59 +0000 Subject: [PATCH] When the metadata cache contains a negative EAPI, it means that the cache entry was generated by a version of portage that did not support the eapi. When the user upgrades to a version that now supports the previously unsupported EAPI, those cache entries need to be regenerated. Therefore, when a cache entry has a negative EAPI, check if the EAPI would be supported and trigger a regen if appropriate. (trunk r7910 and r7919) svn path=/main/branches/2.1.2/; revision=7933 --- pym/portage.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pym/portage.py b/pym/portage.py index eafefbe6b..dca191dcd 100644 --- a/pym/portage.py +++ b/pym/portage.py @@ -6263,7 +6263,12 @@ class portdbapi(dbapi): try: mydata = self.auxdb[mylocation][mycpv] - if emtime != long(mydata.get("_mtime_", 0)): + eapi = mydata.get("EAPI","").strip() + if not eapi: + eapi = "0" + if eapi.startswith("-") and eapi_is_supported(eapi[1:]): + doregen = True + elif emtime != long(mydata.get("_mtime_", 0)): doregen = True elif len(mydata.get("_eclasses_", [])) > 0: doregen = not self.eclassdb.is_eclass_data_valid(mydata["_eclasses_"]) -- 2.26.2