[entropy.spm] PortagePlugin: use /var/tmp/entropy as mkdtemp() dir in doebuild()

This avoids problems for users using tmpfs /tmp
This commit is contained in:
Fabio Erculiani
2013-03-29 08:10:44 +00:00
parent d89f15d760
commit bc083adbe9
@@ -2066,7 +2066,9 @@ class PortagePlugin(SpmPlugin):
portage_tmpdir_created = False # for pkg_postrm, pkg_prerm
if portage_tmpdir is None:
portage_tmpdir = tempfile.mkdtemp()
# /tmp might be mounted using tmpfs, noexec, etc
portage_tmpdir = tempfile.mkdtemp(
dir=etpConst['entropyunpackdir'])
portage_tmpdir_created = True
elif not os.path.isdir(portage_tmpdir):
os.makedirs(portage_tmpdir, 0o744)