Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions tools/SourceKit/cmake/modules/AddSwiftSourceKit.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,9 @@ macro(add_sourcekit_library name)
set(libkind)
endif()
add_library(${name} ${libkind} ${srcs})
if(NOT SWIFT_BUILT_STANDALONE AND NOT CMAKE_C_COMPILER_ID MATCHES Clang)
add_dependencies(${name} clang)
endif()
llvm_update_compile_flags(${name})

set_output_directory(${name}
Expand Down Expand Up @@ -228,6 +231,9 @@ macro(add_sourcekit_executable name)
else()
add_executable(${name} ${SOURCEKITEXE_UNPARSED_ARGUMENTS})
endif()
if(NOT SWIFT_BUILT_STANDALONE AND NOT CMAKE_C_COMPILER_ID MATCHES Clang)
add_dependencies(${name} clang)
endif()
llvm_update_compile_flags(${name})
set_output_directory(${name}
BINARY_DIR ${SOURCEKIT_RUNTIME_OUTPUT_INTDIR}
Expand Down
3 changes: 3 additions & 0 deletions tools/libSwiftSyntaxParser/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ set(LLVM_EXPORTED_SYMBOL_FILE
add_swift_host_library(libSwiftSyntaxParser SHARED
c-include-check.c
libSwiftSyntaxParser.cpp)
if(NOT SWIFT_BUILT_STANDALONE AND NOT CMAKE_C_COMPILER_ID MATCHES Clang)
add_dependencies(libSwiftSyntaxParser clang)
endif()
target_link_libraries(libSwiftSyntaxParser PRIVATE
swiftParse)
set_target_properties(libSwiftSyntaxParser
Expand Down
3 changes: 3 additions & 0 deletions tools/swift-syntax-parser-test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ add_swift_host_tool(swift-syntax-parser-test
Support
SWIFT_COMPONENT tools
)
if(NOT SWIFT_BUILT_STANDALONE AND NOT CMAKE_C_COMPILER_ID MATCHES Clang)
add_dependencies(swift-syntax-parser-test clang)
endif()
target_link_libraries(swift-syntax-parser-test
PRIVATE
libSwiftSyntaxParser
Expand Down
3 changes: 3 additions & 0 deletions unittests/SyntaxParser/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ swift_swap_compiler_if_needed("SyntaxParserUnitTests")
add_swift_unittest(SwiftSyntaxParserTests
SyntaxParserTests.cpp
)
if(NOT SWIFT_BUILT_STANDALONE AND NOT CMAKE_C_COMPILER_ID STREQUAL Clang)
add_dependencies(SwiftSyntaxParserTests clang)
endif()

target_link_libraries(SwiftSyntaxParserTests
PRIVATE
Expand Down