Skip to content

Commit a89d20b

Browse files
committed
Disable ASTGen runtime-compat libs
The runtime compat libraries are not available during the stage-0 compiler ASTGen build. As a result, the compiler fails to link because the compat symbols are not available. Once we have better stage tracking, we should turn this on for stages after the compat56 library has been built. Turning it off for now is safe enough because the ASTGen library doesn't use concurrency, and thus far, that is the only area with backdeployed fixes.
1 parent 97806c9 commit a89d20b

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

lib/ASTGen/CMakeLists.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,13 @@ if (SWIFT_SWIFT_PARSER)
3232
Sources/ASTGen/Types.swift
3333
)
3434

35+
# The compat56 library is not available during a stage-0 compiler build.
36+
# Once we have proper stage tracking, we should turn this on for stages that
37+
# are guaranteed to have the compatibility libraries.
38+
target_compile_options(swiftASTGen PRIVATE
39+
$<$<COMPILE_LANGUAGE:Swift>:-runtime-compatibility-version>
40+
$<$<COMPILE_LANGUAGE:Swift>:none>)
41+
3542
# Set the appropriate target triple.
3643
if(SWIFT_HOST_VARIANT_SDK IN_LIST SWIFT_DARWIN_PLATFORMS)
3744
set(DEPLOYMENT_VERSION "${SWIFT_SDK_${SWIFT_HOST_VARIANT_SDK}_DEPLOYMENT_VERSION}")

0 commit comments

Comments
 (0)