Stephen Hines | 86277eb | 2015-03-23 12:06:32 -0700 | [diff] [blame] | 1 | configure_lit_site_cfg( |
| 2 | ${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.in |
| 3 | ${CMAKE_CURRENT_BINARY_DIR}/lit.site.cfg |
| 4 | ) |
| 5 | |
Pirama Arumuga Nainar | 799172d | 2016-03-03 15:50:30 -0800 | [diff] [blame^] | 6 | set(CFI_TEST_DEPS ${SANITIZER_COMMON_LIT_TEST_DEPS}) |
Stephen Hines | 86277eb | 2015-03-23 12:06:32 -0700 | [diff] [blame] | 7 | if(NOT COMPILER_RT_STANDALONE_BUILD) |
| 8 | list(APPEND CFI_TEST_DEPS |
Pirama Arumuga Nainar | 799172d | 2016-03-03 15:50:30 -0800 | [diff] [blame^] | 9 | cfi |
| 10 | opt |
| 11 | ubsan |
Stephen Hines | 86277eb | 2015-03-23 12:06:32 -0700 | [diff] [blame] | 12 | ) |
| 13 | if(LLVM_ENABLE_PIC AND LLVM_BINUTILS_INCDIR) |
| 14 | list(APPEND CFI_TEST_DEPS |
| 15 | LLVMgold |
| 16 | ) |
| 17 | endif() |
Pirama Arumuga Nainar | 7c91505 | 2015-04-08 08:58:29 -0700 | [diff] [blame] | 18 | if(APPLE) |
| 19 | list(APPEND CFI_TEST_DEPS |
| 20 | LTO |
| 21 | ) |
| 22 | endif() |
Pirama Arumuga Nainar | 799172d | 2016-03-03 15:50:30 -0800 | [diff] [blame^] | 23 | if(WIN32 AND COMPILER_RT_HAS_LLD_SOURCES) |
| 24 | list(APPEND CFI_TEST_DEPS |
| 25 | lld |
| 26 | ) |
| 27 | endif() |
Stephen Hines | 86277eb | 2015-03-23 12:06:32 -0700 | [diff] [blame] | 28 | endif() |
| 29 | |
| 30 | add_lit_testsuite(check-cfi "Running the cfi regression tests" |
| 31 | ${CMAKE_CURRENT_BINARY_DIR} |
| 32 | DEPENDS ${CFI_TEST_DEPS}) |
| 33 | |
| 34 | add_lit_target(check-cfi-and-supported "Running the cfi regression tests" |
| 35 | ${CMAKE_CURRENT_BINARY_DIR} |
| 36 | PARAMS check_supported=1 |
| 37 | DEPENDS ${CFI_TEST_DEPS}) |
| 38 | |
| 39 | set_target_properties(check-cfi PROPERTIES FOLDER "Tests") |