File tree Expand file tree Collapse file tree 4 files changed +20
-9
lines changed Expand file tree Collapse file tree 4 files changed +20
-9
lines changed Original file line number Diff line number Diff line change @@ -4,8 +4,10 @@ add_library(LSPLogging
4
4
set_target_properties (LSPLogging PROPERTIES
5
5
INTERFACE_INCLUDE_DIRECTORIES ${CMAKE_Swift_MODULE_DIRECTORY} )
6
6
if (NOT CMAKE_SYSTEM_NAME STREQUAL Darwin )
7
- target_link_libraries (LSPLogging PRIVATE
8
- Foundation )
7
+ if (Foundation_FOUND )
8
+ target_link_libraries (LSPLogging PRIVATE
9
+ Foundation )
10
+ endif ()
9
11
endif ()
10
12
11
13
if (BUILD_SHARED_LIBS )
Original file line number Diff line number Diff line change @@ -74,9 +74,14 @@ add_library(LanguageServerProtocol
74
74
set_target_properties (LanguageServerProtocol PROPERTIES
75
75
INTERFACE_INCLUDE_DIRECTORIES ${CMAKE_Swift_MODULE_DIRECTORY} )
76
76
if (NOT CMAKE_SYSTEM_NAME STREQUAL Darwin )
77
- target_link_libraries (LanguageServerProtocol PUBLIC
78
- swiftDispatch
79
- Foundation )
77
+ if (dispatch_FOUND )
78
+ target_link_libraries (LanguageServerProtocol PUBLIC
79
+ swiftDispatch )
80
+ endif ()
81
+ if (Foundation_FOUND )
82
+ target_link_libraries (LanguageServerProtocol PUBLIC
83
+ Foundation )
84
+ endif ()
80
85
endif ()
81
86
82
87
if (BUILD_SHARED_LIBS )
Original file line number Diff line number Diff line change @@ -42,8 +42,10 @@ target_link_libraries(SourceKitLSP PUBLIC
42
42
SourceKitD
43
43
TSCUtility )
44
44
if (NOT CMAKE_SYSTEM_NAME STREQUAL Darwin )
45
- target_link_libraries (SourceKitLSP PRIVATE
46
- FoundationXML )
45
+ if (Foundation_FOUND )
46
+ target_link_libraries (SourceKitLSP PRIVATE
47
+ FoundationXML )
48
+ endif ()
47
49
endif ()
48
50
49
51
if (BUILD_SHARED_LIBS )
Original file line number Diff line number Diff line change @@ -13,8 +13,10 @@ target_link_libraries(sourcekit-lsp PRIVATE
13
13
SourceKitLSP
14
14
TSCUtility )
15
15
if (NOT CMAKE_SYSTEM_NAME STREQUAL Darwin )
16
- target_link_libraries (sourcekit-lsp PRIVATE
17
- FoundationXML )
16
+ if (Foundation_FOUND )
17
+ target_link_libraries (sourcekit-lsp PRIVATE
18
+ FoundationXML )
19
+ endif ()
18
20
endif ()
19
21
20
22
install (TARGETS sourcekit-lsp
You can’t perform that action at this time.
0 commit comments