1 |
commit: 905572230b2f156c10faa619e9e4d76b5540173a |
2 |
Author: Zac Medico <zmedico <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Aug 23 17:10:38 2012 +0000 |
4 |
Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Aug 23 17:10:38 2012 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=90557223 |
7 |
|
8 |
config: _eapi_cache.clear() after setcpv |
9 |
|
10 |
--- |
11 |
pym/portage/package/ebuild/config.py | 5 ++++- |
12 |
1 files changed, 4 insertions(+), 1 deletions(-) |
13 |
|
14 |
diff --git a/pym/portage/package/ebuild/config.py b/pym/portage/package/ebuild/config.py |
15 |
index 81e0501..4d871f4 100644 |
16 |
--- a/pym/portage/package/ebuild/config.py |
17 |
+++ b/pym/portage/package/ebuild/config.py |
18 |
@@ -811,7 +811,6 @@ class config(object): |
19 |
# and subsequent calls to the _init() functions have no effect. |
20 |
portage.output._init(config_root=self['PORTAGE_CONFIGROOT']) |
21 |
portage.data._init(self) |
22 |
- _eapi_cache.clear() |
23 |
|
24 |
if mycpv: |
25 |
self.setcpv(mycpv) |
26 |
@@ -1508,6 +1507,10 @@ class config(object): |
27 |
self.configdict["env"]["PORTAGE_USE"] = \ |
28 |
" ".join(sorted(x for x in use if x[-2:] != '_*')) |
29 |
|
30 |
+ # Clear the eapi cache here rather than in the constructor, since |
31 |
+ # setcpv triggers lazy instantiation of things like _use_manager. |
32 |
+ _eapi_cache.clear() |
33 |
+ |
34 |
def _grab_pkg_env(self, penv, container, protected_keys=None): |
35 |
if protected_keys is None: |
36 |
protected_keys = () |