summaryrefslogtreecommitdiffstats
path: root/pym/portage/package/ebuild/config.py
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2012-08-23 10:10:38 -0700
committerZac Medico <zmedico@gentoo.org>2012-08-23 10:10:38 -0700
commit905572230b2f156c10faa619e9e4d76b5540173a (patch)
tree53f05f1baac2d2c487c53b6f32b79e681ec28bf0 /pym/portage/package/ebuild/config.py
parentc0ac477af61fa107aaececeda2ca888292719e17 (diff)
downloadportage-905572230b2f156c10faa619e9e4d76b5540173a.tar.gz
portage-905572230b2f156c10faa619e9e4d76b5540173a.tar.bz2
portage-905572230b2f156c10faa619e9e4d76b5540173a.zip
config: _eapi_cache.clear() after setcpv
Diffstat (limited to 'pym/portage/package/ebuild/config.py')
-rw-r--r--pym/portage/package/ebuild/config.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/pym/portage/package/ebuild/config.py b/pym/portage/package/ebuild/config.py
index 81e05012e..4d871f428 100644
--- a/pym/portage/package/ebuild/config.py
+++ b/pym/portage/package/ebuild/config.py
@@ -811,7 +811,6 @@ class config(object):
# and subsequent calls to the _init() functions have no effect.
portage.output._init(config_root=self['PORTAGE_CONFIGROOT'])
portage.data._init(self)
- _eapi_cache.clear()
if mycpv:
self.setcpv(mycpv)
@@ -1508,6 +1507,10 @@ class config(object):
self.configdict["env"]["PORTAGE_USE"] = \
" ".join(sorted(x for x in use if x[-2:] != '_*'))
+ # Clear the eapi cache here rather than in the constructor, since
+ # setcpv triggers lazy instantiation of things like _use_manager.
+ _eapi_cache.clear()
+
def _grab_pkg_env(self, penv, container, protected_keys=None):
if protected_keys is None:
protected_keys = ()