Skip to content

[CMake] Always build the "non-overlay" apinotes #16851

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
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
9 changes: 3 additions & 6 deletions cmake/modules/AddSwift.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -719,9 +719,9 @@ function(_add_swift_library_single target name)
${SWIFTLIB_SINGLE_SDK} STREQUAL "OSX")
# HACK: don't build WatchKit API notes for OS X.
else()
if (NOT IS_DIRECTORY "${SWIFT_SOURCE_DIR}/stdlib/public/SDK/${framework_name}")
list(APPEND SWIFTLIB_SINGLE_API_NOTES "${framework_name}")
endif()
# Always build the "non-overlay" apinotes to keep them in sync
Copy link
Contributor

Choose a reason for hiding this comment

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

Comment nitpick: this is saying "Always build all API notes", not just the non-overlay ones.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Well, it's building all the apinotes found in swift/apinotes/, but I can adjust the comment.

# rdar://40496966
list(APPEND SWIFTLIB_SINGLE_API_NOTES "${framework_name}")
endif()
endforeach()
endif()
Expand All @@ -732,9 +732,6 @@ function(_add_swift_library_single target name)
else()
string(REPLACE swift "" module_name "${name}")
endif()
if("${module_name}" IN_LIST SWIFT_API_NOTES_INPUTS)
set(SWIFTLIB_SINGLE_API_NOTES "${module_name}")
endif()

if("${SWIFTLIB_SINGLE_SDK}" STREQUAL "WINDOWS")
swift_windows_include_for_arch(${SWIFTLIB_SINGLE_ARCHITECTURE} SWIFTLIB_INCLUDE)
Expand Down