aboutsummaryrefslogtreecommitdiff
path: root/libcxxabi
diff options
context:
space:
mode:
authorLouis Dionne <ldionne.2@gmail.com>2023-09-21 17:21:24 -0400
committerGitHub <noreply@github.com>2023-09-21 17:21:24 -0400
commitd217aeb0b7baad3bf92156b2e5ea1732ee8446a1 (patch)
tree1965fb208c40c5433378261cbb3b125815b6520f /libcxxabi
parent29f8e23ab8a009f074c58d05a1ad5a14c80645c8 (diff)
downloadllvm-d217aeb0b7baad3bf92156b2e5ea1732ee8446a1.zip
llvm-d217aeb0b7baad3bf92156b2e5ea1732ee8446a1.tar.gz
llvm-d217aeb0b7baad3bf92156b2e5ea1732ee8446a1.tar.bz2
[runtimes] Simplify testing configurations on GCC by using -nostdlib++ (#67021)
Since GCC now supports -nostdlib++, we can remove some complexity in the test configurations and do the same as Clang. However, we can't fully remove the GCC test configuration for libc++ because we apparently need to explicitly link against libm for some tests to work.
Diffstat (limited to 'libcxxabi')
-rw-r--r--libcxxabi/CMakeLists.txt4
-rw-r--r--libcxxabi/test/configs/llvm-libc++abi-shared-gcc.cfg.in26
2 files changed, 1 insertions, 29 deletions
diff --git a/libcxxabi/CMakeLists.txt b/libcxxabi/CMakeLists.txt
index f380fe6..6fd4f02 100644
--- a/libcxxabi/CMakeLists.txt
+++ b/libcxxabi/CMakeLists.txt
@@ -144,9 +144,7 @@ endif()
option(LIBCXXABI_HERMETIC_STATIC_LIBRARY
"Do not export any symbols from the static library." ${LIBCXXABI_HERMETIC_STATIC_LIBRARY_DEFAULT})
-if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
- set(LIBCXXABI_DEFAULT_TEST_CONFIG "llvm-libc++abi-shared-gcc.cfg.in")
-elseif(MINGW)
+if(MINGW)
set(LIBCXXABI_DEFAULT_TEST_CONFIG "llvm-libc++abi-mingw.cfg.in")
elseif(WIN32) # clang-cl
if (LIBCXXABI_ENABLE_SHARED)
diff --git a/libcxxabi/test/configs/llvm-libc++abi-shared-gcc.cfg.in b/libcxxabi/test/configs/llvm-libc++abi-shared-gcc.cfg.in
deleted file mode 100644
index c61654b..0000000
--- a/libcxxabi/test/configs/llvm-libc++abi-shared-gcc.cfg.in
+++ /dev/null
@@ -1,26 +0,0 @@
-# This testing configuration handles running the test suite against LLVM's libc++abi
-# using a shared library, with GCC. This is done differently from Clang because
-# GCC does not support the -nostdlib++ command-line flag.
-
-lit_config.load_config(config, '@CMAKE_CURRENT_BINARY_DIR@/cmake-bridge.cfg')
-
-config.substitutions.append(('%{flags}', ''))
-config.substitutions.append(('%{compile_flags}',
- '-nostdinc++ -I %{include} -I %{cxx-include} -I %{cxx-target-include} %{maybe-include-libunwind} -I %{libcxx}/test/support -I %{libcxx}/src -D_LIBCPP_ENABLE_CXX17_REMOVED_UNEXPECTED_FUNCTIONS'
-))
-config.substitutions.append(('%{link_flags}',
- '-L %{lib} -Wl,-rpath,%{lib} -nodefaultlibs -lc++ -lc++abi -lm -lgcc_s -lgcc -lpthread -lc -lgcc_s -lgcc -latomic'
-))
-config.substitutions.append(('%{exec}',
- '%{executor} --execdir %T -- '
-))
-
-import os, site
-site.addsitedir(os.path.join('@LIBCXXABI_LIBCXX_PATH@', 'utils'))
-import libcxx.test.params, libcxx.test.config
-libcxx.test.config.configure(
- libcxx.test.params.DEFAULT_PARAMETERS,
- libcxx.test.features.DEFAULT_FEATURES,
- config,
- lit_config
-)