File tree Expand file tree Collapse file tree 3 files changed +21
-12
lines changed Expand file tree Collapse file tree 3 files changed +21
-12
lines changed Original file line number Diff line number Diff line change @@ -93,6 +93,15 @@ option(SWIFT_INCLUDE_DOCS
93
93
"Create targets for building docs."
94
94
TRUE )
95
95
96
+ set (_swift_include_apinotes_default FALSE )
97
+ if (CMAKE_SYSTEM_NAME STREQUAL "Darwin" )
98
+ set (_swift_include_apinotes_default TRUE )
99
+ endif ()
100
+
101
+ option (SWIFT_INCLUDE_APINOTES
102
+ "Create targets for installing the remaining apinotes in the built toolchain."
103
+ ${_swift_include_apinotes_default} )
104
+
96
105
#
97
106
# Miscellaneous User-configurable options.
98
107
#
@@ -1052,12 +1061,8 @@ endif()
1052
1061
# https://bugs.swift.org/browse/SR-5975
1053
1062
add_subdirectory (stdlib )
1054
1063
1055
- if (SWIFT_BUILD_SDK_OVERLAY )
1056
- list_intersect ("${SWIFT_APPLE_PLATFORMS} " "${SWIFT_SDKS} "
1057
- building_darwin_sdks )
1058
- if (building_darwin_sdks )
1059
- add_subdirectory (apinotes )
1060
- endif ()
1064
+ if (SWIFT_INCLUDE_APINOTES )
1065
+ add_subdirectory (apinotes )
1061
1066
endif ()
1062
1067
1063
1068
add_subdirectory (include )
Original file line number Diff line number Diff line change @@ -31,7 +31,6 @@ add_custom_target("copy_apinotes"
31
31
# This is treated as an OPTIONAL target because if we don't build the SDK
32
32
# overlay, the files will be missing anyway. It also allows us to build
33
33
# single overlays without installing the API notes.
34
- swift_install_in_component (sdk-overlay
34
+ swift_install_in_component (compiler
35
35
DIRECTORY "${output_dir} "
36
- DESTINATION "lib/swift/"
37
- OPTIONAL )
36
+ DESTINATION "lib/swift/" )
Original file line number Diff line number Diff line change @@ -3,6 +3,13 @@ set(swift_platform_sources
3
3
TiocConstants.swift
4
4
tgmath.swift.gyb )
5
5
6
+ set (darwin_depends )
7
+ if (NOT BUILD_STANDALONE )
8
+ # This is overly conservative, but we have so few API notes files that
9
+ # haven't migrated to the Swift repo that it's probably fine in practice.
10
+ list (APPEND darwin_depends copy_apinotes )
11
+ endif ()
12
+
6
13
add_swift_target_library (swiftDarwin ${SWIFT_STDLIB_LIBRARY_BUILD_TYPES} IS_SDK_OVERLAY
7
14
Darwin.swift.gyb
8
15
${swift_platform_sources}
@@ -13,9 +20,7 @@ add_swift_target_library(swiftDarwin ${SWIFT_STDLIB_LIBRARY_BUILD_TYPES} IS_SDK_
13
20
LINK_FLAGS "${SWIFT_RUNTIME_SWIFT_LINK_FLAGS} "
14
21
TARGET_SDKS ALL_APPLE_PLATFORMS
15
22
16
- # This is overly conservative, but we have so few API notes files that
17
- # haven't migrated to the Swift repo that it's probably fine in practice.
18
- DEPENDS copy_apinotes )
23
+ DEPENDS ${darwin_depends} )
19
24
20
25
add_swift_target_library (swiftGlibc ${SWIFT_STDLIB_LIBRARY_BUILD_TYPES} IS_SDK_OVERLAY
21
26
Glibc.swift.gyb
You can’t perform that action at this time.
0 commit comments