1 set(ORC_LIT_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR})
4 set(ORC_TEST_DEPS ${SANITIZER_COMMON_LIT_TEST_DEPS})
6 # TODO: This conditional was added to get standalone builds working
7 # (rdar://99453446). Longer term we should aim to identify and disable
8 # tests that depend on llvm-jitlink, or perhaps just disable ORC runtime
9 # regression testing entirely when it's not available.
10 if (NOT ANDROID AND NOT COMPILER_RT_STANDALONE_BUILD AND
11 NOT LLVM_RUNTIMES_BUILD)
12 list(APPEND ORC_TEST_DEPS llvm-jitlink lli)
15 set(ORC_TEST_ARCH ${ORC_SUPPORTED_ARCH})
16 if (COMPILER_RT_BUILD_ORC AND COMPILER_RT_HAS_ORC)
17 list(APPEND ORC_TEST_DEPS orc)
18 foreach(arch ${ORC_TEST_ARCH})
19 set(ORC_TEST_TARGET_ARCH ${arch})
20 string(TOLOWER "-${arch}-${OS_NAME}" ORC_TEST_CONFIG_SUFFIX)
21 get_test_cc_for_arch(${arch} ORC_TEST_TARGET_CC ORC_TEST_TARGET_CFLAGS)
22 string(TOUPPER ${arch} ARCH_UPPER_CASE)
23 set(CONFIG_NAME ${ARCH_UPPER_CASE}${OS_NAME}Config)
25 configure_lit_site_cfg(
26 ${CMAKE_CURRENT_SOURCE_DIR}/lit.site.cfg.py.in
27 ${CMAKE_CURRENT_BINARY_DIR}/${CONFIG_NAME}/lit.site.cfg.py)
28 list(APPEND ORC_TESTSUITES ${CMAKE_CURRENT_BINARY_DIR}/${CONFIG_NAME})
32 add_lit_testsuite(check-orc-rt "Running the ORC runtime tests"
34 DEPENDS ${ORC_TEST_DEPS})
35 set_target_properties(check-orc-rt PROPERTIES FOLDER "Compiler-RT Misc")