summaryrefslogtreecommitdiff
path: root/eclass/toolchain.eclass
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-01-04 01:27:12 +0000
committerV3n3RiX <venerix@koprulu.sector>2022-01-04 01:27:12 +0000
commit3517852e3b8a68d1e997770fc0650c5053bafc6c (patch)
tree44068672445b1418489aed82de58df3c470289e7 /eclass/toolchain.eclass
parent0f15659d48c193027158492acb726297501202c5 (diff)
gentoo resync : 04.01.2022
Diffstat (limited to 'eclass/toolchain.eclass')
-rw-r--r--eclass/toolchain.eclass48
1 files changed, 4 insertions, 44 deletions
diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass
index fd03ba176276..61718f0d9a01 100644
--- a/eclass/toolchain.eclass
+++ b/eclass/toolchain.eclass
@@ -1,4 +1,4 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
# @ECLASS: toolchain.eclass
@@ -359,7 +359,6 @@ gentoo_urls() {
# with a Cygwin target.
get_gcc_src_uri() {
export PATCH_GCC_VER=${PATCH_GCC_VER:-${GCC_RELEASE_VER}}
- export UCLIBC_GCC_VER=${UCLIBC_GCC_VER:-${PATCH_GCC_VER}}
export MUSL_GCC_VER=${MUSL_GCC_VER:-${PATCH_GCC_VER}}
export PIE_GCC_VER=${PIE_GCC_VER:-${GCC_RELEASE_VER}}
export HTB_GCC_VER=${HTB_GCC_VER:-${GCC_RELEASE_VER}}
@@ -373,7 +372,7 @@ 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="ftp://gcc.gnu.org/pub/gcc/snapshots/${SNAPSHOT}/gcc-${SNAPSHOT}.tar.xz"
+ GCC_SRC_URI="https://gcc.gnu.org/pub/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"
@@ -382,8 +381,6 @@ get_gcc_src_uri() {
fi
fi
- [[ -n ${UCLIBC_VER} ]] && \
- GCC_SRC_URI+=" $(gentoo_urls gcc-${UCLIBC_GCC_VER}-uclibc-patches-${UCLIBC_VER}.tar.bz2)"
[[ -n ${PATCH_VER} ]] && \
GCC_SRC_URI+=" $(gentoo_urls gcc-${PATCH_GCC_VER}-patches-${PATCH_VER}.tar.bz2)"
[[ -n ${MUSL_VER} ]] && \
@@ -557,10 +554,6 @@ do_gcc_gentoo_patches() {
BRANDING_GCC_PKGVERSION="${BRANDING_GCC_PKGVERSION} p${PATCH_VER}"
fi
- if [[ -n ${UCLIBC_VER} ]] ; then
- tc_apply_patches "Applying uClibc patches ..." "${WORKDIR}"/uclibc/*.patch
- fi
-
if [[ -n ${MUSL_VER} ]] && [[ ${CTARGET} == *musl* ]] ; then
if [[ ${CATEGORY} == cross-* ]] ; then
# We don't want to apply some patches when cross-compiling.
@@ -923,21 +916,9 @@ toolchain_src_configure() {
# Undoing it here.
confgcc+=( --disable-libstdcxx-time )
;;
- *-freebsd*) needed_libc=freebsd-lib;;
*-gnu*) needed_libc=glibc;;
*-klibc) needed_libc=klibc;;
*-musl*) needed_libc=musl;;
- *-uclibc*)
- # Enable shared library support only on targets
- # that support it: bug #291870
- if ! echo '#include <features.h>' | \
- $(tc-getCPP ${CTARGET}) -E -dD - 2>/dev/null | \
- grep -q __HAVE_SHARED__
- then
- confgcc+=( --disable-shared )
- fi
- needed_libc=uclibc-ng
- ;;
*-cygwin) needed_libc=cygwin;;
x86_64-*-mingw*|\
*-w64-mingw*) needed_libc=mingw64-runtime;;
@@ -991,14 +972,6 @@ toolchain_src_configure() {
# __cxa_atexit is "essential for fully standards-compliant handling of
# destructors", but apparently requires glibc.
case ${CTARGET} in
- *-uclibc*)
- if tc_has_feature nptl ; then
- confgcc+=(
- --disable-__cxa_atexit
- $(use_enable nptl tls)
- )
- fi
- ;;
*-elf|*-eabi)
confgcc+=( --with-newlib )
;;
@@ -1011,9 +984,6 @@ toolchain_src_configure() {
--enable-clocale=gnu
)
;;
- *-freebsd*)
- confgcc+=( --enable-__cxa_atexit )
- ;;
*-solaris*)
confgcc+=( --enable-__cxa_atexit )
;;
@@ -2301,8 +2271,6 @@ hardened_gcc_works() {
# $gcc_cv_ld_pie is unreliable as it simply take the output of
# `ld --help | grep -- -pie`, that reports the option in all cases, also if
# the loader doesn't actually load the resulting executables.
- # To avoid breakage, blacklist FreeBSD here at least
- [[ ${CTARGET} == *-freebsd* ]] && return 1
want_pie || return 1
_tc_use_if_iuse nopie && return 1
@@ -2324,17 +2292,9 @@ hardened_gcc_works() {
hardened_gcc_is_stable() {
local tocheck
if [[ $1 == "pie" ]] ; then
- if [[ ${CTARGET} == *-uclibc* ]] ; then
- tocheck=${PIE_UCLIBC_STABLE}
- else
- tocheck=${PIE_GLIBC_STABLE}
- fi
+ tocheck=${PIE_GLIBC_STABLE}
elif [[ $1 == "ssp" ]] ; then
- if [[ ${CTARGET} == *-uclibc* ]] ; then
- tocheck=${SSP_UCLIBC_STABLE}
- elif [[ ${CTARGET} == *-gnu* ]] ; then
- tocheck=${SSP_STABLE}
- fi
+ tocheck=${SSP_STABLE}
else
die "hardened_gcc_stable needs to be called with pie or ssp"
fi