diff options
author | Alfred Wingate <parona@protonmail.com> | 2024-04-10 23:36:37 +0300 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2024-04-13 19:40:52 +0100 |
commit | 30e32d9ed408fd786e9c1e16063c1228d123ebc1 (patch) | |
tree | af3eef8f9c9757584a109e3916aa41421dd0cca0 /sys-libs | |
parent | media-video/vobcopy: Stabilize 1.2.1 amd64, #929939 (diff) | |
download | gentoo-30e32d9ed408fd786e9c1e16063c1228d123ebc1.tar.gz gentoo-30e32d9ed408fd786e9c1e16063c1228d123ebc1.tar.bz2 gentoo-30e32d9ed408fd786e9c1e16063c1228d123ebc1.zip |
sys-libs/glibc: export CPP similarily to CC and CXX
* This is copies the approach that CC and CXX use, so that the correct
abi is used. Otherwise an abi_x86_32 configure test could
automagically enable CET which isn't available on abi_x86_32.
Bug: https://bugs.gentoo.org/927652
Signed-off-by: Alfred Wingate <parona@protonmail.com>
Closes: https://github.com/gentoo/gentoo/pull/36200
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'sys-libs')
-rw-r--r-- | sys-libs/glibc/glibc-2.39-r2.ebuild | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sys-libs/glibc/glibc-2.39-r2.ebuild b/sys-libs/glibc/glibc-2.39-r2.ebuild index 236484af1eeb..7624666b6723 100644 --- a/sys-libs/glibc/glibc-2.39-r2.ebuild +++ b/sys-libs/glibc/glibc-2.39-r2.ebuild @@ -589,10 +589,12 @@ setup_env() { # Reset CC and CXX to the value at start of emerge export CC=${glibc__ORIG_CC:-${CC:-$(tc-getCC ${CTARGET})}} export CXX=${glibc__ORIG_CXX:-${CXX:-$(tc-getCXX ${CTARGET})}} + export CPP=${glibc__ORIG_CPP:-${CPP:-$(tc-getCPP ${CTARGET})}} # and make sure glibc__ORIG_CC and glibc__ORIG_CXX is defined now. export glibc__ORIG_CC=${CC} export glibc__ORIG_CXX=${CXX} + export glibc__ORIG_CPP="${CPP}" if tc-is-clang && ! use custom-cflags && ! is_crosscompile ; then export glibc__force_gcc=yes @@ -641,6 +643,7 @@ setup_env() { export CC="$(tc-getCC ${CTARGET})" export CXX="$(tc-getCXX ${CTARGET})" + export CPP="$(tc-getCPP ${CTARGET})" # Always use tuple-prefixed toolchain. For non-native ABI glibc's configure # can't detect them automatically due to ${CHOST} mismatch and fallbacks @@ -657,6 +660,7 @@ setup_env() { # acts on CC?) export glibc__GLIBC_CC=${CC} export glibc__GLIBC_CXX=${CXX} + export glibc__GLIBC_CPP=${CPP} export glibc__abi_CFLAGS="$(get_abi_CFLAGS)" @@ -672,6 +676,8 @@ setup_env() { # Some of the tests are written in C++, so we need to force our multlib abis in, bug 623548 export CXX="${glibc__GLIBC_CXX} ${glibc__abi_CFLAGS} ${CFLAGS}" + export CPP="${glibc__GLIBC_CPP} ${glibc__abi_CFLAGS}" + if is_crosscompile; then # Assume worst-case bootstrap: glibc is built for the first time # with ${CTARGET}-g++ not available yet. We avoid |