[test-suite] r300355 - CMakeLists.txt: Allow external dirs in TEST_SUITE_SUBDIRS
Matthias Braun via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 14 11:03:31 PDT 2017
Author: matze
Date: Fri Apr 14 13:03:31 2017
New Revision: 300355
URL: http://llvm.org/viewvc/llvm-project?rev=300355&view=rev
Log:
CMakeLists.txt: Allow external dirs in TEST_SUITE_SUBDIRS
We need to compute a binary_dir for the add_subdirectory() call to be
able to include any directory outside the test-suite path.
Modified:
test-suite/trunk/CMakeLists.txt
Modified: test-suite/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/test-suite/trunk/CMakeLists.txt?rev=300355&r1=300354&r2=300355&view=diff
==============================================================================
--- test-suite/trunk/CMakeLists.txt (original)
+++ test-suite/trunk/CMakeLists.txt Fri Apr 14 13:03:31 2017
@@ -200,7 +200,8 @@ set(TEST_SUITE_SUBDIRS "${TEST_SUITE_SUB
foreach(subdir ${TEST_SUITE_SUBDIRS})
message(STATUS "Adding directory ${subdir}")
- add_subdirectory(${subdir})
+ get_filename_component(subdir_basename ${subdir} NAME)
+ add_subdirectory(${subdir} ${subdir_basename})
endforeach()
option(TEST_SUITE_RUN_BENCHMARKS "Actually run the benchmarks in lit" On)
More information about the llvm-commits
mailing list