]> granicus.if.org Git - clang/commitdiff
[CMake] One more stab at fixing BUILD_SHARED_LIBS
authorChris Bieneman <chris.bieneman@me.com>
Tue, 21 May 2019 17:30:59 +0000 (17:30 +0000)
committerChris Bieneman <chris.bieneman@me.com>
Tue, 21 May 2019 17:30:59 +0000 (17:30 +0000)
If clang's libraries are build SHARED, we need to grab their `PRIVATE_LINK_LIBRARIES` properties and add those to clang_shared's interface.

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

tools/clang-shlib/CMakeLists.txt

index 018aee37557616500ba82f72a7c887462e04995a..4d11dc2c49a5d6b17c2d9e79f0991114d33d894f 100644 (file)
@@ -8,6 +8,7 @@ get_property(clang_libs GLOBAL PROPERTY CLANG_STATIC_LIBS)
 foreach (lib ${clang_libs})
   list(APPEND _OBJECTS $<TARGET_OBJECTS:obj.${lib}>)
   list(APPEND _DEPS $<TARGET_PROPERTY:${lib},INTERFACE_LINK_LIBRARIES>)
+  list(APPEND _DEPS $<TARGET_PROPERTY:${lib},PRIVATE_LINK_LIBRARIES>)
 endforeach ()
 
 add_clang_library(clang_shared