summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-01-04 00:19:13 +0000
committerZac Medico <zmedico@gentoo.org>2007-01-04 00:19:13 +0000
commit0b7b1d71f62cd8e9e63c1e11f8726593d3623b1f (patch)
tree8b3e6e5a757ba150872b354f868f82d6278efe16
parent61c32e717bf23f7ddad3de5d29af86b993533f67 (diff)
downloadportage-0b7b1d71f62cd8e9e63c1e11f8726593d3623b1f.tar.gz
portage-0b7b1d71f62cd8e9e63c1e11f8726593d3623b1f.tar.bz2
portage-0b7b1d71f62cd8e9e63c1e11f8726593d3623b1f.zip
Export EBUILD_PHASE="" when running misc-function.sh in order to prevent bogus phase values coming from ${T}/environment. Thanks to solar for reporting.
svn path=/main/trunk/; revision=5457
-rw-r--r--pym/portage.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/pym/portage.py b/pym/portage.py
index 039681dcf..322bd2534 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -2781,7 +2781,7 @@ def spawnebuild(mydo,actionmap,mysettings,debug,alwaysdep=0,logfile=None):
kwargs = actionmap[mydo]["args"]
mysettings["EBUILD_PHASE"] = mydo
phase_retval = spawn(actionmap[mydo]["cmd"] % mydo, mysettings, debug=debug, logfile=logfile, **kwargs)
- del mysettings["EBUILD_PHASE"]
+ mysettings["EBUILD_PHASE"] = ""
if not kwargs["droppriv"] and secpass >= 2:
""" Privileged phases may have left files that need to be made
@@ -3373,6 +3373,7 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0,
myargs = [MISC_SH_BINARY, "preinst_bsdflags", "preinst_mask",
"preinst_sfperms", "preinst_selinux_labels",
"preinst_suid_scan"]
+ mysettings["EBUILD_PHASE"] = ""
phase_retval = spawn(" ".join(myargs),
mysettings, debug=debug, free=1, logfile=logfile)
if phase_retval != os.EX_OK:
@@ -3388,6 +3389,7 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0,
# Post phase logic and tasks that have been factored out of
# ebuild.sh.
myargs = [MISC_SH_BINARY, "postinst_bsdflags"]
+ mysettings["EBUILD_PHASE"] = ""
phase_retval = spawn(" ".join(myargs),
mysettings, debug=debug, free=1, logfile=logfile)
if phase_retval != os.EX_OK: