summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2008-12-10 08:16:14 +0000
committerZac Medico <zmedico@gentoo.org>2008-12-10 08:16:14 +0000
commit4d74a0b78ec46a098f9dcd40b28e280e02aaec18 (patch)
treeb468b102ff3eac85b7b89d22c175b5a0380478b9
parent409790d27c73251fb1f7dccc264ee155143f191d (diff)
downloadportage-4d74a0b78ec46a098f9dcd40b28e280e02aaec18.tar.gz
portage-4d74a0b78ec46a098f9dcd40b28e280e02aaec18.tar.bz2
portage-4d74a0b78ec46a098f9dcd40b28e280e02aaec18.zip
Make Binpkg clean the build dir immediately after locking it. This ensures
that a new PORTAGE_LOG_FILE is created. svn path=/main/trunk/; revision=12198
-rw-r--r--pym/_emerge/__init__.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py
index 44107ee20..632765490 100644
--- a/pym/_emerge/__init__.py
+++ b/pym/_emerge/__init__.py
@@ -3186,6 +3186,12 @@ class Binpkg(CompositeTask):
pkg_count = self.pkg_count
if not self.opts.fetchonly:
self._build_dir.lock()
+ try:
+ shutil.rmtree(self._build_dir.dir_path)
+ except EnvironmentError, e:
+ if e.errno != errno.ENOENT:
+ raise
+ del e
portage.prepare_build_dirs(self.settings["ROOT"], self.settings, 1)
fetcher = BinpkgFetcher(background=self.background,
logfile=self.settings.get("PORTAGE_LOG_FILE"), pkg=self.pkg,