Skip to content

[Build System: CMake] Convert the SWIFT_STDLIB_BUILD_TYPE variable into a CMake cache variable in cmake/modules/StandaloneOverlay.cmake #24352

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 1 commit into from
Apr 30, 2019
Merged
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: 5 additions & 1 deletion cmake/modules/StandaloneOverlay.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,13 @@ endif()

set(CMAKE_INSTALL_PREFIX "${SWIFT_DEST_ROOT}${TOOLCHAIN_DIR}/usr")

set(SWIFT_STDLIB_BUILD_TYPE "Release" CACHE STRING
"Build type for the Swift standard library and SDK overlays [Debug, RelWithDebInfo, Release, MinSizeRel]")
set_property(CACHE SWIFT_STDLIB_BUILD_TYPE PROPERTY
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why the property? The set(...CACHE...) should be sufficient.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm just duplicating what's already in the top-level CMakeLists.txt file here.

STRINGS "Debug" "RelWithDebInfo" "Release" "MinSizeRel")

# Only happens if it's called from a top-level cmake invocation.
set(BUILD_STANDALONE TRUE)
set(SWIFT_STDLIB_BUILD_TYPE "Release")
set(SWIFT_SDK_OVERLAY_LIBRARY_BUILD_TYPES "SHARED")
set(SWIFT_INSTALL_COMPONENTS "sdk-overlay" CACHE STRING "")
set(SWIFT_DARWIN_DEPLOYMENT_VERSION_OSX "10.9" CACHE STRING "")
Expand Down