Commit Graph

7219 Commits

Author SHA1 Message Date
Finagolfin
a03f6e5b3a [Build] Enable building and CI testing the early Swift Driver on linux with the prebuilt host toolchain 2023-11-08 20:09:59 +05:30
Alexander Smarus
065ebc4a86 utils: adjust build.ps1 help invocation in helper launcher
As the helper script could (and probably always would) be launched from
a directory outside of the source tree, it is convenient to use an absolute path
in Get-Help invocation, just like we do in the `build.ps1` invocation below.
Also, quoting might be necessary for paths with spaces.
2023-11-07 16:09:36 +02:00
Saleem Abdulrasool
2e348d2bc0 Merge pull request #69575 from compnerd/stage
build: adjust the installer build and artifact staging
2023-11-07 13:44:42 +00:00
Saleem Abdulrasool
c80901b17e Merge pull request #69651 from compnerd/shaving
build: tweak the Windows build to build against the internal swift-syntax
2023-11-06 05:12:20 -08:00
Saleem Abdulrasool
48715298d4 build: add additional download checking for the image
Ensure that the downloaded image matches the expected image.  This
ensures that we catch download errors as well as provides some level of
security by requiring that the download checksum matches.
2023-11-05 08:51:34 -08:00
Saleem Abdulrasool
f7cd9ab1c0 build: tweak the Windows build to build against the internal swift-syntax
Use the internal copy of swift-syntax that the compiler uses for macros
to build the LSP. By sharing the swift-syntax build, we shave ~6MiB off
the LSP binary. Additionally, we avoid building swift-syntax twice as a
single copy is now used.
2023-11-03 16:02:56 -07:00
Anthony Latsis
da6dff3ef5 Merge pull request #68713 from AnthonyLatsis/test-generate-xcode 2023-11-03 23:57:20 +03:00
Saleem Abdulrasool
5da8b3fa09 build: adjust the installer build and artifact staging
Adjust the installer to allow it to be built for foreign architectures.
Additionally, adjust the artifact staging to include additional content
that was missed previously in order to enable code signing.
2023-11-03 13:24:09 -07:00
Saleem Abdulrasool
7ad55267e9 build: add more checking for errors
Apply more error checking to ensure that failures do not slip through
the various layers of invocation.
2023-11-02 10:32:19 -07:00
Saleem Abdulrasool
cb4d0b930b update_checkout: update the next scheme to match main
Update next to match main for dependencies. This includes:
- CURL
- ICU
- libxml2
- zlib
2023-11-01 14:38:10 -07:00
Saleem Abdulrasool
247d56847d build: update update-checkout to ICU 69
Unify the non-Darwin targets to ICU 69. Windows has been using ICU 69
since 5.3, Linux was at 65.
2023-11-01 14:16:15 -07:00
Saleem Abdulrasool
4fb2614e6c build: update build.ps1, use update-checkout for more dependencies
Update the build.ps1 to match the current state which introduces
`-BuildTo` and updates most of the dependencies. Take the opportunity to
migrate to update-checkout for the majority of the dependencies. The
SQLite amalgamation and installer image are still fetched later, and ICU
is still cloned in the CI wrapper.
2023-11-01 14:16:15 -07:00
Saleem Abdulrasool
6a81131385 Merge pull request #69553 from compnerd/compnerd/launcher
utils: add a helper to launch build.ps1
2023-11-01 07:52:02 -07:00
Saleem Abdulrasool
0969d1ef9f Merge pull request #69554 from compnerd/cleanup
utils: remove `build-windows.bat`
2023-11-01 07:51:34 -07:00
Alex Hoppen
dc689ab07e [build] Adjustment to reflect that we re-wrote swift-syntax/format.py in Swift 2023-10-31 21:50:42 -07:00
Alex Hoppen
04f950c084 [build] Verify that SourceKit-LSP is correctly formatted
In sourcekit-lsp and swift-format, run swift-format on the sourcekit-lsp sources to make sure it’s correctly formatted.
2023-10-31 17:10:51 -07:00
Saleem Abdulrasool
26aa2fbfbe utils: remove build-windows.bat
We have been using `build-windows-toolchain.bat` for a while now.
However, that too is now a wrapper around `build.ps1`. This new script
is meant to be used as a *developer* tool, for daily usage. It has
enough control to enable us to use that with some setup from Jenkins as
a means for building the code as well. Remove some of the older scripts.
2023-10-31 14:54:01 -07:00
Saleem Abdulrasool
93b20aa985 utils: add a helper to launch build.ps1
When using build.ps1 as a developer, we may be working in a shell that
does not have the ability to run the PowerShell script due to signing.
Add a little helper that launches the script properly to not require the
user to disable code signature on scripts.
2023-10-31 14:49:46 -07:00
Saleem Abdulrasool
6589897677 Merge pull request #69461 from capricorn/capricorn/vim-comment-hl-fix
[VIM] Fix syntax highlighting of nested comments
2023-10-31 14:36:02 -07:00
Tristan Labelle
3a863c4825 Migrate the Windows build to build.ps1, a new build script (#69337)
* Switch to build.ps1
* Update build.ps1 to the latest
* Update to latest build.ps1
* Update build-windows-toolchain.bat
- Update the curl pin to 8.4.0
- Stage artifacts to expected location
* Update build.ps1
Stage cabs and MSIs as well.
* Update build.ps1
* Update build.ps1

---------

Co-authored-by: Saleem Abdulrasool <compnerd@compnerd.org>
2023-10-31 14:11:19 -07:00
Mike Ash
6606850232 [Runtime] Add option to remove override point for retain/release.
Add a `SWIFT_STDLIB_OVERRIDABLE_RETAIN_RELEASE` CMake option. When set to true, swift_retain/release and the other functions in InstrumentsSupport.h can be overridden by setting the appropriate global function pointer, as is already the case. When set to false, those function pointers are removed and the functions always go into the default implementation.

Set `SWIFT_STDLIB_OVERRIDABLE_RETAIN_RELEASE` to false when building the minimal stdlib, and set it to true otherwise by default.

rdar://115987924
2023-10-31 15:26:01 -04:00
Mishal Shah
9e7d9277c8 Merge pull request #69134 from yim-lee/fix-swift-certs-1.x
[update-checkout] Update package versions in 'release/5.10' block
2023-10-30 21:25:30 -07:00
Saleem Abdulrasool
7e4fa781ea Merge pull request #69431 from compnerd/engine
build: extract the WiX engine during the CI job
2023-10-28 10:24:27 -07:00
Saleem Abdulrasool
405ea047da build: extract the WiX engine during the CI job
Extract the installer engine for simplifying the code signing process.
We need to currently shuffle files around more than necessary to just
extract the installer engine, this will allow us to skip that step.
2023-10-27 15:25:08 -07:00
Karoy Lorentey
eea3d66453 Merge pull request #69445 from lorentey/stdlib-5.11
[5.11][stdlib] Bump runtime version indicator to 5.11
2023-10-27 11:19:04 -07:00
capricorn
3494a23400 [VIM] Fix syntax highlighting of nested comments
This example incorrectly highlights 'foo' as a comment:
/* // */ foo

This example does as well:
// /*
foo
*/ foo
2023-10-27 10:23:25 -06:00
Jonas Devlieghere
eada8d60aa [utils] Enable lldb in Linux smoke testing 2023-10-26 17:04:44 -07:00
Karoy Lorentey
afd80c33f6 [stdlib] SwiftStdlib 5.11 as a version macro 2023-10-26 14:11:58 -07:00
Kavon Farvardin
5b23b23ffa Merge pull request #69402 from kavon/noncopyable-generics-stdlib
[NoncopyableGenerics] provide stdlib build option
2023-10-25 16:32:42 -07:00
Alex Hoppen
12b500878c Merge pull request #69388 from ahoppen/ahoppen/remove-swiftevolve
[build] Remove swiftevolve
2023-10-25 12:43:14 -07:00
Kavon Farvardin
3da894d704 [NoncopyableGenerics] provide stdlib build option
This helps set the stage for getting the stdlib building
correctly with `NoncopyableGenerics` enabled. Disabled by
default for now so this is an NFC.
2023-10-25 09:27:36 -07:00
Yuta Saito
1e5f69b3ee Merge pull request #69101 from kateinoigakukun/yt/wasm-stdlib-product-pr
[wasm][build] Build stdlib and test IRGen for WebAssembly
2023-10-24 22:23:54 -07:00
Yuta Saito
d47b00adac Merge pull request #68750 from kateinoigakukun/yt/enable-llvm-wasm-target
Enable WebAssembly target in LLVM backend by default
2023-10-24 22:21:23 -07:00
Alex Hoppen
6a8ad4b91e [build] Remove swiftevolve
swift-evolve hasn’t been used in the recent past. @beccadax and I agreed that it doesn’t provide any value anymore to keep swift-evolve around. In Becca’s words:

> The resilience implementation is pretty stable at this point, and it never seems to have had many of the bugs that swift-evolve would have been able to shake out.
2023-10-24 18:36:59 -07:00
Alex Hoppen
fdc8e7d387 Merge pull request #69294 from ahoppen/ahoppen/semantic-tokens
[SourceKit] Add a request to get the semantic tokens of a file
2023-10-24 08:07:41 -07:00
Yuta Saito
37d11c91e5 [wasm][build] Skip wasi-libc symbol check step to support LLVM 17 2023-10-24 00:07:28 +00:00
Anthony Latsis
7b5db49ce2 Merge pull request #69063 from AnthonyLatsis/preset-cleanup
[NFC] Presets: Small cleanup
2023-10-23 20:49:33 +03:00
Yuta Saito
e1c4eceea3 [wasm][build] Build and test stdlib for WebAssembly
This patch adds a new build products to build and test the Swift stdlib
for WebAssembly.
This adds WebAssembly specific stdlib product instead of adding the new
target in `stdlib-deployment-targets` because unlike darwin platforms
Wasm target has quite different stdlib configuration from host target
and there is no way to specify different stdlib configuration for each
target in `stdlib-deployment-targets` for now.

This patch adds 1 new dependency `wasi-libc` and 3 new build products:
1. `WASILibc` - wasi-libc is a libc implementation for WebAssembly
   System Interface (WASI). This product is required to build the
   compiler runtimes and Swift stdlib.
2. `WasmLLVMRuntimeLibs` - This product builds `./runtimes` directory
   in llvm-project, which contains compiler-rt, libcxx and libcxxabi.
   This product is required to build Swift stdlib.
3. `WasmStdlib` - This product builds standalone Swift stdlib for
   WebAssembly. (Similar to `MinimalStdlib` product, but configured for
   WebAssembly target)
2023-10-23 17:34:20 +00:00
Anthony Latsis
f87a2bf0d6 [NFC] Presets: Small cleanup
* Remove some options that are implied by a base preset.
* Remove unused preset for building with Xcode.
2023-10-23 18:19:10 +03:00
Alex Hoppen
4bc03f8392 [SourceKit] Add a request to get the semantic tokens of a file
We need this request for semantic highlighting in LSP. Previously, we were getting the semantic tokens using a 0,0 edit after a document update notification but that will no longer be possible if we open the documents in syntactic only mode.
2023-10-20 10:38:08 -07:00
Evan Wilde
312bd47f4c Merge remote-tracking branch 'main' into 'rebranch' 2023-10-16 23:00:12 -07:00
Eric Miotto
ef5492d98f Reduce rebuilds when running buildbot_incremental presets in succession (#69167)
We have some configurations in which we run a preset that only builds
the compiler, and then a few ones to tests such binary, e.g.

```
buildbot_incremental,tools=RA,stdlib=RD,build
buildbot_incremental,tools=RA,stdlib=RD,test=macOS,type=device
buildbot_incremental,tools=RA,stdlib=RD,test=iOS,type=simulator
buildbot_incremental,tools=RA,stdlib=RD,test=watchOS,type=simulator
```

Contrary to the other presets, in the first preset we did not specify
"--lit-args" since it is not necessary -- however that plays a part in
the configuration of compiler-rt, causing an unwanted rebuild when that
parameter is specified in the following preset.

Addresses rdar://116922016
2023-10-16 12:03:42 -07:00
Mishal Shah
3594f8ecaf Merge remote-tracking branch 'origin/main' into rebranch
Conflicts:
	test/IRGen/opaque-pointer-llvm.swift
2023-10-15 23:49:40 -07:00
Alex Hoppen
5b60aad022 Merge pull request #68120 from StevenWong12/move_swift_parser_cli 2023-10-14 17:21:55 -07:00
Saleem Abdulrasool
0af4108471 Merge pull request #69182 from compnerd/redist
build: bundle the VC redist in the installer
2023-10-14 09:37:49 -07:00
Alex Hoppen
99c08345ec Merge pull request #69084 from ahoppen/ahoppen/swift-crypto-sourcekit-lsp 2023-10-14 07:16:17 -07:00
Saleem Abdulrasool
ec1159ae02 Update build-windows-toolchain.bat 2023-10-13 20:53:26 -07:00
Saleem Abdulrasool
56e3c44461 build: bundle the VC redist in the installer
With the work to enable ARM64, we need to package the redistributable
into the toolchain to allow distribution via winget.  This is also
important to make the runtime work without additional packaging.
2023-10-13 17:30:36 -07:00
Saleem Abdulrasool
6740472064 Use clang-cl from prebuilt toolchain
This should avoid the internal dependency on the just built clang being for the build.
2023-10-13 10:53:18 -07:00
Mishal Shah
181ec1c316 Update the main git scheme to use stable/20230725 2023-10-12 23:41:43 -07:00