diff options
author | Alexey Samsonov <samsonov@google.com> | 2014-02-19 11:18:47 +0000 |
---|---|---|
committer | Alexey Samsonov <samsonov@google.com> | 2014-02-19 11:18:47 +0000 |
commit | 1d4c8d7699fd0148de9d916d06aa2952db4f5254 (patch) | |
tree | 5d061d0c94df4f4f27c767900cb96026a661eef6 /CMakeLists.txt | |
parent | 0a5efc3fcc9024a59081195e78682603197eec3d (diff) |
[CMake] Introduce COMPILER_RT_INCLUDE_TESTS option
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@201666 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index c5420516a..eebb2aa63 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -38,12 +38,15 @@ if (NOT COMPILER_RT_STANDALONE_BUILD) # Setup the paths where compiler-rt runtimes and headers should be stored. set(COMPILER_RT_OUTPUT_DIR ${LLVM_LIBRARY_OUTPUT_INTDIR}/clang/${CLANG_VERSION}) set(COMPILER_RT_INSTALL_PATH lib${LLVM_LIBDIR_SUFFIX}/clang/${CLANG_VERSION}) + option(COMPILER_RT_INCLUDE_TESTS "Generate and build compiler-rt unit tests." + ${LLVM_INCLUDE_TESTS}) else() # Take output dir and install path from the user. set(COMPILER_RT_OUTPUT_DIR ${CMAKE_CURRENT_BINARY_DIR} CACHE PATH "Path where built compiler-rt libraries should be stored.") set(COMPILER_RT_INSTALL_PATH ${CMAKE_INSTALL_PREFIX} CACHE PATH "Path where built compiler-rt libraries should be installed.") + option(COMPILER_RT_INCLUDE_TESTS "Generate and build compiler-rt unit tests." OFF) set(LLVM_CONFIG_PATH "" CACHE PATH "Path to llvm-config binary") if (NOT LLVM_CONFIG_PATH) @@ -296,7 +299,7 @@ endif() add_subdirectory(lib) -if(LLVM_INCLUDE_TESTS) +if(COMPILER_RT_INCLUDE_TESTS) add_subdirectory(unittests) endif() add_subdirectory(test) |