Do not build unittests by default.

Only build them for check-polly and check-polly-unittests in out-of-tree builds.

In LLVM, this behaviour is controlled with LLVM_BUILD_TESTS. Polly out-of-tree
does not have such a flag.

llvm-svn: 279740
This commit is contained in:
Michael Kruse 2016-08-25 14:33:44 +00:00
parent c93d123b86
commit fd4a332a3a
1 changed files with 1 additions and 1 deletions

View File

@ -8,7 +8,7 @@ function(add_polly_unittest test_name)
if(COMMAND add_unittest) if(COMMAND add_unittest)
add_unittest(PollyUnitTests ${test_name} ${ARGN}) add_unittest(PollyUnitTests ${test_name} ${ARGN})
else() else()
add_executable(${test_name} ${ARGN}) add_executable(${test_name} EXCLUDE_FROM_ALL ${ARGN})
set_target_properties(${test_name} PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}) set_target_properties(${test_name} PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
target_link_libraries(${test_name} gtest_main gtest) target_link_libraries(${test_name} gtest_main gtest)