File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed
Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change 1+ # Swift compiler currently assumes that the Darwin overlay is a dependency of
2+ # CxxStdlib, and fails to build CxxStdlib if Darwin.swiftmodule in build dir
3+ # is built with a different (older) version of the compiler. To workaround this,
4+ # declare the Darwin overlay as a dependency of CxxStdlib.
5+ set (swift_cxxstdlib_darwin_dependencies)
6+ if (SWIFT_BUILD_STDLIB AND (SWIFT_BUILD_SDK_OVERLAY OR SWIFT_BUILD_TEST_SUPPORT_MODULES))
7+ set (swift_cxxstdlib_darwin_dependencies Darwin)
8+ endif ()
9+
110#
211# C++ Standard Library Overlay.
312#
@@ -6,6 +15,11 @@ add_swift_target_library(swiftCxxStdlib STATIC NO_LINK_NAME IS_STDLIB IS_SWIFT_O
615 String .swift
716
817 SWIFT_MODULE_DEPENDS Cxx
18+ SWIFT_MODULE_DEPENDS_IOS ${swift_cxxstdlib_darwin_dependencies}
19+ SWIFT_MODULE_DEPENDS_OSX ${swift_cxxstdlib_darwin_dependencies}
20+ SWIFT_MODULE_DEPENDS_TVOS ${swift_cxxstdlib_darwin_dependencies}
21+ SWIFT_MODULE_DEPENDS_WATCHOS ${swift_cxxstdlib_darwin_dependencies}
22+ SWIFT_MODULE_DEPENDS_MACCATALYST ${swift_cxxstdlib_darwin_dependencies}
923
1024 SWIFT_COMPILE_FLAGS ${SWIFT_RUNTIME_SWIFT_COMPILE_FLAGS} ${SWIFT_STANDARD_LIBRARY_SWIFT_FLAGS}
1125 -Xfrontend -enable-experimental-cxx-interop
You can’t perform that action at this time.
0 commit comments