diff options
author | Bryant Wong <llvm-commits@xorshift.org> | 2017-01-07 22:14:04 +0000 |
---|---|---|
committer | Bryant Wong <llvm-commits@xorshift.org> | 2017-01-07 22:14:04 +0000 |
commit | ebc9acae35430d23364e938f2e64e400d9df1e78 (patch) | |
tree | 2b3787d2bdda1811bd055bf0996756b6f1b9c0a2 /CMakeLists.txt | |
parent | 3eacb7e06eb996c1015ee7e67c4f323f35c31208 (diff) |
[libcxxabi] Add flag to conditionally enable tests
Differential Revision: https://reviews.llvm.org/D28449
git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@291367 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index f51f402..c7d84ce 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -122,6 +122,7 @@ option(LIBCXXABI_HAS_EXTERNAL_THREAD_API "Build libc++abi with an externalized threading API. This option may only be set to ON when LIBCXXABI_ENABLE_THREADS=ON." OFF) option(LIBCXXABI_BUILD_32_BITS "Build 32 bit libc++abi." ${LLVM_BUILD_32_BITS}) +option(LIBCXXABI_INCLUDE_TESTS "Generate build targets for the libc++abi unit tests." ${LLVM_INCLUDE_TESTS}) set(LIBCXXABI_TARGET_TRIPLE "" CACHE STRING "Target triple for cross compiling.") set(LIBCXXABI_GCC_TOOLCHAIN "" CACHE PATH "GCC toolchain for cross compiling.") set(LIBCXXABI_SYSROOT "" CACHE PATH "Sysroot for cross compiling.") @@ -448,7 +449,7 @@ endif() # soname, etc... add_subdirectory(src) -if (LIBCXXABI_STANDALONE_BUILD AND NOT LIBCXXABI_ENABLE_SHARED) +if (NOT LIBCXXABI_INCLUDE_TESTS OR (LIBCXXABI_STANDALONE_BUILD AND NOT LIBCXXABI_ENABLE_SHARED)) # We can't reasonably test the system C++ library with a static libc++abi. # We either need to be able to replace libc++abi at run time (with a shared # libc++abi), or we need to be able to replace the C++ runtime (with a non- |