dblink.merge: populate vardbapi cache for new pkg
authorZac Medico <zmedico@gentoo.org>
Fri, 27 May 2011 02:55:28 +0000 (19:55 -0700)
committerZac Medico <zmedico@gentoo.org>
Fri, 27 May 2011 02:55:28 +0000 (19:55 -0700)
This is similar to commit 4b5ab00fd0fd08af8c9075acdbb3921cf39d41a3 from
the master branch, but in this branch it doesn't fit in MergeProcess.

pym/portage/dbapi/vartree.py

index f93652b370fccd82b9098720fb5f5328446bba17..b8daa3e34f96cdf1f83c7c8a7a373b60c7c69afe 100644 (file)
@@ -4092,6 +4092,14 @@ class dblink(object):
                                                        self, mydbapi, myebuild, "clean")
 
                finally:
+
+                       # Populate the vardbapi cache for the new package
+                       # while its inodes are still hot.
+                       try:
+                               self.vartree.dbapi.aux_get(self.mycpv, ["EAPI"])
+                       except KeyError:
+                               pass
+
                        self.settings.pop('REPLACING_VERSIONS', None)
                        if self.vartree.dbapi._linkmap is None:
                                # preserve-libs is entirely disabled