commit: 1d71b219e234a15889f99063e8dcdff1ca44054c Author: Benda Xu <heroxbd <AT> gentoo <DOT> org> AuthorDate: Sat Jun 4 07:25:15 2016 +0000 Commit: Benda XU <heroxbd <AT> gentoo <DOT> org> CommitDate: Wed Jun 15 08:02:34 2016 +0000 URL: https://gitweb.gentoo.org/repo/proj/prefix.git/commit/?id=1d71b219
s/bootstrap-prefix.sh: remove EPREFIX/tmp after "emerge -e system". partially reverts 3a945696443b. 1. A rerun of bootstrap script after "emerge -e system" failure should not go through stage1 again. 2. For RAP binutils in stage3 is linked against zlib of stage2. scripts/bootstrap-prefix.sh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/scripts/bootstrap-prefix.sh b/scripts/bootstrap-prefix.sh index a023ed3..5cb89b7 100755 --- a/scripts/bootstrap-prefix.sh +++ b/scripts/bootstrap-prefix.sh @@ -1508,12 +1508,6 @@ EOF # Switch to the proper portage. hash -r - # Get rid of the temporary tools. - if [[ -d ${ROOT}/tmp/var/tmp ]] ; then - rm -rf "${ROOT}"/tmp - mkdir "${ROOT}"/tmp - fi - # Update the portage tree. treedate=$(date -f "${ROOT}"/usr/portage/metadata/timestamp +%s) nowdate=$(date +%s) @@ -2161,7 +2155,13 @@ EOF hash -r # tmp/* stuff is removed in stage3 - if ! emerge -e system ; then + if emerge -e system ; then + # Now, after 'emerge -e system', we can get rid of the temporary tools. + if [[ -d ${EPREFIX}/tmp/var/tmp ]] ; then + rm -Rf "${EPREFIX}"/tmp || return 1 + mkdir -p "${EPREFIX}"/tmp || return 1 + fi + else # emerge -e system fail cat << EOF