summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Stubbs <jstubbs@gentoo.org>2005-10-11 12:46:33 +0000
committerJason Stubbs <jstubbs@gentoo.org>2005-10-11 12:46:33 +0000
commitab60dde101192da76b2d54fdaf5753703b235847 (patch)
treee254dce7f6f2012ebdc0c6915bf62e507407598c
parentea14cf1e1538662c000a6bc4137725a9f4aa562e (diff)
downloadportage-ab60dde101192da76b2d54fdaf5753703b235847.tar.gz
portage-ab60dde101192da76b2d54fdaf5753703b235847.tar.bz2
portage-ab60dde101192da76b2d54fdaf5753703b235847.zip
Set PORTDIR_OVERLAY (rather than PORTDIR) when portage wants to use a different ebuild.
(Yields the same behaviour when stuff isn't missing in the same tree and better behaviour when there is) svn path=/main/branches/2.0/; revision=2124
-rwxr-xr-xbin/ebuild7
1 files changed, 3 insertions, 4 deletions
diff --git a/bin/ebuild b/bin/ebuild
index 75386c7f6..45f2442e6 100755
--- a/bin/ebuild
+++ b/bin/ebuild
@@ -37,10 +37,9 @@ cpv = "/".join(ebuild_split[-2:])[:-7]
portage_ebuild = portage.portdb.findname(cpv)
-if portage_ebuild != ebuild:
- os.environ["PORTDIR"] = "/".join(ebuild_split[:-2])
- os.environ["PORTDIR_OVERLAY"] = ""
- print "Adjusting PORTDIR to '%s'..." % os.environ["PORTDIR"]
+if not portage_ebuild or os.path.abspath(portage_ebuild) != ebuild:
+ os.environ["PORTDIR_OVERLAY"] = "/".join(ebuild_split[:-2])
+ print "Adjusting PORTDIR_OVERLAY to '%s'..." % os.environ["PORTDIR_OVERLAY"]
reload(portage)