File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -578,20 +578,16 @@ function(_add_swift_library_single target name)
578
578
set (SWIFTLIB_SINGLE_API_NOTES "${module_name} " )
579
579
endif ()
580
580
581
- # On platforms that use ELF binaries (for now that is Linux and FreeBSD)
582
- # we add markers for metadata sections in the shared libraries using
583
- # these object files. This wouldn't be necessary if the link was done by
584
- # the swift binary: rdar://problem/19007002
585
- if ("${SWIFTLIB_SINGLE_SDK} " STREQUAL "LINUX" OR
586
- "${SWIFTLIB_SINGLE_SDK} " STREQUAL "FREEBSD" )
587
-
581
+ # On platforms that use ELF binaries we add markers for metadata sections in
582
+ # the shared libraries using these object files. This wouldn't be necessary
583
+ # if the link was done by the swift binary: rdar://problem/19007002
584
+ if ("${SWIFT_SDK_${SWIFTLIB_SINGLE_SDK} _OBJECT_FORMAT}" STREQUAL "ELF" )
588
585
if ("${libkind} " STREQUAL "SHARED" )
589
586
set (arch_subdir "${SWIFTLIB_DIR} /${SWIFTLIB_SINGLE_SUBDIR} " )
590
587
591
588
set (SWIFT_SECTIONS_OBJECT_BEGIN "${arch_subdir} /swift_begin.o" )
592
589
set (SWIFT_SECTIONS_OBJECT_END "${arch_subdir} /swift_end.o" )
593
590
endif ()
594
-
595
591
endif ()
596
592
597
593
# FIXME: don't actually depend on the libraries in SWIFTLIB_SINGLE_LINK_LIBRARIES,
You can’t perform that action at this time.
0 commit comments