[clang] [cmake] Use add_clang_tool() to install all tools

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

llvm-svn: 373785
This commit is contained in:
Michal Gorny 2019-10-04 20:28:59 +00:00
parent da9e252491
commit c178809eb6
3 changed files with 3 additions and 11 deletions

View 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)

View 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)

View 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)