summaryrefslogtreecommitdiff
path: root/test/asan/CMakeLists.txt
diff options
context:
space:
mode:
authorKuba Mracek <mracek@apple.com>2016-11-29 19:25:53 +0000
committerKuba Mracek <mracek@apple.com>2016-11-29 19:25:53 +0000
commitf5b57a6e6c35536268c680c785dff33d1b587c97 (patch)
treefd7839bd688a4bed34c67d8de9cc19821dfab21c /test/asan/CMakeLists.txt
parentcae76be0761eb694ded4da32ff95f50257f5bfe0 (diff)
[sanitizer] Add macOS minimum deployment target to all compiler invocations in lit tests
The Clang driver on macOS decides the deployment target based on various things, like your host OS version, the SDK version and some environment variables, which makes lit tests pass or fail based on your environment. Let's make sure we run all lit tests with `-mmacosx-version-min=${SANITIZER_MIN_OSX_VERSION}` (10.9 unless overriden). Differential Revision: https://reviews.llvm.org/D26929 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@288186 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/asan/CMakeLists.txt')
-rw-r--r--test/asan/CMakeLists.txt10
1 files changed, 1 insertions, 9 deletions
diff --git a/test/asan/CMakeLists.txt b/test/asan/CMakeLists.txt
index cb32cfba8..637c5b808 100644
--- a/test/asan/CMakeLists.txt
+++ b/test/asan/CMakeLists.txt
@@ -43,15 +43,7 @@ foreach(arch ${ASAN_TEST_ARCH})
endif()
string(TOLOWER "-${arch}-${OS_NAME}" ASAN_TEST_CONFIG_SUFFIX)
get_bits_for_arch(${arch} ASAN_TEST_BITS)
- if(ANDROID OR ${arch} MATCHES "arm|aarch64")
- # This is only true if we are cross-compiling.
- # Build all tests with host compiler and use host tools.
- set(ASAN_TEST_TARGET_CC ${COMPILER_RT_TEST_COMPILER})
- set(ASAN_TEST_TARGET_CFLAGS ${COMPILER_RT_TEST_COMPILER_CFLAGS})
- else()
- get_target_flags_for_arch(${arch} ASAN_TEST_TARGET_CFLAGS)
- string(REPLACE ";" " " ASAN_TEST_TARGET_CFLAGS "${ASAN_TEST_TARGET_CFLAGS}")
- endif()
+ get_test_cc_for_arch(${arch} ASAN_TEST_TARGET_CC ASAN_TEST_TARGET_CFLAGS)
if(ANDROID)
set(ASAN_TEST_DYNAMIC True)
else()