diff options
author | Louis Dionne <ldionne.2@gmail.com> | 2024-05-28 18:29:47 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-05-28 18:29:47 -0700 |
commit | 633ea41b54bf7b2f10850bbd5ba3c4ab06081595 (patch) | |
tree | 72dbe1af28ed588070d443aa6da9fe6f38c3e15f /libcxx/test | |
parent | 04f01a2b9cedc291fa7dd941de841dc957c75a33 (diff) | |
download | llvm-633ea41b54bf7b2f10850bbd5ba3c4ab06081595.zip llvm-633ea41b54bf7b2f10850bbd5ba3c4ab06081595.tar.gz llvm-633ea41b54bf7b2f10850bbd5ba3c4ab06081595.tar.bz2 |
[runtimes] Reintroduce a way to select the compiler used for the test suite (#93542)
A while back, the cxx_under_test Lit parameter was removed. This patch
reintroduces a Lit parameter called "compiler" which controls the value
of the %{cxx} substitution used in the test suite.
To run the test suite with a different compiler, one can now pass
--param compiler=<path>.
Diffstat (limited to 'libcxx/test')
-rw-r--r-- | libcxx/test/CMakeLists.txt | 2 | ||||
-rw-r--r-- | libcxx/test/configs/cmake-bridge.cfg.in | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/libcxx/test/CMakeLists.txt b/libcxx/test/CMakeLists.txt index fd57aa9..ee3502d 100644 --- a/libcxx/test/CMakeLists.txt +++ b/libcxx/test/CMakeLists.txt @@ -16,6 +16,8 @@ endif() set(AUTO_GEN_COMMENT "## Autogenerated by libcxx configuration.\n# Do not edit!") set(SERIALIZED_LIT_PARAMS "# Lit parameters serialized here for llvm-lit to pick them up\n") +serialize_lit_string_param(SERIALIZED_LIT_PARAMS compiler "${CMAKE_CXX_COMPILER}") + if (NOT LIBCXX_ENABLE_EXCEPTIONS) serialize_lit_param(SERIALIZED_LIT_PARAMS enable_exceptions False) endif() diff --git a/libcxx/test/configs/cmake-bridge.cfg.in b/libcxx/test/configs/cmake-bridge.cfg.in index 84b3270..78d0cb5 100644 --- a/libcxx/test/configs/cmake-bridge.cfg.in +++ b/libcxx/test/configs/cmake-bridge.cfg.in @@ -23,8 +23,6 @@ config.recursiveExpansionLimit = 10 config.test_exec_root = os.path.join('@CMAKE_BINARY_DIR@', 'test') # Add substitutions for bootstrapping the test suite configuration -import shlex -config.substitutions.append(('%{cxx}', shlex.quote('@CMAKE_CXX_COMPILER@'))) config.substitutions.append(('%{libcxx-dir}', '@LIBCXX_SOURCE_DIR@')) config.substitutions.append(('%{include-dir}', '@LIBCXX_GENERATED_INCLUDE_DIR@')) config.substitutions.append(('%{target-include-dir}', '@LIBCXX_GENERATED_INCLUDE_TARGET_DIR@')) |