From c1c585a065e5f694570d334d0e432454be41e220 Mon Sep 17 00:00:00 2001 From: Lang Hames Date: Thu, 1 Sep 2022 22:42:39 -0700 Subject: [PATCH] [ORC-RT] Don't unconditionally add dependence on llvm-jitlink. Commit 4adc5bead4a moved a dependence on llvm-jitlink from SANITIZER_COMMON_LIT_TEST_DEPS to ORC_TEST_DEPS, but in doing so it moved it out from under a 'NOT COMPILER_RT_STANDALONE_BUILD ...' conditional. This led to failures on standalone builds. This commit adds the conditional to the ORC_TEST_DEPS assignment to work around the issue while we look a longer term fix. rdar://99453446 --- compiler-rt/test/orc/CMakeLists.txt | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/compiler-rt/test/orc/CMakeLists.txt b/compiler-rt/test/orc/CMakeLists.txt index 36a7462..4d3e80c 100644 --- a/compiler-rt/test/orc/CMakeLists.txt +++ b/compiler-rt/test/orc/CMakeLists.txt @@ -1,8 +1,16 @@ set(ORC_LIT_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}) set(ORC_TESTSUITES) -set(ORC_TEST_DEPS) -list(APPEND ORC_TEST_DEPS ${SANITIZER_COMMON_LIT_TEST_DEPS} llvm-jitlink) +set(ORC_TEST_DEPS ${SANITIZER_COMMON_LIT_TEST_DEPS}) + +# TODO: This conditional was added to get standalone builds working +# (rdar://99453446). Longer term we should aim to identify and disable +# tests that depend on llvm-jitlink, or perhaps just disable ORC runtime +# regression testing entirely when it's not available. +if (NOT ANDROID AND NOT COMPILER_RT_STANDALONE_BUILD AND + NOT LLVM_RUNTIMES_BUILD) + list(APPEND ORC_TEST_DEPS $llvm-jitlink) +endif() set(ORC_TEST_ARCH ${ORC_SUPPORTED_ARCH}) if (COMPILER_RT_BUILD_ORC AND COMPILER_RT_HAS_ORC) -- 2.7.4