about summary refs log tree commit diff
path: root/src/bootstrap
AgeCommit message (Collapse)AuthorLines
2022-12-19Fix arch flag on i686-apple-darwinMarcus Calhoun-Lopez-0/+3
i686-apple-darwin should use `-arch i386` instead of `-arch i686`
2022-12-19Don't panic on stable since miri is not available thereOli Scherer-4/+8
2022-12-18Auto merge of #105876 - matthiaskrgr:rollup-a9dgzjt, r=matthiaskrgrbors-21/+74
Rollup of 7 pull requests Successful merges: - #96584 (Fix `x setup -h -v` should work) - #105420 (Remove dead code after destination propagation) - #105844 (Make the x tool use the x and x.ps1 scripts) - #105854 (remove redundant clone) - #105858 (Another `as_chunks` example) - #105870 (avoid .into() conversion to identical types) - #105875 (don't destuct references just to reborrow) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2022-12-18Rollup merge of #96584 - bentongxyz:x-setup-h-v-should-work, r=jyn514Matthias Krüger-21/+74
Fix `x setup -h -v` should work r? `@jyn514` I have to convert profile to path and back in order to remove special-casing in bootstrap. I also check for `dry_run` so that `config.toml` and/ or `.git/hooks/pre-push` will not be created if `--dry-run` is specified. Please help me see if this is ok, thanks alot!
2022-12-18Auto merge of #105714 - jyn514:tidy-first, r=Mark-Simulacrumbors-0/+1
Run `x test tidy` sooner in mingw-check It takes less time to run than the other tests and is more likely to fail. `expand-yaml-anchors` is still run first to make sure the CI files are internally consistent. Note that changing to `--stage 0` doesn't actually do anything since bootstrap tools are always built with the bootstrap compiler, this just makes it less confusing. cc https://github.com/rust-lang/rust/pull/105058/commits/83bab41b5b2d4752d187dd91b05c88ac74cf3783
2022-12-17Remove special cases for setup subcommandBenjamin Tong-21/+74
- Remove setup special-casing in Flags::parse
2022-12-17Rollup merge of #105829 - the8472:tidy-style, r=jyn514Matthias Krüger-4/+19
Speed up tidy This can be reviewed commit by commit since they contain separate optimizations. ``` # master $ taskset -c 0-5 hyperfine './x test tidy' Benchmark #1: ./x test tidy Time (mean ± σ): 4.857 s ± 0.064 s [User: 12.967 s, System: 2.014 s] Range (min … max): 4.779 s … 4.997 s 10 runs # PR $ taskset -c 0-5 hyperfine './x test tidy' Benchmark #1: ./x test tidy Time (mean ± σ): 3.672 s ± 0.035 s [User: 10.524 s, System: 2.029 s] Range (min … max): 3.610 s … 3.725 s 10 runs ```
2022-12-17Rollup merge of #105559 - mkroening:install-llvm-tools, r=Mark-SimulacrumMatthias Krüger-0/+7
bootstrap: Allow installing `llvm-tools` This PR allows installing the `llvm-tools` dist tarball using `./x.py install`.
2022-12-17Symlink `build/host` -> `build/x86_64-unknown-linux-gnu` (as appropriate per ↵Joshua Nelson-1/+18
target) This allows us to use a consistent path in the documentation, without having to worry about which platform people are using.
2022-12-17Make `RUN_CHECK_WITH_PARALLEL_QUERIES` the last thing to runJoshua Nelson-0/+1
This takes a long time and rarely fails. It also interferes with `retry make prepare`, the retry is unhelpful since `make prepare` turns into a no-op
2022-12-17poll rustfmt child processesThe 8472-4/+19
2022-12-14Update CI to use Android NDK r25bChris Wailes-6/+18
This commit updates the CI definitions to use the most recent Android LTS NDK release: r25b. Changes since the last NDK used by Rust negate the need to generate "standalone toolchains" and newer NDKs can be used in-place. See https://developer.android.com/ndk/guides/other_build_systems#overview
2022-12-14Rollup merge of #105624 - compiler-errors:cache-unsound, r=jyn514Matthias Krüger-4/+4
Fix unsoundness in bootstrap cache code Discovered via #105575, which showed that rustc was failing to build during a perf run.
2022-12-13Adjust miri to still be optionalMark Rousskov-25/+31
We don't distribute a miri build for beta/stable so it needs to be kept optional. In the future it likely makes sense to switch the miri *artifacts* to always be built, but the rustup component to not be included -- this will avoid some of this pain.
2022-12-12🚨 fix unsoundness in bootstrap cache codeMichael Goulet-4/+4
2022-12-11bootstrap: Allow installing llvm-toolsMartin Kröning-0/+7
2022-12-11Rollup merge of #105459 - jyn514:proc-macro-default, r=Mark-SimulacrumMatthias Krüger-10/+0
Build rust-analyzer proc-macro server by default This allows getting rid of some documentation and an extra step when building a custom toolchain: https://rustc-dev-guide.rust-lang.org/building/how-to-build-and-run.html#creating-a-rustup-toolchain and it seems likely that people will want to do this if they want rustdoc (which is also built by default).
2022-12-10Rollup merge of #104512 - jyn514:download-ci-llvm-default, r=Mark-SimulacrumMatthias Krüger-96/+138
Set `download-ci-llvm = "if-available"` by default when `channel = dev` See https://github.com/rust-lang/compiler-team/issues/566. The motivation for changing the default is to avoid downloading and building LLVM when someone runs `x build` before running `x setup`. The motivation for only doing it on `channel = "dev"` is to avoid breaking distros or users installing from source. It works because `dev` is also the default channel. The diff looks larger than it is; most of it is moving the `llvm` branch below the `rust` so `config.channel` is set. r? `@Mark-Simulacrum` cc `@oli-obk` `@bjorn3` `@cuviper`
2022-12-08Build rust-analyzer proc-macro server by defaultJoshua Nelson-10/+0
This allows getting rid of some documentation and an extra step when building a custom toolchain: https://rustc-dev-guide.rust-lang.org/building/how-to-build-and-run.html#creating-a-rustup-toolchain and it seems likely that people will want to do this if they want rustdoc (which is also built by default).
2022-12-06Rollup merge of #104439 - ferrocene:pa-generate-copyright, r=pnkfelixMatthias Krüger-0/+77
Add prototype to generate `COPYRIGHT` from REUSE metadata This PR adds a prototype to generate the `COPYRIGHT` file from the metadata gathered with REUSE. There are two new tools: * `src/tools/collect-license-metadata` invokes REUSE, parses its output and stores a concise JSON representation of the metadata in `src/etc/license-metadata.json`. * `src/tools/generate-copyright` parses the metadata generated above, (in the future will) gather crate dependencies metadata, and renders the `COPYRIGHT.md` file. Note that since the contents of those files are currently incorrect, rather than outputting in the paths above, the files will be stored in `build/` and not committed. This will be changed once we're confident about the metadata. Eventually, `src/etc/license-metadata.json` will be committed into the repository and verified to be up to date by CI (similar to our GitHub Actions configuration), to avoid having people install REUSE on their local machine in most cases. You can see the (incorrect) generated files in https://gist.github.com/pietroalbini/3f3f22b6f9cc8533abf7494b6a50cf97. r? `@pnkfelix`
2022-12-05Rollup merge of #104953 - jyn514:fewer-submodule-updates, r=Mark-SimulacrumMatthias Krüger-3/+3
Ensure required submodules at the same time as updating existing submodules In practice, this would always happen at the same time, but putting them next to each other makes that more obvious and ensures it doesn't change in the future. It also avoids the difference affecting `cargo metadata` somehow. This is based on https://github.com/rust-lang/rust/pull/104952 for convenience to avoid merge conflicts, but doesn't depend on that PR.
2022-12-05Rollup merge of #104952 - jyn514:setup, r=Mark-SimulacrumMatthias Krüger-67/+77
Streamline the user experience for `x.py setup` ## Don't update submodules for x setup Before, the submodule handling was very jank and would update *between two interactive prompts*: ``` ; x setup Building rustbuild Finished dev [unoptimized] target(s) in 0.05s Welcome to the Rust project! What do you want to do with x.py? a) library: Contribute to the standard library Please choose one (a/b/c/d/e): a Updating submodule library/backtrace Submodule 'library/backtrace' (https://github.com/rust-lang/backtrace-rs.git) registered for path 'library/backtrace' error: you asked `x.py` to setup a new config file, but one already exists at `config.toml` Build completed unsuccessfully in 0:00:02 ``` That's not a great user experience because you need to wait a long time between prompts. It would be possible to move the submodule handling either before or after the prompt, but it seems better to just not require submodules to be checked out at all, to minimize the time spend waiting just to create a new configuration. ## Revamp the order setup executes - Create `config.toml` last. It's the most likely to error, and used to stop later steps from executing - Don't print an error message + exit if the git hook already exists; that's expected
2022-12-05Auto merge of #104824 - klensy:bump-some, r=Mark-Simulacrumbors-2/+2
deps: update cpufeatures, swap difference to dissimilar Updating cpufeatures v0.2.1 -> v0.2.5: https://github.com/RustCrypto/utils/blob/master/cpufeatures/CHANGELOG.md#025-2022-09-04, was yanked bc of miscompile (https://github.com/RustCrypto/utils/pull/800, https://github.com/rust-lang/rust/issues/101346) Removing difference v2.0.0 Adding dissimilar v1.0.4 Updating expect-test v1.0.1 -> v1.4.0 difference unmaintened https://rustsec.org/advisories/RUSTSEC-2020-0095.html, so replaced with https://github.com/dtolnay/dissimilar (as dependency of `expect-test`)
2022-12-04Update crossbeambjorn3-12/+10
This removes a lazy_static dependency edge
2022-12-04Update rayon to 1.6bjorn3-5/+4
This removes an autocfg dependency edge
2022-12-04Update pretty_assertions to 1.3bjorn3-13/+10
This replaces ansi_term with yansi which in turn removes a winapi dependency edge
2022-12-03Don't exit with an error if there are no changes to submodulesJoshua Nelson-2/+15
2022-11-30Rollup merge of #104865 - pratushrai0309:bootstrap, r=jyn514Matthias Krüger-2/+3
Don't overwrite local changes when updating submodules Fixes https://github.com/rust-lang/rust/issues/103485
2022-11-29Run patchelf also on rust-analyzer-proc-macro-srv.Joe Neeman-0/+2
2022-11-29update cpufeatures, swap difference to dissimilarklensy-2/+2
2022-11-27suggested changesPratush Rai-1/+0
2022-11-27Rollup merge of #104944 - aDotInTheVoid:jsondoclint-unit-tests, r=jyn514Matthias Krüger-0/+37
Support unit tests for jsondoclint r? ````@ghost````
2022-11-27Auto merge of #103786 - tshepang:obsolete, r=jyn514bors-7/+1
Don't build `compiler_builtins` with `-C panic=abort`
2022-11-27suggested changesPratush Rai-2/+2
2022-11-26Ensure required submodules at the same time as updating existing submodulesJoshua Nelson-3/+3
In practice, this would always happen at the same time, but putting them next to each other makes that more obvious and ensures it doesn't change in the future. It also avoids the difference avoiding `cargo metadata` somehow.
2022-11-26Revamp the order `setup` executesJoshua Nelson-13/+15
- Create `config.toml` last. It's the most likely to error, and used to stop later steps from executing - Don't print an error message + exit if the git hook already exists; that's expected
2022-11-26Refactor `setup_config_toml` into a functionJoshua Nelson-31/+31
2022-11-26Don't update submodules for `x setup`Joshua Nelson-24/+32
Before, the submodule handling was very jank and would update *between two interactive prompts*: ``` ; x setup Building rustbuild Finished dev [unoptimized] target(s) in 0.05s Welcome to the Rust project! What do you want to do with x.py? a) library: Contribute to the standard library Please choose one (a/b/c/d/e): a Updating submodule library/backtrace Submodule 'library/backtrace' (https://github.com/rust-lang/backtrace-rs.git) registered for path 'library/backtrace' error: you asked `x.py` to setup a new config file, but one already exists at `config.toml` Build completed unsuccessfully in 0:00:02 ``` That's not a great user experience because you need to wait a long time between prompts. It would be possible to move the submodule handling either before or after the prompt, but it seems better to just not require submodules to be checked out at all, to minimize the time spend waiting just to create a new configuration.
2022-11-26Revert "Don't set `is_preview` for clippy and rustfmt"Joshua Nelson-2/+4
This reverts commit fb3e724d7602675f147a9b80e70fb6bd6512738c, which broke `rustup update` for anyone with clippy or rustfmt installed.
2022-11-26Support unit tests for jsondoclintNixon Enraght-Moony-0/+37
2022-11-25Rollup merge of #104887 - aDotInTheVoid:rustbuild-json-doc-shared-assets, ↵Matthias Krüger-1/+3
r=jyn514 rustbuild: Don't build doc::SharedAssets when building JSON docs. Previously, running `./x doc library/core/ --json` on a plain build would panic bootstrap. ``` $ ./x doc library/core/ --json Building rustbuild Blocking waiting for file lock on package cache Compiling bootstrap v0.0.0 (/home/nixon/dev/rust/rust/src/bootstrap) Finished dev [unoptimized] target(s) in 4.47s thread 'main' panicked at 'fs::write(&version_info, &info) failed with No such file or directory (os error 2) ("/home/nixon/dev/rust/rust/build/x86_64-unknown-linux-gnu/doc/version_info.html")', doc.rs:410:13 note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace Build completed unsuccessfully in 0:00:04 ``` Becuase the `SharedAssets` step assumes that the HTML out dir has been created. This isn't true for JSON. The fix is to not build shared assets when doing a JSON doc build, as it doesn't need them. r? ``@jyn514`` ``@rustbot`` modify labels: +A-rustdoc-json
2022-11-25Rollup merge of #104853 - jyn514:sysroot-typo, r=RalfJungMatthias Krüger-1/+1
Fix typo in miri sysroot r? ``@RalfJung``
2022-11-25remove unused codeTshepang Mbambo-3/+1
2022-11-25remove obsolete commentTshepang Mbambo-4/+0
2022-11-25rustbuild: Don't build doc::SharedAssets when building JSON docs.Nixon Enraght-Moony-1/+3
2022-11-25Rollup merge of #103648 - jyn514:no-preview, r=Mark-SimulacrumMatthias Krüger-4/+2
Don't set `is_preview` for clippy and rustfmt These have been shipped on stable for many years now and it would be very disruptive to ever remove them. Remove the `-preview` suffix from their dist components. Based on https://github.com/rust-lang/rust/pull/102565.
2022-11-25bootstrapPratush Rai-2/+4
2022-11-24Fix typo in miri sysrootJoshua Nelson-1/+1
2022-11-24Don't set `is_preview` for clippy and rustfmtJoshua Nelson-4/+2
These have been shipped on stable for many years now and it would be very disruptive to ever remove them. Remove the `-preview` suffix from their dist components.
2022-11-23Rollup merge of #104286 - ozkanonur:fix-doc-bootstrap-recompilation, r=jyn514Dylan DPC-14/+15
copy doc output files by format This pr provides copying doc outputs by checking output format without removing output directory on each trigger. Resolves #103785