diff options
author | Louis Dionne <ldionne.2@gmail.com> | 2021-10-18 17:54:05 -0400 |
---|---|---|
committer | Louis Dionne <ldionne.2@gmail.com> | 2021-10-19 08:21:29 -0400 |
commit | 7a801138f8bddf17d7df52c1c3f1d4ce8da702ad (patch) | |
tree | 237e33a1c5739eeb88e9c62b9734d965122ca78b /runtimes | |
parent | 45503fc044499a5dc88be273a2d599f8ad5bccd3 (diff) | |
download | llvm-7a801138f8bddf17d7df52c1c3f1d4ce8da702ad.tar.gz |
[runtimes] Make sure LLVM_LIT_ARGS is set before including individual runtimes
Otherwise, the individual `check-cxx`, `check-cxxabi` and similar targets
will not know about `LLVM_LIT_ARGS`, and we'll end up running lit without
any argument.
Differential Revision: https://reviews.llvm.org/D112035
Diffstat (limited to 'runtimes')
-rw-r--r-- | runtimes/CMakeLists.txt | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/runtimes/CMakeLists.txt b/runtimes/CMakeLists.txt index 2cc8eab3e73d..8a3c683900b1 100644 --- a/runtimes/CMakeLists.txt +++ b/runtimes/CMakeLists.txt @@ -152,6 +152,14 @@ foreach(entry ${runtimes}) set(HAVE_${canon_name} ON) endforeach() +if(LLVM_INCLUDE_TESTS) + set(LIT_ARGS_DEFAULT "-sv --show-xfail --show-unsupported") + if (MSVC OR XCODE) + set(LIT_ARGS_DEFAULT "${LIT_ARGS_DEFAULT} --no-progress-bar") + endif() + set(LLVM_LIT_ARGS "${LIT_ARGS_DEFAULT}" CACHE STRING "Default options for lit") +endif() + # We do this in two loops so that HAVE_* is set for each runtime before the # other runtimes are added. foreach(entry ${runtimes}) @@ -179,13 +187,6 @@ endforeach() if(LLVM_INCLUDE_TESTS) # Add a global check rule now that all subdirectories have been traversed # and we know the total set of lit testsuites. - - set(LIT_ARGS_DEFAULT "-sv --show-xfail --show-unsupported") - if (MSVC OR XCODE) - set(LIT_ARGS_DEFAULT "${LIT_ARGS_DEFAULT} --no-progress-bar") - endif() - set(LLVM_LIT_ARGS "${LIT_ARGS_DEFAULT}" CACHE STRING "Default options for lit") - add_lit_target(check-runtimes "Running all regression tests" ${RUNTIMES_LIT_TESTSUITES} |