aboutsummaryrefslogtreecommitdiff
path: root/unittests/ExecutionEngine/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'unittests/ExecutionEngine/CMakeLists.txt')
-rw-r--r--unittests/ExecutionEngine/CMakeLists.txt8
1 files changed, 6 insertions, 2 deletions
diff --git a/unittests/ExecutionEngine/CMakeLists.txt b/unittests/ExecutionEngine/CMakeLists.txt
index ed7f10a23c..4eefc1e3bb 100644
--- a/unittests/ExecutionEngine/CMakeLists.txt
+++ b/unittests/ExecutionEngine/CMakeLists.txt
@@ -6,5 +6,9 @@ add_llvm_unittest(ExecutionEngineTests
ExecutionEngineTest.cpp
)
-add_subdirectory(JIT)
-add_subdirectory(MCJIT)
+# Include JIT/MCJIT tests only if native arch is a JIT target.
+list(FIND LLVM_TARGETS_WITH_JIT "${LLVM_NATIVE_ARCH}" have_jit)
+if (NOT have_jit EQUAL -1 )
+ add_subdirectory(JIT)
+ add_subdirectory(MCJIT)
+endif()