Synchronize vardbapi._aux_cache_keys with trunk. It's important
authorZac Medico <zmedico@gentoo.org>
Sun, 18 Nov 2007 04:23:36 +0000 (04:23 -0000)
committerZac Medico <zmedico@gentoo.org>
Sun, 18 Nov 2007 04:23:36 +0000 (04:23 -0000)
at least to include RESTRICT since the depgraph uses that one
and therefore it should be cached to improve performance. The
others aren't strictly necessary at this time, but it's good to
be in sync with trunk.

svn path=/main/branches/2.1.2/; revision=8522

pym/portage.py

index 046277db4dbb3bb453f6add2df614a85f5a16428..5fc82faff49f731c5669c4701f0274b9c1dbc47a 100644 (file)
@@ -5664,8 +5664,10 @@ class vardbapi(dbapi):
                if vartree is None:
                        vartree = globals()["db"][root]["vartree"]
                self.vartree = vartree
-               self._aux_cache_keys = set(["SLOT", "COUNTER", "PROVIDE", "USE",
-                       "IUSE", "DEPEND", "RDEPEND", "PDEPEND", "repository"])
+               self._aux_cache_keys = set(
+                       ["CHOST", "COUNTER", "DEPEND", "EAPI", "IUSE", "KEYWORDS",
+                       "LICENSE", "PDEPEND", "PROVIDE", "RDEPEND", "NEEDED",
+                       "repository", "RESTRICT" , "SLOT", "USE"])
                self._aux_cache = None
                self._aux_cache_version = "1"
                self._aux_cache_filename = os.path.join(self.root,
@@ -6019,7 +6021,8 @@ class vardbapi(dbapi):
                                        myd = myf.read()
                                finally:
                                        myf.close()
-                               myd = " ".join(myd.split())
+                               if x != "NEEDED":
+                                       myd = " ".join(myd.split())
                        except IOError:
                                myd = ""
                        if x == "EAPI" and not myd: