diff options
author | Fabian Groffen <grobian@gentoo.org> | 2019-03-25 09:01:44 +0100 |
---|---|---|
committer | Fabian Groffen <grobian@gentoo.org> | 2019-03-25 09:01:44 +0100 |
commit | 01c51c1f3c8868e6b8c6a59c84304d971cd4aea7 (patch) | |
tree | 8fc87d58bffb5e3385fea804b3f046a019f01c7a | |
parent | dev-lang/python: fix configure for 2.7.16 after builddir changes (diff) | |
download | prefix-01c51c1f3c8868e6b8c6a59c84304d971cd4aea7.tar.gz prefix-01c51c1f3c8868e6b8c6a59c84304d971cd4aea7.tar.bz2 prefix-01c51c1f3c8868e6b8c6a59c84304d971cd4aea7.zip |
scripts/bootstrap-prefix: ensure we don't use mirrors for latest tree
In do_tree, ensure that we don't end up using mirrors to fetch a daily
snapshot. The purpose of those is to be fresh, so we don't want a stale
copy.
Signed-off-by: Fabian Groffen <grobian@gentoo.org>
-rwxr-xr-x | scripts/bootstrap-prefix.sh | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/scripts/bootstrap-prefix.sh b/scripts/bootstrap-prefix.sh index 7cb83cf84d..c91f6393e4 100755 --- a/scripts/bootstrap-prefix.sh +++ b/scripts/bootstrap-prefix.sh @@ -554,10 +554,18 @@ do_tree() { mkdir -p "${PORTDIR}" if [[ ! -e ${PORTDIR}/.unpacked ]]; then - efetch "$1/$2" || return 1 + # latest tree cannot be fetched from mirrors, always have to + # respect the source to get the latest + if [[ -n ${LATEST_TREE_YES} ]] ; then + echo "$1" + ( export GENTOO_MIRRORS= ; efetch "$1/$2" ) || return 1 + else + efetch "$1/$2" || return 1 + fi [[ -e ${PORTDIR} ]] || mkdir -p ${PORTDIR} einfo "Unpacking, this may take a while" - bzip2 -dc ${DISTDIR}/$2 | tar -xf - -C ${PORTDIR} --strip-components=1 || return 1 + bzip2 -dc ${DISTDIR}/$2 | \ + tar -xf - -C ${PORTDIR} --strip-components=1 || return 1 touch ${PORTDIR}/.unpacked fi } @@ -2036,7 +2044,7 @@ set_helper_vars() { GNU_URL=${GNU_URL:="http://ftp.gnu.org/gnu"} DISTFILES_G_O="http://distfiles.gentoo.org" GENTOO_MIRRORS=${GENTOO_MIRRORS:=${DISTFILES_G_O}} - SNAPSHOT_HOST=$(rapx ${GENTOO_MIRRORS} http://rsync.prefix.bitzolder.nl) + SNAPSHOT_HOST=$(rapx ${DISTFILES_G_O} http://rsync.prefix.bitzolder.nl) SNAPSHOT_URL=${SNAPSHOT_URL:-"${SNAPSHOT_HOST}/snapshots"} GCC_APPLE_URL="http://www.opensource.apple.com/darwinsource/tarballs/other" |