From: Zac Medico Date: Mon, 3 Dec 2007 20:53:29 +0000 (-0000) Subject: Bug #201090 - When portage creates a temp PORTAGE_BIN_PATH, put it X-Git-Tag: v2.2_pre1~235 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=50f7502ca753f70b0dc93b4c3aad998188a98475;p=portage.git Bug #201090 - When portage creates a temp PORTAGE_BIN_PATH, put it inside PORTAGE_TMPDIR since, unlike /tmp, it can't be mounted with the "noexec" option. svn path=/main/trunk/; revision=8828 --- diff --git a/pym/portage/dbapi/vartree.py b/pym/portage/dbapi/vartree.py index d75029dc6..54b8d135e 100644 --- a/pym/portage/dbapi/vartree.py +++ b/pym/portage/dbapi/vartree.py @@ -2407,7 +2407,10 @@ class dblink(object): base_path_orig = os.path.dirname(settings["PORTAGE_BIN_PATH"]) from tempfile import mkdtemp import shutil - base_path_tmp = mkdtemp() + # Make the temp directory inside PORTAGE_TMPDIR since, unlike + # /tmp, it can't be mounted with the "noexec" option. + base_path_tmp = mkdtemp("", "._portage_reinstall_.", + settings["PORTAGE_TMPDIR"]) from portage.process import atexit_register atexit_register(shutil.rmtree, base_path_tmp) dir_perms = 0755