Skip to content

Commit ba1e88f

Browse files
committed
build: repair build on Windows
This enables building SourceKit-LSP on Windows. This is sufficient to repair the build, though it is insufficient to run currently.
1 parent f40f610 commit ba1e88f

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

Sources/LanguageServerProtocol/CMakeLists.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,9 @@ add_library(LanguageServerProtocol
7070
)
7171
set_target_properties(LanguageServerProtocol PROPERTIES
7272
INTERFACE_INCLUDE_DIRECTORIES ${CMAKE_Swift_MODULE_DIRECTORY})
73-
if(NOT CMAKE_SYSTEM_NAME STREQUAL Windows)
73+
if(NOT CMAKE_SYSTEM_NAME STREQUAL Darwin)
7474
target_link_libraries(LanguageServerProtocol PUBLIC
75+
swiftDispatch
7576
Foundation)
7677
endif()
7778

Sources/SourceKit/CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,10 @@ target_link_libraries(SourceKit PUBLIC
3838
SKCore
3939
SKSwiftPMWorkspace
4040
TSCUtility)
41+
if(NOT CMAKE_SYSTEM_NAME STREQUAL Darwin)
42+
target_link_libraries(SourceKit PRIVATE
43+
FoundationXML)
44+
endif()
4145

4246
if(BUILD_SHARED_LIBS)
4347
get_swift_host_arch(swift_arch)

Sources/sourcekit-lsp/CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ target_link_libraries(sourcekit-lsp PRIVATE
1111
LanguageServerProtocolJSONRPC
1212
SourceKit
1313
TSCUtility)
14+
if(NOT CMAKE_SYSTEM_NAME STREQUAL Darwin)
15+
target_link_libraries(sourcekit-lsp PRIVATE
16+
FoundationXML)
17+
endif()
1418

1519
install(TARGETS sourcekit-lsp
1620
DESTINATION bin)

0 commit comments

Comments
 (0)