summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonas Devlieghere <jonas@devlieghere.com>2018-07-17 15:11:15 +0000
committerJonas Devlieghere <jonas@devlieghere.com>2018-07-17 15:11:15 +0000
commit4ab573197312b51af0345550d3d6199df926fce3 (patch)
treee3e854c39b1a7a507c06a5fb26bec0a41ca3fe11
parentdf9c9ad687d0d22bd02dea42193371b639c7565f (diff)
downloadbcm5719-llvm-4ab573197312b51af0345550d3d6199df926fce3.tar.gz
bcm5719-llvm-4ab573197312b51af0345550d3d6199df926fce3.zip
[CMake] Have check-lldb-unit use CMAKE_CURRENT_BINARY_DIR
llvm-lit uses `map_config` directives (generated at configuration-time) to make it possible to pass a test path relative to the source instead of the build folder (CMAKE_CURRENT_BINARY_DIR). However, this doesn't work in the case of swift where the build directory layout prevents llvm-lit from knowing about lldb and its test paths. This caused check-lldb-unit to fail in this configuration, while everything was working as expected upstream. This patch fixes the issue by passing a path relative to the build directory. This was already the case for check-lldb-lit. llvm-svn: 337291
-rw-r--r--lldb/lit/CMakeLists.txt5
1 files changed, 3 insertions, 2 deletions
diff --git a/lldb/lit/CMakeLists.txt b/lldb/lit/CMakeLists.txt
index da429ed6bd0..8a93236d2cf 100644
--- a/lldb/lit/CMakeLists.txt
+++ b/lldb/lit/CMakeLists.txt
@@ -73,7 +73,7 @@ set(LLDB_TEST_PARAMS
add_lit_testsuite(check-lldb-lit "Running lldb lit test suite"
${CMAKE_CURRENT_BINARY_DIR}
PARAMS lldb_site_config=${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg
- lldb_unit_site_config=${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg
+ lldb_unit_site_config=${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg
DEPENDS ${LLDB_TEST_DEPS}
)
@@ -85,7 +85,8 @@ if (TARGET clang)
add_dependencies(check-lldb-lit clang)
endif()
-add_lit_testsuites(LLDB ${CMAKE_CURRENT_SOURCE_DIR}
+add_lit_testsuites(LLDB
+ ${CMAKE_CURRENT_BINARY_DIR}
PARAMS lldb_site_config=${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg
lldb_unit_site_config=${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg
DEPENDS ${LLDB_TEST_DEPS}
OpenPOWER on IntegriCloud