summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2006-04-12 03:45:04 +0000
committerZac Medico <zmedico@gentoo.org>2006-04-12 03:45:04 +0000
commitd1ede5959f39a95711a468345938fce7d903e5ed (patch)
treeb9552bdba8d318a812563e9dec7fedba2368759e
parenta47f6c7c8713f0658aece434e6016c05239d0616 (diff)
downloadportage-d1ede5959f39a95711a468345938fce7d903e5ed.tar.gz
portage-d1ede5959f39a95711a468345938fce7d903e5ed.tar.bz2
portage-d1ede5959f39a95711a468345938fce7d903e5ed.zip
Use cannonical paths for portdb.portrees to ensure that, given pkgdir, FetchlistDict can determine the correct path for the portage tree.
svn path=/main/trunk/; revision=3134
-rw-r--r--pym/portage.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/pym/portage.py b/pym/portage.py
index 11877a861..e5b251386 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -4511,7 +4511,7 @@ class portdbapi(dbapi):
self.manifestVerifier = portage_gpg.FileChecker(self.mysettings["PORTAGE_GPG_DIR"], "gentoo.gpg", minimumTrust=self.manifestVerifyLevel)
#self.root=settings["PORTDIR"]
- self.porttree_root = porttree_root
+ self.porttree_root = os.path.realpath(porttree_root)
self.depcachedir = self.mysettings.depcachedir[:]
@@ -4532,7 +4532,8 @@ class portdbapi(dbapi):
self.xcache={}
self.frozen=0
- self.porttrees=[self.porttree_root]+self.mysettings["PORTDIR_OVERLAY"].split()
+ self.porttrees = [self.porttree_root] + \
+ [os.path.realpath(t) for t in self.mysettings["PORTDIR_OVERLAY"].split()]
self.auxdbmodule = self.mysettings.load_best_module("portdbapi.auxdbmodule")
self.auxdb = {}
@@ -6275,7 +6276,7 @@ class FetchlistDict(UserDict.DictMixin):
self.pkgdir = pkgdir
self.cp = os.sep.join(pkgdir.split(os.sep)[-2:])
self.settings = settings
- self.porttrees = [os.path.dirname(os.path.dirname(pkgdir))]
+ self.porttrees = [os.path.realpath(os.path.dirname(os.path.dirname(pkgdir)))]
def __getitem__(self, pkg_key):
"""Returns the complete fetch list for a given package."""
global portdb # has the global auxdb caches