about summary refs log tree commit diff
path: root/src/bootstrap/util.rs
AgeCommit message (Collapse)AuthorLines
2022-03-07copy over `std::path::absolute` instead of adding `canonicalize` hacksJoshua Nelson-0/+109
this also fixes a bug where bootstrap would try to use the fake `rustc` binary built by bootstrap - cargo puts it in a different directory when using `cargo run` instead of x.py
2022-03-05Merge build_helper into utilbjorn3-3/+143
2022-03-05Remove build_helperbjorn3-2/+1
The majority of the code is only used by either rustbuild or rustc_llvm's build script. Rust_build is compiled once for rustbuild and once for every stage. This means that the majority of the code in this crate is needlessly compiled multiple times. By moving only the code actually used by the respective crates to rustbuild and rustc_llvm's build script, this needless duplicate compilation is avoided.
2022-01-27rustbuild: Fix compiletest warning when building outside of root.Eric Huss-2/+3
2022-01-01Remove some dead codebjorn3-20/+0
2022-01-01Make the rustc and rustdoc wrapper not depend on libbootstrapbjorn3-23/+1
This slightly improves compilation time by reducing linking time (saving about a 1/10 of the the total compilation time after changing rustbuild) and slightly reduces disk usage (from 16MB for the rustc wrapper to 4MB).
2021-11-09Allow to run a specific rustdoc-js* testGuillaume Gomez-0/+32
2021-06-06Auto merge of #79608 - alessandrod:bpf, r=nagisabors-1/+2
BPF target support This adds `bpfel-unknown-none` and `bpfeb-unknown-none`, two new no_std targets that generate little and big endian BPF. The approach taken is very similar to the cuda target, where `TargetOptions::obj_is_bitcode` is enabled and code generation is done by the linker. I added the targets to `dist-various-2`. There are [some tests](https://github.com/alessandrod/bpf-linker/tree/main/tests/assembly) in bpf-linker and I'm planning to add more. Those are currently not ran as part of rust CI.
2021-06-03fix testing Miri with --stage 0Ralf Jung-0/+1
2021-05-23Add BPF targetAlessandro Decina-1/+2
This change adds the bpfel-unknown-none and bpfeb-unknown-none targets which can be used to generate little endian and big endian BPF
2021-02-17Make sure pdbs are copied along with exe and dlls when bootstrappingRyan Levick-0/+6
2020-10-18bootstrap: Print units for "finished in xxx" messageCamelid-1/+1
It now says "finished in xxx seconds". Also slightly improved some wording in the README.
2020-07-17Teach bootstrap about target files vs target triplesJake Goulding-6/+5
`rustc` allows passing in predefined target triples as well as JSON target specification files. This change allows bootstrap to have the first inkling about those differences. This allows building a cross-compiler for an out-of-tree architecture (even though that compiler won't work for other reasons). Even if no one ever uses this functionality, I think the newtype around the `Interned<String>` improves the readability of the code.
2020-03-18Ensure LLVM is in the link path for rustc toolsJosh Stone-0/+25
2020-03-18Rename add_lib_path to add_dylib_pathJosh Stone-1/+1
2020-02-03bootstrap: fix clippy warningsMatthias Krüger-1/+1
2020-01-11use winapi for non-stdlib Windows bindingsAndy Russell-49/+13
2019-12-22Format the worldMark Rousskov-67/+62
2019-12-21use Result::map_or for bootstrapLzu Tao-2/+2
2019-12-09Bootstrap: change logic for choosing linker and rpathJethro Beekman-0/+13
2019-11-22ci: add support for GitHub Actions in the CI scriptsPietro Albini-0/+4
2019-07-15ci: Remove Travis/AppVeyor configurationAlex Crichton-73/+3
Now that we've fully moved to Azure Pipelines and bors has been updated to only gate on Azure this commit removes the remaining Travis/AppVeyor support contained in this repository. Most of the deletions here are related to producing better output on Travis by folding certain sections. This isn't supported by Azure so there's no need to keep it around, and if Azure ever adds support we can always add it back!
2019-06-17Make use of `ptr::null(_mut)` instead of casting zeroLzu Tao-1/+1
2019-05-27Only build clang_rt when RUSTBUILD_FORCE_CLANG_BASED_TESTS is set.Michael Woerister-0/+16
2019-05-13Update src/bootstrap/util.rsPietro Albini-1/+1
Co-Authored-By: Jake Goulding <shepmaster@mac.com>
2019-05-10Add Azure PipelinesJohn Erickson-0/+4
2019-05-09remove unneeded `extern crate`s from build toolsAndy Russell-0/+2
2019-02-25bootstrap: deny(rust_2018_idioms)Taiki Endo-1/+1
2019-02-10rustc: doc commentsAlexander Regueiro-1/+1
2019-01-26Workaround presence of LLVM library in stage0/libMark Rousskov-1/+5
This commit works around the newly-introduced LLVM shared library. This is needed such that llvm-config run from librustc_llvm's build script can correctly locate it's own LLVM, not the one in stage0/lib. The LLVM build system uses the DT_RUNPATH/RUNPATH header within the llvm-config binary, which we want to use, but because Cargo always adds the host compiler's "libdir" (stage0/lib in our case) to the dynamic linker's search path, we weren't properly finding the freshly-built LLVM in llvm/lib. By restoring the environment variable setting the search path to what bootstrap sees, the problem is resolved and librustc_llvm correctly links and finds the appropriate LLVM. Several run-make-fulldeps tests are also updated with similar handling.
2018-12-25Remove licensesMark Rousskov-10/+0
2018-12-10bootstrap: fix editionljedrz-2/+2
2018-12-01remove some uses of try!Mark Mansi-3/+3
2018-08-29Replace usages of 'bad_style' with 'nonstandard_style'.Corey Farwell-1/+1
`bad_style` is being deprecated in favor of `nonstandard_style`: - https://github.com/rust-lang/rust/issues/41646
2018-07-29Replace push loops with collect() and extend() where possibleljedrz-4/+1
2018-04-17Remove uses of Build across Builder stepsMark Simulacrum-3/+3
2018-04-03Avoid printing output when in dry run modeMark Simulacrum-7/+10
2018-04-03Refactor to use a dry-run config instead of cfg(test)Mark Simulacrum-101/+5
This ensures that each build will support the testing design of "dry running" builds. It's also checked that a dry run build is equivalent step-wise to a "wet" run build; the graphs we generate when running are directly compared node/node and edge/edge, both for order and contents.
2018-04-03Stub out less codeMark Simulacrum-2/+0
2018-04-03Stub out various functions during testingMark Simulacrum-0/+3
2018-03-28rustbuild: Don't leak file handles when creating junctions on WindowsOliver Middleton-2/+5
This fixes building the compiler docs because stage1-rustc\x86_64-pc-windows-msvc\doc is used twice which doesn't work if we still have a handle from the first time.
2018-01-04Bump to 1.25.0Alex Crichton-1/+1
* Bump the release version to 1.25 * Bump the bootstrap compiler to the recent beta * Allow using unstable rustdoc features on beta - this fix has been applied to the beta branch but needed to go to the master branch as well.
2017-12-04template month/year, version into man pages while building dist tarballZack M. Davis-2/+16
This is meant to resolve #25689.
2017-10-18Make sure to clear out the stageN-{rustc,std,tools} directories.Mark Simulacrum-2/+19
We copy built tool binaries into a dedicated directory to avoid deleting them, stageN-tools-bin. These aren't ever cleared out by code, since there should be no reason to do so, and we'll simply overwrite them as necessary. When clearing out the stageN-{std,rustc,tools} directories, make sure to delete both Cargo directories -- per-target and build scripts. This ensures that changing libstd doesn't cause problems due to build scripts not being rebuilt, even though they should be.
2017-09-09rustbuild: Switch back to using hard linksAlex Crichton-3/+6
The `copy` function historically in rustbuild used hard links to speed up the copy operations that it does. This logic was backed out, however, in #39518 due to a bug that only showed up on Windows, described in #39504. The cause described in #39504 happened because Cargo, on a fresh build, would overwrite the previous artifacts with new hard links that Cargo itself manages. This behavior in Cargo was fixed in rust-lang/cargo#4390 where it no longer should overwrite files on fresh builds, opportunistically leaving the filesystem intact and not touching it. Hopefully this can help speed up local builds by doing fewer copies all over the place!
2017-08-31Update Cargo to 0.23.0 and our lockfileAlex Crichton-1/+1
2017-07-04Cleanup utilsMark Simulacrum-12/+3
2017-06-02ci: Improve log output (mainly Travis).kennytm-2/+101
* Bring back colors on Travis, which was disabled since #39036. Append --color=always to cargo when running in CI environment. * Removed `set -x` in the shell scripts. The `retry` function already prints which command it is running, add `-x` just add noise to the output. * Support travis_fold/travis_time. Matching pairs of these allow Travis CI to collapse the output in between. This greatly cut down the unnecessary "successful" output one need to scroll through before finding the failed statement.
2017-04-24Haiku: add missing cases of using LIBRARY_PATHJessica Hamilton-0/+2
2017-03-10rustbuild: Build documentation for `proc_macro`Alex Crichton-0/+139
This commit fixes #38749 by building documentation for the `proc_macro` crate by default for configured hosts. Unfortunately did not turn out to be a trivial fix. Currently rustbuild generates documentation into multiple locations: one for std, one for test, and one for rustc. The initial fix for this issue simply actually executed `cargo doc -p proc_macro` which was otherwise completely elided before. Unfortunately rustbuild was the left to merge two documentation trees together. One for the standard library and one for the rustc tree (which only had docs for the `proc_macro` crate). Rustdoc itself knows how to merge documentation files (specifically around search indexes, etc) but rustbuild was unaware of this, so an initial fix ended up destroying the sidebar and the search bar from the libstd docs. To solve this issue the method of documentation has been tweaked slightly in rustbuild. The build system will not use symlinks (or directory junctions on Windows) to generate all documentation into the same location initially. This'll rely on rustdoc's logic to weave together all the output and ensure that it ends up all consistent. Closes #38749