Build libcxx-tsan only if TSan is supported on host architecture
authorAlexey Samsonov <vonosmas@gmail.com>
Wed, 23 Jul 2014 20:07:26 +0000 (20:07 +0000)
committerAlexey Samsonov <vonosmas@gmail.com>
Wed, 23 Jul 2014 20:07:26 +0000 (20:07 +0000)
llvm-svn: 213791

compiler-rt/lib/tsan/CMakeLists.txt

index 19efb54..3d53de9 100644 (file)
@@ -103,7 +103,8 @@ endif()
 add_dependencies(compiler-rt tsan)
 
 # Build libcxx instrumented with TSan.
-if(COMPILER_RT_HAS_LIBCXX_SOURCES AND
+if(TSAN_SUPPORTED_ARCH AND
+   COMPILER_RT_HAS_LIBCXX_SOURCES AND
    COMPILER_RT_TEST_COMPILER_ID STREQUAL "Clang")
   set(LIBCXX_PREFIX ${CMAKE_CURRENT_BINARY_DIR}/libcxx_tsan)
   add_custom_libcxx(libcxx_tsan ${LIBCXX_PREFIX}