Skip to content

[preset] Add sourcekit-lsp to swiftpm PR presets #23136

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 7, 2019
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
13 changes: 4 additions & 9 deletions cmake/modules/SwiftSource.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ function(_compile_swift_files
if (SWIFTFILE_IS_STDLIB)
list(APPEND swift_flags "-swift-version" "5")
endif()

# Force swift 4 compatibility mode for overlays.
if (SWIFTFILE_IS_SDK_OVERLAY)
list(APPEND swift_flags "-swift-version" "4")
Expand Down Expand Up @@ -344,16 +344,11 @@ function(_compile_swift_files
list(APPEND module_outputs "${interface_file}")
endif()

set(optional_arg)
if(sdk IN_LIST SWIFT_APPLE_PLATFORMS)
# Allow installation of stdlib without building all variants on Darwin.
set(optional_arg "OPTIONAL")
endif()

if(SWIFTFILE_SDK IN_LIST SWIFT_APPLE_PLATFORMS)
swift_install_in_component("${SWIFTFILE_INSTALL_IN_COMPONENT}"
DIRECTORY "${specific_module_dir}"
DESTINATION "lib${LLVM_LIBDIR_SUFFIX}/swift/${library_subdir}")
DESTINATION "lib${LLVM_LIBDIR_SUFFIX}/swift/${library_subdir}"
OPTIONAL)
else()
swift_install_in_component("${SWIFTFILE_INSTALL_IN_COMPONENT}"
FILES ${module_outputs}
Expand Down Expand Up @@ -439,7 +434,7 @@ function(_compile_swift_files
set(file_path "${CMAKE_CURRENT_BINARY_DIR}/${file_name}.txt")
string(REPLACE ";" "'\n'" source_files_quoted "${source_files}")
file(WRITE "${file_path}" "'${source_files_quoted}'")

# If this platform/architecture combo supports backward deployment to old
# Objective-C runtimes, we need to copy a YAML file with legacy type layout
# information to the build directory so that the compiler can find it.
Expand Down
14 changes: 14 additions & 0 deletions utils/build-presets.ini
Original file line number Diff line number Diff line change
Expand Up @@ -1380,6 +1380,12 @@ assertions
llbuild
swiftpm

sourcekit-lsp

install-swift
install-llbuild
install-swiftpm

dash-dash

skip-test-swift
Expand All @@ -1405,6 +1411,14 @@ xctest
foundation
libdispatch
llbuild
sourcekit-lsp

install-swift
install-llbuild
install-swiftpm
install-foundation
install-libdispatch
install-xctest

skip-test-swift
skip-test-cmark
Expand Down