@@ -755,7 +755,6 @@ function(_add_swift_host_library_single target name)
755
755
INCORPORATE_OBJECT_LIBRARIES_SHARED_ONLY
756
756
LINK_FLAGS
757
757
LLVM_LINK_COMPONENTS
758
- PRIVATE_LINK_LIBRARIES
759
758
SWIFT_COMPILE_FLAGS )
760
759
761
760
cmake_parse_arguments (SWIFTLIB_SINGLE
@@ -1143,36 +1142,6 @@ function(_add_swift_host_library_single target name)
1143
1142
target_link_directories (${target} PRIVATE
1144
1143
${library_search_directories} )
1145
1144
1146
- # Adjust the linked libraries for windows targets. On Windows, the link is
1147
- # performed against the import library, and the runtime uses the dll. Not
1148
- # doing so will result in incorrect symbol resolution and linkage. We created
1149
- # import library targets when the library was added. Use that to adjust the
1150
- # link libraries.
1151
- if (SWIFTLIB_SINGLE_SDK STREQUAL WINDOWS AND NOT CMAKE_SYSTEM_NAME STREQUAL Windows )
1152
- foreach (library_list PRIVATE_LINK_LIBRARIES )
1153
- set (import_libraries )
1154
- foreach (library ${SWIFTLIB_SINGLE_${library_list}} )
1155
- # Ensure that the library is a target. If an absolute path was given,
1156
- # then we do not have an import library associated with it. This occurs
1157
- # primarily with ICU (which will be an import library). Import
1158
- # libraries are only associated with shared libraries, so add an
1159
- # additional check for that as well.
1160
- set (import_library ${library} )
1161
- if (TARGET ${library} )
1162
- get_target_property (type ${library} TYPE )
1163
- if (${type} STREQUAL "SHARED_LIBRARY" )
1164
- set (import_library ${library} _IMPLIB )
1165
- endif ()
1166
- endif ()
1167
- list (APPEND import_libraries ${import_library} )
1168
- endforeach ()
1169
- set (SWIFTLIB_SINGLE_${library_list} ${import_libraries} )
1170
- endforeach ()
1171
- endif ()
1172
-
1173
- target_link_libraries ("${target} " PRIVATE
1174
- ${SWIFTLIB_SINGLE_PRIVATE_LINK_LIBRARIES} )
1175
-
1176
1145
# NOTE(compnerd) use the C linker language to invoke `clang` rather than
1177
1146
# `clang++` as we explicitly link against the C++ runtime. We were previously
1178
1147
# actually passing `-nostdlib++` to avoid the C++ runtime linkage.
0 commit comments