From 80826974be6b0d1382070efc4c9cca04bf21819e Mon Sep 17 00:00:00 2001 From: Sam James Date: Wed, 7 Jun 2023 09:42:46 +0100 Subject: sys-devel/gcc-apple: drop toolchain.eclass We use only a tiny function from it and this prevents modernising the eclass. Closes: https://github.com/gentoo/gentoo/pull/31337 Signed-off-by: Sam James --- sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r3.ebuild | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'sys-devel') diff --git a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r3.ebuild b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r3.ebuild index c144abe8aca5..c4d1c48409c4 100644 --- a/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r3.ebuild +++ b/sys-devel/gcc-apple/gcc-apple-4.2.1_p5666-r3.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2021 Gentoo Authors +# Copyright 1999-2023 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI="7" -inherit toolchain flag-o-matic autotools prefix toolchain-funcs +inherit flag-o-matic autotools prefix toolchain-funcs GCC_VERS=${PV/_p*/} APPLE_VERS="${PV/*_p/}.3" @@ -42,6 +42,17 @@ S=${WORKDIR}/gcc-${APPLE_VERS} # TPREFIX is the prefix of the CTARGET installation export TPREFIX=${TPREFIX:-${EPREFIX}} +export CTARGET=${CTARGET:-${CHOST}} +if [[ ${CTARGET} = ${CHOST} ]] ; then + if [[ ${CATEGORY} == cross-* ]] ; then + export CTARGET=${CATEGORY#cross-} + fi +fi + +is_crosscompile() { + [[ ${CHOST} != ${CTARGET} ]] +} + do_bootstrap() { is_crosscompile && return 1 [[ ${CHOST} != ${CBUILD} ]] && return 1 -- cgit v1.2.3-65-gdbad