diff options
author | Fabian Groffen <grobian@gentoo.org> | 2022-06-06 18:49:49 +0200 |
---|---|---|
committer | Fabian Groffen <grobian@gentoo.org> | 2022-06-06 18:49:49 +0200 |
commit | 1b3e9f1dc1e6fcce61f1ed7e26b93d69c927177a (patch) | |
tree | 9847d6eabb95941612ac62b156ad374f735e48ec /eclass | |
parent | sys-devel/gcc: cleanup and add 12.1.0 for Apple M1 (diff) | |
download | prefix-1b3e9f1dc1e6fcce61f1ed7e26b93d69c927177a.tar.gz prefix-1b3e9f1dc1e6fcce61f1ed7e26b93d69c927177a.tar.bz2 prefix-1b3e9f1dc1e6fcce61f1ed7e26b93d69c927177a.zip |
toolchain.eclass: update Darwin hacks for GCC-12
GCC-12 is completely C++, so patch the appropriate file(s) instead.
Signed-off-by: Fabian Groffen <grobian@gentoo.org>
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/toolchain.eclass | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/eclass/toolchain.eclass b/eclass/toolchain.eclass index 782cbeebf2..afd81cfc08 100644 --- a/eclass/toolchain.eclass +++ b/eclass/toolchain.eclass @@ -615,13 +615,17 @@ toolchain_src_prepare() { make_gcc_hard fi - # we use our libtool on Darwin + # we use our libtool on Darwin (no longer applies since 12) sed -i -e "s:/usr/bin/libtool:${EPREFIX}/usr/bin/${CTARGET}-libtool:" \ "${S}"/gcc/config/darwin.h || die "sed gcc/config/darwin.h failed" # add prefixed Frameworks to default search paths (may want to # change this in a cross-compile) + local darwindriver + tc_version_is_at_least 12 \ + && darwindriver=darwin-c.cc \ + || darwindriver=darwin-c.c sed -i -e "/\"\/System\/Library\/Frameworks\"\,/i\ \ \"${EPREFIX}/MacOSX.sdk/System/Library/Frameworks\"\, \"${EPREFIX}/Frameworks\"\, " \ - "${S}"/gcc/config/darwin-c.c || die "sed gcc/config/darwin-c.c failed" + "${S}"/gcc/config/${darwindriver} || die "sed gcc/config/${darwindriver} failed" # Make sure the pkg-config files install into multilib dirs. # Since we configure with just one --libdir, we can't use that |