Commit Graph

8465 Commits

Author SHA1 Message Date
Mishal Shah
c9bdc6be7c [update-checkout] Swift 6.2 release branch support
(cherry picked from commit dbf648b172)
2025-04-03 23:44:52 -07:00
Doug Gregor
e49afc8797 Merge pull request #80389 from 3405691582/nobtcfi
Add a build flavor to opt-out of BTCFI on OpenBSD.
2025-04-03 13:29:04 -07:00
Brian Michel
c0c9116bd6 Remove cache configuration from EanbleCaching
EnableCaching should only configure cmake to allow for sccache usage, it
should not configure sccache itself in any way. Those configuration
options should be deferred into the environment variables that sccache
will look for when it starts up.
2025-04-01 11:13:06 -04:00
Brian Michel
09664ee7cb Add remote caching option
When setting up sccache we can choose between local disk caching or
remote caching via an S3-ish blob storage engine. To allow for backward
compatibility for anyone that might be using the existing option for
disk caching we leave it place and instead provide a new remote caching
option.

This option assumes you've read the sccache documentation for setting up
the correct environment variables for telling sccache where to find the
bucket and how to authenticate to it.
2025-03-31 19:28:35 -04:00
Saleem Abdulrasool
36af875572 Merge pull request #80289 from jeffdav/win-build-compilers-test-split
utils: Breakup Build-Compilers into Build- and Test- steps.
2025-03-29 17:19:47 -07:00
3405691582
a341ce5570 Add a build flavor to opt-out of BTCFI on OpenBSD.
To work-around #80059, we need to stop return address signing and
opt-out of BTCFI enforcement via enabling a platform linker option.

We don't want to completely undo the BTCFI work in the rare case that
we later figure out how to properly address the above issue, or allow
users who might want to benefit from BTCFI enforcement and won't use
Concurrency. To do this, condition the existing BTCFI flag enforcement
into a configuration option that defaults to off for now.

