summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2008-08-20 03:13:45 +0000
committerZac Medico <zmedico@gentoo.org>2008-08-20 03:13:45 +0000
commit27d6e837d1ce90a8ed56adbffa7ce5baf2dd4e35 (patch)
tree4cf86ee09c6e627de2b899ae657236e2214498cc
parent9bb99ddda8070ee38d052e995c2e595b068a4fa8 (diff)
downloadportage-27d6e837d1ce90a8ed56adbffa7ce5baf2dd4e35.tar.gz
portage-27d6e837d1ce90a8ed56adbffa7ce5baf2dd4e35.tar.bz2
portage-27d6e837d1ce90a8ed56adbffa7ce5baf2dd4e35.zip
Make sure EBUILD_PHASE is properly unset when calling misc-functions.sh.
svn path=/main/trunk/; revision=11440
-rw-r--r--pym/_emerge/__init__.py1
-rw-r--r--pym/portage/__init__.py2
2 files changed, 3 insertions, 0 deletions
diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py
index d9d762860..411f0a16e 100644
--- a/pym/_emerge/__init__.py
+++ b/pym/_emerge/__init__.py
@@ -2202,6 +2202,7 @@ class MiscFunctionsProcess(SpawnProcess):
def _start(self):
settings = self.settings
+ settings.pop("EBUILD_PHASE", None)
portage_bin_path = settings["PORTAGE_BIN_PATH"]
misc_sh_binary = os.path.join(portage_bin_path,
os.path.basename(portage.const.MISC_SH_BINARY))
diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py
index bbfdd7d10..42124708f 100644
--- a/pym/portage/__init__.py
+++ b/pym/portage/__init__.py
@@ -5527,6 +5527,7 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0,
if phase_retval == os.EX_OK:
_doebuild_exit_status_unlink(
mysettings.get("EBUILD_EXIT_STATUS_FILE"))
+ mysettings.pop("EBUILD_PHASE", None)
phase_retval = spawn(
" ".join(_post_pkg_preinst_cmd(mysettings)),
mysettings, debug=debug, free=1, logfile=logfile)
@@ -5548,6 +5549,7 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0,
if phase_retval == os.EX_OK:
_doebuild_exit_status_unlink(
mysettings.get("EBUILD_EXIT_STATUS_FILE"))
+ mysettings.pop("EBUILD_PHASE", None)
phase_retval = spawn(" ".join(_post_pkg_postinst_cmd(mysettings)),
mysettings, debug=debug, free=1, logfile=logfile)
phase_retval = exit_status_check(phase_retval)