summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2022-04-19 18:19:51 +0100
committerSam James <sam@gentoo.org>2022-04-19 19:20:05 +0100
commit5a7ea1cef34c3c3026a999d566bc4badc1dccc9c (patch)
treeb7060b6035b3cde7bf8de4724d6fffd501397e9d /eclass
parenttoolchain.eclass: default to .xz for newer patch tarballs (diff)
downloadgentoo-5a7ea1cef34c3c3026a999d566bc4badc1dccc9c.tar.gz
gentoo-5a7ea1cef34c3c3026a999d566bc4badc1dccc9c.tar.bz2
gentoo-5a7ea1cef34c3c3026a999d566bc4badc1dccc9c.zip
toolchain.eclass: allow overriding S in ebuilds
Useful for RCs-but-we-pretend-they're-not-RCs. Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'eclass')
-rw-r--r--eclass/toolchain.eclass22
1 files changed, 12 insertions, 10 deletions
diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass
index 9f6293910145..38e4ccd55688 100644
--- a/eclass/toolchain.eclass
+++ b/eclass/toolchain.eclass
@@ -244,7 +244,7 @@ fi
if tc_has_feature sanitize ; then
# libsanitizer relies on 'crypt.h' to be present
# on target. glibc user to provide it unconditionally.
- # Nowadays it's a standalone library: #802648
+ # Nowadays it's a standalone library: bug #802648
DEPEND+=" sanitize? ( virtual/libcrypt )"
fi
@@ -268,15 +268,17 @@ PDEPEND=">=sys-devel/gcc-config-2.3"
# Set the source directory depending on whether we're using
# a live git tree, snapshot, or release tarball.
-S=$(
- if tc_is_live ; then
- echo ${EGIT_CHECKOUT_DIR}
- elif [[ -n ${SNAPSHOT} ]] ; then
- echo ${WORKDIR}/gcc-${SNAPSHOT}
- else
- echo ${WORKDIR}/gcc-${GCC_RELEASE_VER}
- fi
-)
+if [[ -z ${S} ]] ; then
+ S=$(
+ if tc_is_live ; then
+ echo ${EGIT_CHECKOUT_DIR}
+ elif [[ -n ${SNAPSHOT} ]] ; then
+ echo ${WORKDIR}/gcc-${SNAPSHOT}
+ else
+ echo ${WORKDIR}/gcc-${GCC_RELEASE_VER}
+ fi
+ )
+fi
gentoo_urls() {
local devspace="