summaryrefslogtreecommitdiffstats
path: root/pym/_emerge/MiscFunctionsProcess.py
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2011-03-24 21:32:38 -0700
committerZac Medico <zmedico@gentoo.org>2011-03-24 21:32:38 -0700
commit3081e651fc3cd3a0729bb1fbe2e93fbc58dcef0d (patch)
tree84c0c38f442d42c4352602070e16a07716a73772 /pym/_emerge/MiscFunctionsProcess.py
parentf823031ed33bda9579d265b62607380bb255dfdd (diff)
downloadportage-3081e651fc3cd3a0729bb1fbe2e93fbc58dcef0d.tar.gz
portage-3081e651fc3cd3a0729bb1fbe2e93fbc58dcef0d.tar.bz2
portage-3081e651fc3cd3a0729bb1fbe2e93fbc58dcef0d.zip
MergeProcess: Fix PORTAGE_BACKGROUND/LOG_FILE use
In this subprocess we don't want PORTAGE_BACKGROUND to suppress stdout/stderr output since they are pipes. We also don't want to open PORTAGE_LOG_FILE, since it will already be opened by the parent process, so we set the PORTAGE_BACKGROUND="subprocess" value for use in conditional logging code involving PORTAGE_LOG_FILE.
Diffstat (limited to 'pym/_emerge/MiscFunctionsProcess.py')
-rw-r--r--pym/_emerge/MiscFunctionsProcess.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/pym/_emerge/MiscFunctionsProcess.py b/pym/_emerge/MiscFunctionsProcess.py
index ad8cefcfd..e6bb103d8 100644
--- a/pym/_emerge/MiscFunctionsProcess.py
+++ b/pym/_emerge/MiscFunctionsProcess.py
@@ -22,7 +22,8 @@ class MiscFunctionsProcess(AbstractEbuildProcess):
os.path.basename(portage.const.MISC_SH_BINARY))
self.args = [portage._shell_quote(misc_sh_binary)] + self.commands
- if self.logfile is None:
+ if self.logfile is None and \
+ self.settings.get("PORTAGE_BACKGROUND") != "subprocess":
self.logfile = settings.get("PORTAGE_LOG_FILE")
AbstractEbuildProcess._start(self)