[llvm-commits] [compiler-rt] r161412 - /compiler-rt/trunk/lib/asan/lit_tests/CMakeLists.txt

Alexey Samsonov samsonov at google.com
Tue Aug 7 04:09:41 PDT 2012


Author: samsonov
Date: Tue Aug  7 06:09:41 2012
New Revision: 161412

URL: http://llvm.org/viewvc/llvm-project?rev=161412&view=rev
Log:
[ASan] simplify cmake rules for adding lit testsuites

Modified:
    compiler-rt/trunk/lib/asan/lit_tests/CMakeLists.txt

Modified: compiler-rt/trunk/lib/asan/lit_tests/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/lit_tests/CMakeLists.txt?rev=161412&r1=161411&r2=161412&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/lit_tests/CMakeLists.txt (original)
+++ compiler-rt/trunk/lib/asan/lit_tests/CMakeLists.txt Tue Aug  7 06:09:41 2012
@@ -11,19 +11,16 @@
   ${CMAKE_CURRENT_BINARY_DIR}/Unit/lit.site.cfg
   )
 
-set(ASAN_TEST_DEPS
-  clang-rt.asan-x86_64 clang-rt.asan-i386
-  )
-if(LLVM_INCLUDE_TESTS)
-  list(APPEND ASAN_TEST_DEPS AsanUnitTests)
-endif()
-
 if("${CMAKE_HOST_SYSTEM}" STREQUAL "${CMAKE_SYSTEM}")
   # Run ASan output tests only if we're not cross-compiling,
   # and can be sure that clang would produce working binaries.
-  list(APPEND ASAN_TEST_DEPS
+  set(ASAN_TEST_DEPS
     clang clang-headers FileCheck count not
+    clang-rt.asan-x86_64 clang-rt.asan-i386
     )
+  if(LLVM_INCLUDE_TESTS)
+    list(APPEND ASAN_TEST_DEPS AsanUnitTests)
+  endif()
   add_lit_testsuite(check-asan "Running the AddressSanitizer tests"
     ${CMAKE_CURRENT_BINARY_DIR}
     DEPENDS ${ASAN_TEST_DEPS}
@@ -33,7 +30,7 @@
   # Otherwise run only ASan unit tests.
   add_lit_testsuite(check-asan "Running the AddressSanitizer unit tests"
     ${CMAKE_CURRENT_BINARY_DIR}/Unit
-    DEPENDS ${ASAN_TEST_DEPS}
+    DEPENDS AsanUnitTests
     )
   set_target_properties(check-asan PROPERTIES FOLDER "ASan unit tests")
 endif()





More information about the llvm-commits mailing list