summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-01-19 01:16:36 +0000
committerZac Medico <zmedico@gentoo.org>2007-01-19 01:16:36 +0000
commit3b09e6199004e605014127ea5a4d284dee4d6792 (patch)
tree91ef7b69532c4ae69edf76a03ee5bd8e83c8b05f
parent0bd7abde7fd2d87c0ac9e5d7ee23bbc85b900ace (diff)
downloadportage-3b09e6199004e605014127ea5a4d284dee4d6792.tar.gz
portage-3b09e6199004e605014127ea5a4d284dee4d6792.tar.bz2
portage-3b09e6199004e605014127ea5a4d284dee4d6792.zip
For bug #162404, when sesandbox is enabled, only log if PORT_LOGDIR is explicitly enabled since it is possible that local SELinux security policies do not allow ouput to be piped out of the sesandbox domain.
svn path=/main/trunk/; revision=5718
-rw-r--r--pym/portage.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/pym/portage.py b/pym/portage.py
index 69f636214..e1b0f7445 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -3228,7 +3228,13 @@ def prepare_build_dirs(myroot, mysettings, cleanup):
(mysettings["CATEGORY"], mysettings["PF"], logid_time))
del logid_path, logid_time
else:
- mysettings["PORTAGE_LOG_FILE"] = os.path.join(mysettings["T"], "build.log")
+ # When sesandbox is enabled, only log if PORT_LOGDIR is explicitly
+ # enabled since it is possible that local SELinux security policies
+ # do not allow ouput to be piped out of the sesandbox domain.
+ if not (mysettings.selinux_enabled() and \
+ "sesandbox" in mysettings.features):
+ mysettings["PORTAGE_LOG_FILE"] = os.path.join(
+ mysettings["T"], "build.log")
_doebuild_manifest_exempt_depend = 0
_doebuild_manifest_checked = None