[PATCH] D67321: Respect CLANG_LINK_CLANG_DYLIB=ON in libclang and c-index-test
Aaron Puchert via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sat Sep 7 11:20:30 PDT 2019
aaronpuchert added a comment.
I'm thinking about the following, but I'm not sure if that's the proper way to do it.
--- a/clang/cmake/modules/AddClang.cmake
+++ b/clang/cmake/modules/AddClang.cmake
@@ -174,8 +174,11 @@ macro(add_clang_symlink name dest)
endmacro()
function(clang_target_link_libraries target type)
+ get_target_property(TARGET_TYPE ${target} TYPE)
if (CLANG_LINK_CLANG_DYLIB)
target_link_libraries(${target} ${type} clang-cpp)
+ elseif(${TARGET_TYPE} EQUAL "STATIC_LIBRARY")
+ target_link_libraries(${target} INTERFACE ${ARGN})
else()
target_link_libraries(${target} ${type} ${ARGN})
endif()
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D67321/new/
https://reviews.llvm.org/D67321
More information about the cfe-commits
mailing list