[llvm-commits] [compiler-rt] r173677 - CMake: simplify build rules for compiler-rt unit tests. This fixes warnings in Ninja build tree.

Alexey Samsonov samsonov at google.com
Mon Jan 28 01:07:31 PST 2013


Author: samsonov
Date: Mon Jan 28 03:07:30 2013
New Revision: 173677

URL: http://llvm.org/viewvc/llvm-project?rev=173677&view=rev
Log:
CMake: simplify build rules for compiler-rt unit tests. This fixes warnings in Ninja build tree.

Modified:
    compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake

Modified: compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake?rev=173677&r1=173676&r2=173677&view=diff
==============================================================================
--- compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake (original)
+++ compiler-rt/trunk/cmake/Modules/AddCompilerRT.cmake Mon Jan 28 03:07:30 2013
@@ -114,12 +114,10 @@ set(COMPILER_RT_GTEST_INCLUDE_CFLAGS
 macro(add_compiler_rt_test test_suite test_name)
   parse_arguments(TEST "OBJECTS;DEPS;LINK_FLAGS" "" ${ARGN})
   set(output_bin "${CMAKE_CURRENT_BINARY_DIR}/${test_name}")
-  add_custom_command(
-    OUTPUT ${output_bin}
+  add_custom_target(${test_name}
     COMMAND clang ${TEST_OBJECTS} -o "${output_bin}"
             ${TEST_LINK_FLAGS}
     DEPENDS clang ${TEST_DEPS})
-  add_custom_target(${test_name} DEPENDS ${output_bin})
   # Make the test suite depend on the binary.
   add_dependencies(${test_suite} ${test_name})
 endmacro()





More information about the llvm-commits mailing list