diff options
author | Sam James <sam@gentoo.org> | 2023-03-25 02:47:19 +0000 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2023-03-25 02:49:56 +0000 |
commit | 9af2dc246b433bf8503a3e4c92d024c429fec927 (patch) | |
tree | 79aedc696427233dc2885e8dd8f635e471c7baf6 /eclass | |
parent | profiles: introduce mirror://gcc (diff) | |
download | gentoo-9af2dc246b433bf8503a3e4c92d024c429fec927.tar.gz gentoo-9af2dc246b433bf8503a3e4c92d024c429fec927.tar.bz2 gentoo-9af2dc246b433bf8503a3e4c92d024c429fec927.zip |
toolchain.eclass: use mirror://gcc first, then fallback to mirror://gnu
mirror://gnu doesn't always have snapshots, but mirror://gcc do. See
https://gcc.gnu.org/mirrors.html.
Needed because of the ongoing gnu.org DNS and availability issues.
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/toolchain.eclass | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index 8ffdd9e26f1e..81f2f7328fe4 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -537,12 +537,18 @@ get_gcc_src_uri() { # Pull gcc tarball from another location. Frequently used by gnat-gpl. GCC_SRC_URI="${GCC_TARBALL_SRC_URI}" elif [[ -n ${SNAPSHOT} ]] ; then - GCC_SRC_URI="https://gcc.gnu.org/pub/gcc/snapshots/${SNAPSHOT}/gcc-${SNAPSHOT}.tar.xz" + GCC_SRC_URI="mirror://gcc/snapshots/${SNAPSHOT}/gcc-${SNAPSHOT}.tar.xz" else if tc_version_is_between 5.5 6 || tc_version_is_between 6.4 7 || tc_version_is_at_least 7.2 ; then - GCC_SRC_URI="mirror://gnu/gcc/gcc-${GCC_PV}/gcc-${GCC_RELEASE_VER}.tar.xz" + GCC_SRC_URI=" + mirror://gcc/gcc-${GCC_PV}/gcc-${GCC_RELEASE_VER}.tar.xz + mirror://gnu/gcc/gcc-${GCC_PV}/gcc-${GCC_RELEASE_VER}.tar.xz + " else - GCC_SRC_URI="mirror://gnu/gcc/gcc-${GCC_PV}/gcc-${GCC_RELEASE_VER}.tar.bz2" + GCC_SRC_URI=" + mirror://gcc/gcc-${GCC_PV}/gcc-${GCC_RELEASE_VER}.tar.bz2 + mirror://gnu/gcc/gcc-${GCC_PV}/gcc-${GCC_RELEASE_VER}.tar.bz2 + " fi fi |