File tree Expand file tree Collapse file tree 1 file changed +20
-3
lines changed Expand file tree Collapse file tree 1 file changed +20
-3
lines changed Original file line number Diff line number Diff line change @@ -99,14 +99,30 @@ endif()
99
99
100
100
if (CMAKE_SYSTEM_NAME STREQUAL Android OR CMAKE_SYSTEM_NAME STREQUAL Linux )
101
101
set (deployment_target -DDEPLOYMENT_TARGET_LINUX )
102
- set (Foundation_rpath_flags -Xlinker;-rpath;-Xlinker; "\\\$\$ ORIGIN" )
102
+ set (Foundation_RPATH -Xlinker;-rpath;-Xlinker; "\\\$\$ ORIGIN" )
103
103
elseif (CMAKE_SYSTEM_NAME STREQUAL Darwin )
104
104
set (deployment_target -DDEPLOYMENT_TARGET_MACOSX )
105
105
elseif (CMAKE_SYSTEM_NAME STREQUAL FreeBSD )
106
106
set (deployment_target -DDEPLOYMENT_TARGET_FREEBSD )
107
- set (Foundation_rpath_flags -Xlinker;-rpath;-Xlinker; "\\\$\$ ORIGIN" )
107
+ set (Foundation_RPATH -Xlinker;-rpath;-Xlinker; "\\\$\$ ORIGIN" )
108
108
elseif (CMAKE_SYSTEM_NAME STREQUAL Windows )
109
109
set (deployment_target -DDEPLOYMENT_TARGET_WINDOWS )
110
+ # FIXME(compnerd) these are not all CoreFoundation dependencies, some of them
111
+ # are Foundation's. We should split them up accordingly.
112
+ set (CoreFoundation_INTERFACE_LIBRARIES
113
+ -lAdvAPI32
114
+ -lDbgHelp
115
+ -lShell32
116
+ -lOle32
117
+ -lRpcRT4
118
+ -lSecur32
119
+ -lShLwApi
120
+ -lUser32
121
+ -lWS2_32
122
+ -liphlpapi
123
+ -lpathcch
124
+ -lucrt
125
+ -lshell32 )
110
126
endif ()
111
127
112
128
add_swift_library (Foundation
@@ -295,7 +311,8 @@ add_swift_library(Foundation
295
311
${libdispatch_ldflags}
296
312
-L${CMAKE_CURRENT_BINARY_DIR}
297
313
-luuid
298
- ${Foundation_rpath_flags}
314
+ ${Foundation_RPATH}
315
+ ${CoreFoundation_INTERFACE_LIBRARIES}
299
316
SWIFT_FLAGS
300
317
-DDEPLOYMENT_RUNTIME_SWIFT
301
318
${deployment_enable_libdispatch}
You can’t perform that action at this time.
0 commit comments