diff options
author | H.J. Lu <hjl.tools@gmail.com> | 2024-04-23 13:59:50 -0700 |
---|---|---|
committer | Florian Weimer <fweimer@redhat.com> | 2024-04-25 13:16:51 +0200 |
commit | 2f8f157eb0cc7f1d8d9a3fcaa8c55bed53b092a8 (patch) | |
tree | 6ad9ec1a6e74dde86b74f7972dbf7888d1373607 /sysdeps/x86/configure | |
parent | e701c7d761f6e5c48d8e9dd5da88cbe2e94943f4 (diff) | |
download | glibc-2f8f157eb0cc7f1d8d9a3fcaa8c55bed53b092a8.tar.gz glibc-2f8f157eb0cc7f1d8d9a3fcaa8c55bed53b092a8.tar.xz glibc-2f8f157eb0cc7f1d8d9a3fcaa8c55bed53b092a8.zip |
x86: Define MINIMUM_X86_ISA_LEVEL in config.h [BZ #31676]
Define MINIMUM_X86_ISA_LEVEL at configure time to avoid /usr/bin/ld: …/build/elf/librtld.os: in function `init_cpu_features': …/git/elf/../sysdeps/x86/cpu-features.c:1202: undefined reference to `_dl_runtime_resolve_fxsave' /usr/bin/ld: …/build/elf/librtld.os: relocation R_X86_64_PC32 against undefined hidden symbol `_dl_runtime_resolve_fxsave' can not be used when making a shared object /usr/bin/ld: final link failed: bad value collect2: error: ld returned 1 exit status when glibc is built with -march=x86-64-v3 and configured with --with-rtld-early-cflags=-march=x86-64, which is used to allow ld.so to print an error message on unsupported CPUs: Fatal glibc error: CPU does not support x86-64-v3 This fixes BZ #31676. Reviewed-by: Sunil K Pandey <skpgkp2@gmail.com> (cherry picked from commit 46c999741340ea559784c20a45077955b50aca43)
Diffstat (limited to 'sysdeps/x86/configure')
-rw-r--r-- | sysdeps/x86/configure | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sysdeps/x86/configure b/sysdeps/x86/configure index 2a5421bb31..d28d9bcb29 100644 --- a/sysdeps/x86/configure +++ b/sysdeps/x86/configure @@ -151,6 +151,13 @@ printf "%s\n" "$libc_cv_have_x86_isa_level" >&6; } else libc_cv_have_x86_isa_level=baseline fi +if test $libc_cv_have_x86_isa_level = baseline; then + printf "%s\n" "#define MINIMUM_X86_ISA_LEVEL 1" >>confdefs.h + +else + printf "%s\n" "#define MINIMUM_X86_ISA_LEVEL $libc_cv_have_x86_isa_level" >>confdefs.h + +fi config_vars="$config_vars have-x86-isa-level = $libc_cv_have_x86_isa_level" config_vars="$config_vars |