From: Zac Medico Date: Thu, 12 Mar 2009 04:25:01 +0000 (-0000) Subject: Make dyn_clean ignore FEATURES=keepwork when [[ $EMERGE_FROM = binary ]] X-Git-Tag: v2.2_rc25~4 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=f773aa347211235417363945d8bfd409e201357e;p=portage.git Make dyn_clean ignore FEATURES=keepwork when [[ $EMERGE_FROM = binary ]] and remove shutil.rmtree() call from Binpkg._clean_exit() since dyn_clean is guaranteed to do a full clean now. svn path=/main/trunk/; revision=13069 --- diff --git a/bin/ebuild.sh b/bin/ebuild.sh index 23f1c447f..b75dfc098 100755 --- a/bin/ebuild.sh +++ b/bin/ebuild.sh @@ -712,11 +712,12 @@ dyn_clean() { rm -rf "${PORTAGE_BUILDDIR}/image" "${PORTAGE_BUILDDIR}/homedir" rm -f "${PORTAGE_BUILDDIR}/.installed" - if ! hasq keeptemp $FEATURES && ! hasq keepwork $FEATURES ; then + if [[ $EMERGE_FROM = binary ]] || \ + ! hasq keeptemp $FEATURES && ! hasq keepwork $FEATURES ; then rm -rf "${T}" fi - if ! hasq keepwork $FEATURES; then + if [[ $EMERGE_FROM = binary ]] || ! hasq keepwork $FEATURES; then rm -f "$PORTAGE_BUILDDIR"/.{exit_status,logid,unpacked,prepared} \ "$PORTAGE_BUILDDIR"/.{configured,compiled,tested,packaged} diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py index a0b73dd19..b8a0a5059 100644 --- a/pym/_emerge/__init__.py +++ b/pym/_emerge/__init__.py @@ -3510,13 +3510,6 @@ class Binpkg(CompositeTask): dir_path = self._build_dir.dir_path - try: - shutil.rmtree(dir_path) - except (IOError, OSError), e: - if e.errno != errno.ENOENT: - raise - del e - infloc = self._infloc pkg = self.pkg pkg_path = self._pkg_path