diff options
| author | H.J. Lu <hjl.tools@gmail.com> | 2024-12-18 07:24:38 +0800 |
|---|---|---|
| committer | H.J. Lu <hjl.tools@gmail.com> | 2024-12-22 13:15:43 +0800 |
| commit | 03feea74dc75397f7eff10a92a322d235a6c1751 (patch) | |
| tree | be382100801776188c66b19ddaa4b43b1e7d93c7 /configure.ac | |
| parent | d085db5b57c71c3ee2fbfc38a4f7e2158abeb1d4 (diff) | |
elf: Compile test modules with -fsemantic-interposition
Compiler may default to -fno-semantic-interposition. But some elf test
modules must be compiled with -fsemantic-interposition to function properly.
Add a TEST_CC check for -fsemantic-interposition and use it on elf test
modules. This fixed
FAIL: elf/tst-dlclose-lazy
FAIL: elf/tst-pie1
FAIL: elf/tst-plt-rewrite1
FAIL: elf/unload4
when Clang 19 is used to test glibc.
Signed-off-by: H.J. Lu <hjl.tools@gmail.com>
Reviewed-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'configure.ac')
| -rw-r--r-- | configure.ac | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index 8f75b319a3..bcf37310df 100644 --- a/configure.ac +++ b/configure.ac @@ -1504,6 +1504,16 @@ LIBC_CONFIG_VAR([config-cflags-signaling-nans], [$libc_cv_cc_signaling_nans]) AC_SUBST(libc_cv_test_cc_signaling_nans) +dnl Check if TEST_CC supports -fsemantic-interposition. +LIBC_TRY_TEST_CC_OPTION([-fsemantic-interposition], + [-c -Werror -fsemantic-interposition], + libc_cv_test_cc_cflags_fsemantic_interposition, + [libc_cv_test_cc_cflags_fsemantic_interposition=yes], + [libc_cv_test_cc_cflags_fsemantic_interposition=no] +) +LIBC_CONFIG_VAR(have-test-cc-cflags-fsemantic-interposition, + $libc_cv_test_cc_cflags_fsemantic_interposition) + dnl Determine if TEST_CC supports -ffloat-store. LIBC_TRY_TEST_CC_OPTION([for -ffloat-store], [-Werror -ffloat-store], |