Because the new swift-driver needs to "know" whether the frontend is
configured to opt-out or not, and since the new driver communicates with
the frontend via the target info JSON to begin with, we add a field
that emits the build flavor to signal the right behavior.
2025-03-29 10:47:23 -04:00
Saleem Abdulrasool
f3329376ca Merge pull request #80341 from compnerd/new-currency
utils: enable swift_Concurrency on the new build
2025-03-28 13:47:35 -07:00
Jeff
4f8af6cc9c utils: Breakup Build-Compilers into Build- and Test- steps. 2025-03-27 18:27:40 -07:00
Saleem Abdulrasool
d644044c1c Merge pull request #80336 from jeffdav/win-build-summary-sort
utils: Fix build.ps1 summary sorting.
2025-03-27 13:26:05 -07:00
Saleem Abdulrasool
075b973f98 utils: enable swift_Concurrency on the new build
Enable the Concurrency runtime for the experimental runtime builds on
Windows. This is required to enable the use of the static runtime to
bootstrap the early swift-driver.
2025-03-27 08:31:45 -07:00
Jeff
92b0849a56 utils: Fix build.ps1 summary sorting. 2025-03-26 22:02:42 -07:00
Saleem Abdulrasool
f042eb8755 Merge pull request #80323 from jeffdav/win-build-fix-android-os-enum-refs
utils: Fix Android OS enum usage in function params.
2025-03-26 20:05:39 -07:00
Jeff
f863570499 utils: Fix Android OS enum usage in function params. 2025-03-26 15:21:24 -07:00
Max Desiatov
eb1a2960b6 Enable _Concurrency for Embedded Swift with WASI (#79292)
WASI with Embedded Swift provides WASI-libc and libc++ headers necessary to build the `_Concurrency` module for Wasm. We now add `wasm32-unknown-wasip1-wasm` triple to `EMBEDDED_STDLIB_TARGET_TRIPLES` when `SWIFT_WASI_SYSROOT_PATH` is set, which builds the necessary stdlib slice.

---------

Co-authored-by: Yuta Saito <kateinoigakukun@gmail.com>
2025-03-26 21:14:05 +00:00
Jeff
828a3470e8 utils: Add back missing ToolchainInstallRoot properties. 2025-03-25 21:43:36 -07:00
Evan Wilde
521e2f66b2 Merge pull request #80276 from etcwilde/ewilde/build-cmake-before-ninja
[build-script] Build CMake before Ninja
2025-03-25 15:22:40 -07:00
Evan Wilde
813ed210b3 [build-script] Build CMake before Ninja
Ninja requires CMake 3.15 or newer to build, while the CMake on Amazon
Linux 2 is only 2.8. We bootstrap a newer CMake anyway, so build it
before Ninja so that Ninja has a new enough CMake.
2025-03-25 10:23:47 -07:00
Saleem Abdulrasool
0819b437ef Merge pull request #80181 from jeffdav/win-build-platforms
utils: Convert build.ps1 to use Platform definitions.
2025-03-25 08:28:45 -07:00
Jeff
f3c95329bc PR Feedback. 2025-03-24 13:28:44 -07:00
Evan Wilde
321c8208f5 [build-script] Create time log dir
If the directory where the build time log is supposed to go doesn't
exist, create it. The append file mode will create files, but won't
create directories. When we start building ninja, we haven't necessary
created the build directory yet, so this results in an error about the
missing directory when writing the build time log.
2025-03-24 08:33:35 -07:00
Evan Wilde
bbd412b0dc Revert "[build-script] Remove ninja build time tracking"
This reverts commit fb4799f5d1.
2025-03-24 08:30:29 -07:00
Evan Wilde
fb4799f5d1 [build-script] Remove ninja build time tracking
Logging the build time is failing because the build log time file
doesn't always exist by the time Ninja is getting brought up.
2025-03-24 08:09:11 -07:00
Jeff
498f8f7909 Add fixme. 2025-03-21 11:05:15 -07:00
Jeff
dd6f1c29b3 Fix missing param. 2025-03-21 10:18:44 -07:00
Mishal Shah
deb1d9696d Merge pull request #80199 from etcwilde/ewilde/remove-ninja-host
[build-script] Remove ninja host
2025-03-21 09:43:50 -07:00
Evan Wilde
bafbfa2d46 [build-script] Remove ninja host
The ninja builder took a host argument that was unused by the function.
The ninja build failed to pass this argument, resulting in
an execution failure. Removing the argument.
2025-03-21 08:55:19 -07:00
Jeff
b150d4c94e PR Feedback 2. 2025-03-20 21:57:27 -07:00
Jeff
3daeb9c7b9 PR Feedback. 2025-03-20 17:08:41 -07:00
Jeff
643f904353 utils: Handle additional args to Invoke-BuildStep in build.ps1. 2025-03-20 15:17:27 -07:00
Jeff
ad744421fd utils: Convert build.ps1 to use Platform definitions. 2025-03-20 15:17:25 -07:00
Saleem Abdulrasool
1289c9614e Merge pull request #80092 from compnerd/versioning
utils: version testing frameworks
2025-03-20 10:20:40 -07:00
Saleem Abdulrasool
1e74bdffa0 Merge branch 'main' into timing 2025-03-19 22:28:46 -07:00
Saleem Abdulrasool
8e10b00984 Merge pull request #80148 from weliveindetail/windrd-unblock-nightly
utils: temporarily ignore test failure for Android runtimes
2025-03-19 21:42:57 -07:00
Saleem Abdulrasool
1b1274f7c1 Merge pull request #80125 from hjyamauchi/foundationmacros
Fix FoundationMacro build failure in ARM64 cross-build
2025-03-19 20:13:36 -07:00
Saleem Abdulrasool
440ebee0bb utils: collect more build times
Add time collection for the test execution. This will allow us to
immediately see in the summary the time expenditure.
2025-03-19 16:54:43 -07:00
Saleem Abdulrasool
89e9681592 utils: remove extra timing data collection
The timing data collection is now homed under `Invoke-BuildStep`.
`Build-SPMProject` is an implementation detail of the build step and is
timed at a higher level.
2025-03-19 16:53:35 -07:00
Saleem Abdulrasool
befc15e6df Merge pull request #80082 from compnerd/isolated
utils: split `Build-*` into `Build-` and `Test-`
2025-03-19 16:31:04 -07:00
Stefan Gränitz
123b25d20a utils: temporarily ignore test failure for Android runtimes 2025-03-20 00:16:56 +01:00
Evan Wilde
f5f79f056f Merge pull request #80102 from etcwilde/ewilde/choose-built-ninja
[build-script]: Automatically choose a built ninja
2025-03-19 15:28:15 -07:00
Saleem Abdulrasool
f20ff950ec utils: split Build-Dispatch into Build- and Test- function
Split up the test routines from the build routines. This is motivated by
the desire to simplify (remove logic flow) and to help get more accurate
timing data.
2025-03-19 11:13:43 -07:00
Saleem Abdulrasool
ae1f4cae7b utils: split Build-Foundation into Build- and Test- function
Split up the test routines from the build routines. This is motivated by
the desire to simplify (remove logic flow) and to help get more accurate
timing data.
2025-03-19 11:13:42 -07:00
Saleem Abdulrasool
789bd1fc0d utils: split Build-Testing into Build- and Test- function
Split up the test routines from the build routines. This is motivated by
the desire to simplify (remove logic flow) and to help get more accurate
timing data.
2025-03-19 11:12:03 -07:00
Saleem Abdulrasool
2c02471271 utils: split Build-LLBuild into Build- and Test- function
Split up the test routines from the build routines. This is motivated by
the desire to simplify (remove logic flow) and to help get more accurate
timing data.
2025-03-19 11:12:03 -07:00
Saleem Abdulrasool
e7c8dc66ad utils: remove extraneous parameter (NFC)
The callee does not take any parameters, remove the extra leftover
parameter.
2025-03-19 11:12:03 -07:00
Hiroshi Yamauchi
2ff8806fa8 Fix FoundationMacro build failure in ARM64 cross-build 2025-03-19 10:54:58 -07:00
Saleem Abdulrasool
6ead8cb5bd utils: correct straggling function replacement 2025-03-19 09:00:06 -07:00
Alex Hoppen
d870056efd Merge pull request #80076 from ahoppen/foundation-tests-debug
[tests] Run swift-(corelibs-)foundation tests in debug configuration on Windows
2025-03-19 08:16:30 -07:00
Evan Wilde
9402a1689b Automatically choose a built ninja
Instead of using `--build-ninja` to decide to build ninja, build it
automatically if a sufficiently new enough version is not available.
Also record the build time taken to build the local Ninja so that we can
see how much time we would save by stashing a pre-built Ninja in CI.
2025-03-19 07:35:32 -07:00
Saleem Abdulrasool
f457d9ccd4 Merge pull request #80099 from hjyamauchi/minjectverbose
Make minject not verbose
2025-03-18 21:28:23 -07:00
Evan Wilde
012ac5da5d Merge pull request #80093 from etcwilde/ewilde/ninja-skip-build-testing
Disable building Ninja tests
2025-03-18 14:28:27 -07:00