* [gentoo-commits] portage r11745 - main/branches/prefix/pym/portage/dbapi
@ 2008-10-29 20:15 Fabian Groffen (grobian)
0 siblings, 0 replies; only message in thread
From: Fabian Groffen (grobian) @ 2008-10-29 20:15 UTC (permalink / raw
To: gentoo-commits
Author: grobian
Date: 2008-10-29 20:15:28 +0000 (Wed, 29 Oct 2008)
New Revision: 11745
Modified:
main/branches/prefix/pym/portage/dbapi/vartree.py
Log:
Apply LinkageMap changes to LinkageMapMachO, make sure we call rebuild correctly
Modified: main/branches/prefix/pym/portage/dbapi/vartree.py
===================================================================
--- main/branches/prefix/pym/portage/dbapi/vartree.py 2008-10-29 20:02:41 UTC (rev 11744)
+++ main/branches/prefix/pym/portage/dbapi/vartree.py 2008-10-29 20:15:28 UTC (rev 11745)
@@ -679,13 +679,15 @@
"""
return isinstance(self._key, tuple)
- def rebuild(self, include_file=None):
+ def rebuild(self, exclude_pkgs=None, include_file=None):
root = self._root
libs = {}
obj_key_cache = {}
obj_properties = {}
lines = []
for cpv in self._dbapi.cpv_all():
+ if exclude_pkgs is not None and cpv in exclude_pkgs:
+ continue
lines += self._dbapi.aux_get(cpv, ["NEEDED.MACHO.3"])[0].split('\n')
# Cache NEEDED.* files avoid doing excessive IO for every rebuild.
self._dbapi.flush_cache()
@@ -2878,9 +2880,10 @@
# read global reverse NEEDED map
linkmap = self.vartree.dbapi.linkmap
if ostype == "Darwin":
- linkmap.rebuild(include_file=os.path.join(inforoot, "NEEDED.MACHO.3"))
+ neededfile = "NEEDED.MACHO.3"
else:
- linkmap.rebuild(include_file=os.path.join(inforoot, "NEEDED.ELF.2"))
+ neededfile = "NEEDED.ELF.2"
+ linkmap.rebuild(include_file=os.path.join(inforoot, neededfile))
liblist = linkmap.listLibraryObjects()
# get list of libraries from old package instance
@@ -3574,8 +3577,12 @@
writedict(cfgfiledict, conf_mem_file)
exclude_pkgs = set(dblnk.mycpv for dblnk in others_in_slot)
+ if ostype == "Darwin":
+ neededfile = "NEEDED.MACHO.3"
+ else:
+ neededfile = "NEEDED.ELF.2"
self.vartree.dbapi.linkmap.rebuild(exclude_pkgs=exclude_pkgs,
- include_file=os.path.join(inforoot, "NEEDED.ELF.2"))
+ include_file=os.path.join(inforoot, neededfile))
# These caches are populated during collision-protect and the data
# they contain is now invalid. It's very important to invalidate
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-10-29 20:15 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-10-29 20:15 [gentoo-commits] portage r11745 - main/branches/prefix/pym/portage/dbapi Fabian Groffen (grobian)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox