summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2022-08-20 01:31:21 +0100
committerSam James <sam@gentoo.org>2022-08-20 01:32:36 +0100
commit4fd2400c18a36b8aad51328b3731fef55968e4fc (patch)
tree1bbea767169404600ab2bb6125e050f8f3f377c0 /sys-libs/glibc/glibc-2.35-r8.ebuild
parentnet-vpn/openconnect: Keyword 9.01-r1 riscv, #865819 (diff)
downloadgentoo-4fd2400c18a36b8aad51328b3731fef55968e4fc.tar.gz
gentoo-4fd2400c18a36b8aad51328b3731fef55968e4fc.tar.bz2
gentoo-4fd2400c18a36b8aad51328b3731fef55968e4fc.zip
sys-libs/glibc: restore GCC < 11.2.1_p* AVX512 sanity check
It's cheap and it avoids build failures, so why not? Only really affects Tiger Lake or so though. Fixed in newer GCCs anyway. Bug: https://bugs.gentoo.org/823780 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'sys-libs/glibc/glibc-2.35-r8.ebuild')
-rw-r--r--sys-libs/glibc/glibc-2.35-r8.ebuild6
1 files changed, 6 insertions, 0 deletions
diff --git a/sys-libs/glibc/glibc-2.35-r8.ebuild b/sys-libs/glibc/glibc-2.35-r8.ebuild
index c50c5ba3fbca..25a735d93196 100644
--- a/sys-libs/glibc/glibc-2.35-r8.ebuild
+++ b/sys-libs/glibc/glibc-2.35-r8.ebuild
@@ -326,6 +326,12 @@ setup_target_flags() {
fi
# For compatibility with older binaries at slight performance cost.
use stack-realign && export CFLAGS_x86+=" -mstackrealign"
+
+ # Workaround for bug #823780.
+ if tc-is-gcc && (($(gcc-major-version) == 11)) && (($(gcc-minor-version) <= 2)) && (($(gcc-micro-version) == 0)) ; then
+ export CFLAGS_x86="${CFLAGS_x86} -mno-avx512f"
+ einfo "Auto adding -mno-avx512f to CFLAGS_x86 for buggy GCC version (bug #823780) (ABI=${ABI})"
+ fi
fi
;;
mips)