summary refs log tree commit diff
path: root/src/bootstrap
AgeCommit message (Collapse)AuthorLines
2020-01-13Reenable static linking of libstdc++ on windows-gnuMateusz Mikuła-1/+1
2019-12-13Auto merge of #67077 - Aaron1011:build-llvm-in-binary, r=alexcrichtonbors-344/+125
rustc: Link LLVM directly into rustc again (take two) This is a continuation of PR https://github.com/rust-lang/rust/pull/65703
2019-12-12Auto merge of #67172 - jethrogb:jb/bootstrap-linker, r=alexcrichtonbors-11/+17
Bootstrap: change logic for choosing linker and rpath This is a follow-up from #66957 and #67023. Apparently there was one more location with a hard-coded list of targets to influence linking. I've filed #67171 to track this madness. r? @alexcrichton
2019-12-11Add comment explaining original `maybe_install_llvm_dylib` callAaron Hill-0/+3
2019-12-11Fix missing libLLVM.so in stage0 sysroot.Aaron Hill-0/+38
When we dynamically link against libLLVM.so (as opposed to statically linking LLVM), we need libLLVM.so to be present in the stage0 sysroot, so that stage1 tools (which are built against the stage0 compiler+sysroot) can see it at build time (when the linker is run) See the comment in the commit for more details
2019-12-11Fix a test in the bootstrap test suiteAlex Crichton-0/+4
2019-12-11Fix some linking of LLVM's dynamic libraryAlex Crichton-25/+24
Ensure it shows up in the same places it did before so tools can find it at runtime.
2019-12-11rustc: Link LLVM directly into rustc againAlex Crichton-320/+57
This commit builds on #65501 continue to simplify the build system and compiler now that we no longer have multiple LLVM backends to ship by default. Here this switches the compiler back to what it once was long long ago, which is linking LLVM directly to the compiler rather than dynamically loading it at runtime. The `codegen-backends` directory of the sysroot no longer exists and all relevant support in the build system is removed. Note that `rustc` still supports a dynamically loaded codegen backend as it did previously, it just no longer supports dynamically loaded codegen backends in its own sysroot. Additionally as part of this the `librustc_codegen_llvm` crate now once again explicitly depends on all of its crates instead of implicitly loading them through the sysroot. This involved filling out its `Cargo.toml` and deleting all the now-unnecessary `extern crate` annotations in the header of the crate. (this in turn required adding a number of imports for names of macros too). The end results of this change are: * Rustbuild's build process for the compiler as all the "oh don't forget the codegen backend" checks can be easily removed. * Building `rustc_codegen_llvm` is much simpler since it's simply another compiler crate. * Managing the dependencies of `rustc_codegen_llvm` is much simpler since it's "just another `Cargo.toml` to edit" * The build process should be a smidge faster because there's more parallelism in the main rustc build step rather than splitting `librustc_codegen_llvm` out to its own step. * The compiler is expected to be slightly faster by default because the codegen backend does not need to be dynamically loaded. * Disabling LLVM as part of rustbuild is still supported, supporting multiple codegen backends is still supported, and dynamic loading of a codegen backend is still supported.
2019-12-10Move CI to new builtin check-toolstateMark Rousskov-0/+2
2019-12-10Add toolstate checking into bootstrapMark Rousskov-27/+406
This is not yet actually used by CI, but implements the logic for checking that tools are properly building on beta/stable and during beta cutoff week. This attempts to mirror the checking functionality in src/ci/docker/x86_64-gnu-tools/checktools.sh, and called scripts. It does not attempt to run the relevant steps (that functionality was originally desired to be moved into bootstrap as well, but doing so proved more difficult than expected). This is intended as a way to centralize and make clearer the logic involved in toolstate checking. In particular, the previous logic was spread across numerous python and shell scripts in such a way that made interpretation quite difficult.
2019-12-09Bootstrap: change logic for choosing linker and rpathJethro Beekman-11/+17
2019-12-04SGX: Fix target linker used by bootstrapJethro Beekman-0/+1
2019-12-02Update the minimum external LLVM to 7Josh Stone-2/+2
LLVM 7 is over a year old, which should be plenty for compatibility. The last LLVM 6 holdout was llvm-emscripten, which went away in #65501. I've also included a fix for LLVM 8 lacking `MemorySanitizerOptions`, which was broken by #66522.
2019-12-01rustbuild: don't clobber RUSTFLAGS, append to itXimin Luo-5/+7
2019-12-01rustbuild: fix cross-compile installXimin Luo-1/+1
although, not sure why this works - it wasn't needed before
2019-11-26Fix spelling typosBrian Wignall-1/+1
2019-11-25Rollup merge of #66569 - pietroalbini:gha-1, r=alexcrichtonPietro Albini-0/+4
GitHub Actions: preparations, part 1 This PR adds the first batch of commits in preparation for GitHub Actions: * Added GitHub Actions support in `src/ci/shared.sh` and bootstrap. * Addded a `setup-environment.sh` script which guesses and sets the `DEPLOY`, `DEPLOY_ALT` and `IMAGE` environment variables automatically, to reduce the verbosity of the CI configuration. This PR does **not** yet add any builders on GitHub Actions. r? @alexcrichton
2019-11-22ci: add support for GitHub Actions in the CI scriptsPietro Albini-0/+4
2019-11-20debuginfo: Support for std::collections::Hash* in windows debuggers.MaulingMonkey-0/+1
2019-11-13Rollup merge of #66317 - cuviper:bindir_relative, r=Mark-SimulacrumYuki Okushi-1/+16
Use a relative bindir for rustdoc to find rustc In bootstrap, we set `RUSTC_INSTALL_BINDIR` to `config.bindir`, so rustdoc can find rustc relative to the toolchain sysroot. However, if a distro script like Fedora's `%configure` sets an absolute path, then rustdoc's `sysroot.join(bin_path)` ignores that sysroot altogether. That would be OK once the toolchain is actually installed, but it breaks the in-tree doc tests during the build, since `/usr/bin/rustc` is still the old version. So now we try to make `RUSTC_INSTALL_BINDIR` relative to the sysroot prefix in the first place. r? @Mark-Simulacrum
2019-11-13Rollup merge of #66166 - GuillaumeGomez:rename-rustdoc-to-doc, r=QuietMisdreavusYuki Okushi-1/+1
rename cfg(rustdoc) into cfg(doc) Needed by https://github.com/rust-lang/rust/pull/61351 r? @QuietMisdreavus
2019-11-13Rollup merge of #65932 - guanqun:download-xz, r=alexcrichtonYuki Okushi-14/+29
download .tar.xz if python3 is used fixes https://github.com/rust-lang/rust/issues/65757
2019-11-12Hopefully fix rustdoc buildMark Rousskov-1/+12
It's super unclear why this broke when we switched to beta but not previously -- but at least it's hopefully fixed now.
2019-11-12Bump version to 1.41Mark Rousskov-1/+1
2019-11-12Fallback to the unmodified path in bindir_relativeJosh Stone-8/+10
2019-11-12Rollup merge of #66263 - guanqun:make-error-explicit, r=alexcrichtonYuki Okushi-3/+3
make the error message more readable When I type it wrong e.g. `--stage --bless`, missing a number here, this change would make it more explicit what's going wrong here.
2019-11-11Use a relative bindir for rustdoc to find rustcJosh Stone-1/+14
In bootstrap, we set `RUSTC_INSTALL_BINDIR` to `config.bindir`, so rustdoc can find rustc relative to the toolchain sysroot. However, if a distro script like Fedora's `%configure` sets an absolute path, then rustdoc's `sysroot.join(bin_path)` ignores that sysroot altogether. That would be OK once the toolchain is actually installed, but it breaks the in-tree doc tests during the build, since `/usr/bin/rustc` is still the old version. So now we try to make `RUSTC_INSTALL_BINDIR` relative to the sysroot prefix in the first place.
2019-11-12bootstrap: don't call support_xz in hot-pathGuanqun Lu-21/+22
2019-11-11Update clippyManish Goregaokar-0/+5
2019-11-10download .tar.xz if python3 is usedGuanqun Lu-9/+23
2019-11-10make the error message more readableGuanqun Lu-3/+3
2019-11-06rename cfg(rustdoc) into cfg(doc)Guillaume Gomez-1/+1
2019-11-05Auto merge of #65911 - mati865:static-libstdcxx-mingw, r=alexcrichtonbors-5/+5
Statically link libstdc++ on windows-gnu Fixes https://github.com/rust-lang/rust/issues/61561 by not shipping `libstdc++-6.dll` which can conflict with the GCC.
2019-10-31Rollup merge of #65274 - pietroalbini:ci-upload-toolstate, r=alexcrichtonMazdak Farrokhzad-0/+4
Upload toolstates.json to rust-lang-ci2 This PR does two things: * Following up with https://github.com/rust-lang/rust/pull/65202, it migrates deploying artifacts to CI in a script. Both uploading release artifacts and CPU stats were merged into the same script, designing it to be easily extended. * Uploads the toolstate JSON to `rust-lang-ci2` along with the release artifacts, both for Linux and Windows. This is needed because @RalfJung wants to stop shipping MIRI when its tests are failing, and the toolstate repo doesn't have entries for each commit. Having the toolstate data (just for that specific commit) on `rust-lang-ci2` will simplify the code a lot. r? @alexcrichton cc @RalfJung
2019-10-30Statically link libstdc++ on windows-gnuMateusz Mikuła-5/+5
2019-10-30ci: move toolstates.json to /tmp/toolstate/ and docker mount itPietro Albini-0/+4
Before this commit toolstates.json was stored in /tmp and it wasn't mounted outside the build container. That caused uploading the file in the upload-artifacts task to fail, as the file was missing on the host. Mounting /tmp/toolstates.json alone is not the best approach: if the file is missing when the container is started the Docker engine will create a *directory* named /tmp/toolstates.json. The Docker issue could be solved by pre-creating an empty file named /tmp/toolstates.json, but doing that could cause problems if bootstrap fails to generate the file and the toolstate scripts receive an empty JSON. The approach I took in this commit is to instead mount a /tmp/toolstate directory inside Docker, and create the toolstates.json file in it. That also required a small bootstrap change to ensure the directory is created if it's missing.
2019-10-29Rollup merge of #65920 - smaeul:patch/workspace-hack, r=alexcrichtonTyler Mandry-0/+1
Use rustc-workspace-hack for rustbook As rustbook now depends transitively on openssl, it needs access to the rustc-workspace-hack/all-static feature to pick up openssl-sys/vendored. This fixes the rust build with `all-static = true` on systems where openssl is not installed (e.g. when cross-compiling).
2019-10-29Rollup merge of #65843 - xen0n:mips64-musl-targets-with-ci, r=alexcrichtonTyler Mandry-0/+4
Enable dist for MIPS64 musl targets Continuing work in #63165, necessary libc changes are in place and published so here we go!
2019-10-29Rollup merge of #65832 - tlively:emscripten-exception-handling, r=alexcrichtonTyler Mandry-0/+4
Re-enable Emscripten's exception handling support Passes LLVM codegen and Emscripten link-time flags for exception handling if and only if the panic strategy is `unwind`. Sets the default panic strategy for Emscripten targets to `unwind`. Re-enables tests that depend on unwinding support for Emscripten, including `should_panic` tests. r? @alexcrichton
2019-10-28Use rustc-workspace-hack for rustbookSamuel Holland-0/+1
As rustbook now depends transitively on openssl, it needs access to the rustc-workspace-hack/all-static feature to pick up openssl-sys/vendored. This fixes the rust build with `all-static = true` on systems where openssl is not installed (e.g. when cross-compiling).
2019-10-26Auto merge of #65167 - hermitcore:rusty-hermit, r=alexcrichtonbors-1/+1
Redesign the interface to the unikernel HermitCore We are developing the unikernel HermitCore, where the kernel is written in Rust and is already part of the Rust Standard Library. The interface between the standard library and the kernel based on a small C library. With this pull request, we remove completely the dependency to C and use lld as linker. Currently, the kernel will be linked to the application as static library, which is published at https://github.com/hermitcore/libhermit-rs. We don’t longer support the C interface to the kernel. Consequently, we remove this part from the Rust Standard Library.
2019-10-26ci: add support for MIPS64 musl targetsWang Xuerui-0/+4
2019-10-26use plain cargo to install xargoRalf Jung-11/+1
2019-10-26bootstrap now takes care of installing xargoRalf Jung-4/+21
2019-10-25Re-enable Emscripten's exception handling supportThomas Lively-0/+4
Passes LLVM codegen and Emscripten link-time flags for exception handling if and only if the panic strategy is `unwind`. Sets the default panic strategy for Emscripten targets to `unwind`. Re-enables tests that depend on unwinding support for Emscripten, including `should_panic` tests.
2019-10-25Merge branch 'master' into rusty-hermit, resolve conflictsStefan Lankes-55/+143
2019-10-25Rollup merge of #65408 - guanqun:remove-rust-optimize, r=Mark-SimulacrumMazdak Farrokhzad-15/+15
reorder config.toml.example options and add one missing option r? @Mark-Simulacrum
2019-10-24reorder TomlTarget struct's fields based on the order in config.toml.exampleGuanqun Lu-2/+2
2019-10-24reorder Rust struct's fields based on the order in config.toml.exampleGuanqun Lu-5/+5
2019-10-24reorder Install struct's fields based on the order in config.toml.exampleGuanqun Lu-1/+1