Skip to content

Commit 8354c86

Browse files
committed
build: guard against builds where SwiftSyntax may not be enabled
Fix the build after swiftlang#69440
1 parent 103f716 commit 8354c86

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

lib/ASTGen/CMakeLists.txt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ set(compile_options
7171
"SHELL:-Xcc -UIBOutlet -Xcc -UIBAction -Xcc -UIBInspectable"
7272
)
7373

74-
foreach(target swiftASTGen swiftLLVMJSON)
75-
target_compile_options(${target} PRIVATE ${compile_options})
76-
endforeach()
74+
if(SWIFT_BUILD_SWIFT_SYNTAX)
75+
foreach(target swiftASTGen swiftLLVMJSON)
76+
target_compile_options(${target} PRIVATE ${compile_options})
77+
endforeach()
78+
endif()

0 commit comments

Comments
 (0)