]> granicus.if.org Git - clang/commitdiff
[clang] [cmake] Use add_clang_tool() to install all tools
authorMichal Gorny <mgorny@gentoo.org>
Fri, 4 Oct 2019 20:28:59 +0000 (20:28 +0000)
committerMichal Gorny <mgorny@gentoo.org>
Fri, 4 Oct 2019 20:28:59 +0000 (20:28 +0000)
Switch clang-check, clang-extdef-mapping and clang-offload-bundler
to use add_clang_tool() rather than add_clang_executable() with a custom
install rule.  This makes them LLVM_DISTRIBUTION_COMPONENTS-friendly.

Differential Revision: https://reviews.llvm.org/D68429

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@373785 91177308-0d34-0410-b5e6-96231b3b80d8

tools/clang-check/CMakeLists.txt
tools/clang-extdef-mapping/CMakeLists.txt
tools/clang-offload-bundler/CMakeLists.txt

index 4576d78bcfb4d819e86e40d2da545e59e233d37a..6d2fc196631da57eac45c1e9332331aae2915c35 100644 (file)
@@ -4,7 +4,7 @@ set( LLVM_LINK_COMPONENTS
   Support
   )
 
-add_clang_executable(clang-check
+add_clang_tool(clang-check
   ClangCheck.cpp
   )
 
@@ -19,6 +19,3 @@ clang_target_link_libraries(clang-check
   clangStaticAnalyzerFrontend
   clangTooling
   )
-
-install(TARGETS clang-check
-  RUNTIME DESTINATION bin)
index 4798bdb71ad06d3159eea52348e7e55458a93208..973b68db69dff4e24cdbfbe5d265bf59695e6854 100644 (file)
@@ -3,7 +3,7 @@ set(LLVM_LINK_COMPONENTS
   support
   )
 
-add_clang_executable(clang-extdef-mapping
+add_clang_tool(clang-extdef-mapping
   ClangExtDefMapGen.cpp
   )
 
@@ -16,6 +16,3 @@ clang_target_link_libraries(clang-extdef-mapping
   clangSerialization
   clangTooling
   )
-
-install(TARGETS clang-extdef-mapping
-  RUNTIME DESTINATION bin)
index fd8f0d219a322afbf29736773fb03a7097101ca5..4ef099493364aef3d9b509aa976cf3f62ba17c9f 100644 (file)
@@ -4,7 +4,7 @@ if(NOT CLANG_BUILT_STANDALONE)
   set(tablegen_deps intrinsics_gen)
 endif()
 
-add_clang_executable(clang-offload-bundler
+add_clang_tool(clang-offload-bundler
   ClangOffloadBundler.cpp
   
   DEPENDS
@@ -21,5 +21,3 @@ clang_target_link_libraries(clang-offload-bundler
   PRIVATE
   ${CLANG_OFFLOAD_BUNDLER_LIB_DEPS}
   )
-
-install(TARGETS clang-offload-bundler RUNTIME DESTINATION bin)