Skip to content

Commit 3c95348

Browse files
authored
Merge pull request #29342 from compnerd/bs-options
build-script: generate options (NFC)
2 parents a989b8a + 45af79d commit 3c95348

File tree

1 file changed

+25
-54
lines changed

1 file changed

+25
-54
lines changed

utils/build-script-impl

Lines changed: 25 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -115,96 +115,54 @@ KNOWN_SETTINGS=(
115115
darwin-xcrun-toolchain "default" "the name of the toolchain to use on Darwin"
116116

117117
## Build Types for Components
118-
cmark-build-type "Debug" "the CMake build variant for CommonMark (Debug, RelWithDebInfo, Release, MinSizeRel). Defaults to Debug."
119-
foundation-build-type "Debug" "the build variant for Foundation"
120-
libdispatch-build-type "Debug" "the build variant for libdispatch"
121-
libicu-build-type "Debug" "the build variant for libicu"
122-
llbuild-build-type "Debug" "the CMake build variant for llbuild"
123-
lldb-build-type "Debug" "the CMake build variant for LLDB"
124-
llvm-build-type "Debug" "the CMake build variant for LLVM and Clang (Debug, RelWithDebInfo, Release, MinSizeRel). Defaults to Debug."
125-
playgroundsupport-build-type "Debug" "the build variant for PlaygroundSupport"
126-
swift-build-type "Debug" "the CMake build variant for Swift"
127118
swift-stdlib-build-type "Debug" "the CMake build variant for Swift"
128-
xctest-build-type "Debug" "the build variant for xctest"
129119

130120
## Skip Build ...
131121
skip-build-android "" "set to skip building Swift stdlibs for Android"
132122
skip-build-benchmarks "" "set to skip building Swift Benchmark Suite"
133123
skip-build-clang-tools-extra "" "set to skip building clang-tools-extra as part of llvm"
134-
skip-build-cmark "" "set to skip building CommonMark"
135124
skip-build-compiler-rt "" "set to skip building Compiler-RT"
136125
skip-build-cygwin "" "set to skip building Swift stdlibs for Cygwin"
137126
skip-build-external-benchmarks "1" "set to skip building the external Swift Benchmark Suite. (skipped by default)"
138-
skip-build-foundation "" "set to skip building foundation"
139127
skip-build-freebsd "" "set to skip building Swift stdlibs for FreeBSD"
140128
skip-build-haiku "" "set to skip building Swift stdlibs for Haiku"
141129
skip-build-ios-device "" "set to skip building Swift stdlibs for iOS devices (i.e. build simulators only)"
142130
skip-build-ios-simulator "" "set to skip building Swift stdlibs for iOS simulators (i.e. build devices only)"
143-
skip-build-libcxx "" "set to skip building libcxx"
144-
skip-build-libdispatch "" "set to skip building libdispatch"
145-
skip-build-libicu "" "set to skip building libicu"
146131
skip-build-linux "" "set to skip building Swift stdlibs for Linux"
147-
skip-build-llbuild "" "set to skip building llbuild"
148-
skip-build-lldb "" "set to skip building LLDB"
149-
skip-build-llvm "" "set to skip building LLVM/Clang"
150132
skip-build-maccatalyst "" "set to skip building Swift stdlibs for macCatalyst"
151133
skip-build-osx "" "set to skip building Swift stdlibs for OS X"
152-
skip-build-playgroundsupport "" "set to skip building PlaygroundSupport"
153-
skip-build-static-foundation "" "set to skip building static Foundation"
154-
skip-build-static-libdispatch "" "set to skip building static libdispatch"
155-
skip-build-swift "" "set to skip building Swift"
156134
skip-build-tvos-device "" "set to skip building Swift stdlibs for tvOS devices (i.e. build simulators only)"
157135
skip-build-tvos-simulator "" "set to skip building Swift stdlibs for tvOS simulators (i.e. build devices only)"
158136
skip-build-watchos-device "" "set to skip building Swift stdlibs for Apple watchOS devices (i.e. build simulators only)"
159137
skip-build-watchos-simulator "" "set to skip building Swift stdlibs for Apple watchOS simulators (i.e. build devices only)"
160-
skip-build-xctest "" "set to skip building xctest"
161138

162139
## Skip Test ...
163140
skip-test-android "" "set to skip testing Swift stdlibs for Android"
164141
skip-test-android-host "" "set to skip testing the host parts of the Android toolchain"
165-
skip-test-cmark "" "set to skip testing CommonMark"
166142
skip-test-cygwin "" "set to skip testing Swift stdlibs for Cygwin"
167-
skip-test-foundation "" "set to skip testing foundation"
168143
skip-test-freebsd "" "set to skip testing Swift stdlibs for FreeBSD"
169144
skip-test-haiku "" "set to skip testing Swift stdlibs for Haiku"
170145
skip-test-ios-32bit-simulator "" "set to skip testing Swift stdlibs for iOS 32bit simulators"
171146
skip-test-ios-host "" "set to skip testing the host parts of the iOS toolchain"
172147
skip-test-ios-simulator "" "set to skip testing Swift stdlibs for iOS simulators (i.e. test devices only)"
173-
skip-test-libdispatch "" "set to skip testing libdispatch"
174-
skip-test-libicu "" "set to skip testing libicu"
175148
skip-test-linux "" "set to skip testing Swift stdlibs for Linux"
176-
skip-test-llbuild "" "set to skip testing llbuild"
177-
skip-test-lldb "" "set to skip testing lldb"
178149
skip-test-maccatalyst "" "set to skip testing Swift stdlibs for macCatalyst"
179150
skip-test-osx "" "set to skip testing Swift stdlibs for OS X"
180-
skip-test-playgroundsupport "" "set to skip testing PlaygroundSupport"
181-
skip-test-swift "" "set to skip testing Swift"
182151
skip-test-tvos-host "" "set to skip testing the host parts of the tvOS toolchain"
183152
skip-test-tvos-simulator "" "set to skip testing Swift stdlibs for tvOS simulators (i.e. test devices only)"
184153
skip-test-watchos-host "" "set to skip testing the host parts of the watchOS toolchain"
185154
skip-test-watchos-simulator "" "set to skip testing Swift stdlibs for Apple watchOS simulators (i.e. test devices only)"
186-
skip-test-xctest "" "set to skip testing xctest"
187155
skip-test-benchmarks "" "set to skip running Swift Benchmark Suite"
188156
skip-test-optimized "" "set to skip testing the test suite in optimized mode"
189157
skip-test-optimize-for-size "" "set to skip testing the test suite in optimize for size mode"
190158
skip-test-optimize-none-with-implicit-dynamic "" "set to skip testing the test suite in optimize none with implicit dynamic mode"
191159
skip-test-sourcekit "" "set to skip testing SourceKit"
192160

193161
## Extra ... CMake Options
194-
cmark-cmake-options "" "CMake options used for all cmark targets"
195162
common-cmake-options "" "CMake options used for all targets, including LLVM/Clang"
196163
extra-cmake-options "" "Extra options to pass to CMake for all targets"
197-
foundation-cmake-options "" "CMake options used for all foundation targets"
198-
libdispatch-cmake-options "" "CMake options used for all libdispatch targets"
199-
libicu-cmake-options "" "CMake options used for all libicu targets"
200-
llbuild-cmake-options "" "CMake options used for all llbuild targets"
201-
lldb-cmake-options "" "CMake options used for all lldb targets"
202-
llvm-cmake-options "" "CMake options used for all llvm targets"
203164
ninja-cmake-options "" "CMake options used for all ninja targets"
204165
ninja-cmake-options "" "CMake options used for all ninja targets"
205-
playgroundsupport-cmake-options "" "CMake options used for all playgroundsupport targets"
206-
swift-cmake-options "" "CMake options used for all swift targets"
207-
xctest-cmake-options "" "CMake options used for all xctest targets"
208166

209167
## Build ...
210168
build-llvm "1" "set to 1 to build LLVM and Clang"
@@ -227,18 +185,6 @@ KNOWN_SETTINGS=(
227185
swift-include-tests "1" "Set to true to generate testing targets for Swift. This allows the build to proceed when 'test' directory is missing (required for B&I builds)"
228186
validation-test "0" "set to run the validation test suite"
229187

230-
## Install ...
231-
install-cmark "" "whether to install cmark"
232-
install-foundation "" "whether to install foundation"
233-
install-libcxx "" "whether to install libc++"
234-
install-libdispatch "" "whether to install libdispatch"
235-
install-libicu "" "whether to install libicu"
236-
install-llbuild "" "whether to install llbuild"
237-
install-lldb "" "whether to install LLDB"
238-
install-playgroundsupport "" "whether to install PlaygroundSupport"
239-
install-swift "" "whether to install Swift"
240-
install-xctest "" "whether to install xctest"
241-
242188
## llbuild Options
243189
llbuild-enable-assertions "1" "enable assertions in llbuild"
244190

@@ -296,6 +242,31 @@ KNOWN_SETTINGS=(
296242
skip-local-host-install "" "If we are cross-compiling multiple targets, skip an install pass locally if the hosts match"
297243
)
298244

245+
components=(
246+
cmark
247+
foundation
248+
libcxx
249+
libdispatch
250+
libicu
251+
llbuild
252+
lldb
253+
llvm
254+
playgroundsupport
255+
static-foundation
256+
static-libdispatch
257+
swift
258+
xctest
259+
)
260+
for component in ${components[@]} ; do
261+
KNOWN_SETTINGS+=(
262+
${component}-build-type "Debug" "the build variant for ${component}"
263+
${component}-cmake-options "" "CMake options used for ${component}"
264+
skip-build-${component} "" "set to skip building ${component}"
265+
skip-test-${component} "" "set to skip testing ${component}"
266+
install-${component} "" "whether to install ${component}"
267+
)
268+
done
269+
299270
# Centralized access point for traced command invocation.
300271
# Every operation that might mutates file system should be called via
301272
# these functions.

0 commit comments

Comments
 (0)