Skip to content

Commit 80cdc37

Browse files
authored
[Clang] Include the clang-shlib CMake project when building for MSVC (llvm#109457)
Enable building clang-cpp shared library for windows when building with explicit visibility macros enabled and LLVM is built as a shared library(LLVM_BUILD_LLVM_DYLIB_VIS). This is part of the effort to support for enabling plugins on windows by adding better support for building LLVM and Clang as a DLL.
1 parent ba5e195 commit 80cdc37

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clang/tools/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ add_clang_subdirectory(c-index-test)
2222
add_clang_subdirectory(clang-refactor)
2323
# For MinGW we only enable shared library if LLVM_LINK_LLVM_DYLIB=ON.
2424
# Without that option resulting library is too close to 2^16 DLL exports limit.
25-
if(UNIX OR (MINGW AND LLVM_LINK_LLVM_DYLIB))
25+
if(UNIX OR (MSVC AND LLVM_BUILD_LLVM_DYLIB_VIS) OR (MINGW AND LLVM_LINK_LLVM_DYLIB))
2626
add_clang_subdirectory(clang-shlib)
2727
endif()
2828

0 commit comments

Comments
 (0)