about summary refs log tree commit diff
path: root/src/bootstrap/native.rs
AgeCommit message (Collapse)AuthorLines
2019-10-30Statically link libstdc++ on windows-gnuMateusz Mikuła-2/+2
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-21Remove `src/llvm-emscripten` submoduleAlex Crichton-50/+25
With #65251 landed there's no need to build two LLVM backends and ship them with rustc, every target we have now uses the same LLVM backend! This removes the `src/llvm-emscripten` submodule and additionally removes all support from rustbuild for building the emscripten LLVM backend. Multiple codegen backend support is left in place for now, and this is intended to be an easy 10-15 minute win on CI times by avoiding having to build LLVM twice.
2019-10-08Disable Go and OCaml bindings when building LLVMTomasz Miąsko-9/+1
Instead of instaling OCaml bindings in a location where installation will not fail, don't build them in the first place.
2019-09-04Assume non-git LLVM is fresh if the stamp file existsJosh Stone-13/+14
Rustbuild usually writes the LLVM submodule commit in a stamp file, so we can avoid rebuilding it unnecessarily. However, for builds from a source tarball (non-git), we were assuming a rebuild is always needed. This can cause a lot of extra work if any environment like `CFLAGS` changed between steps like build and install, which are often separate in distro builds. Now we also write an empty stamp file if the git commit is unknown, and its presence is trusted to indicate that no rebuild is needed. An info message reports that this is happening, along with the stamp file path that can be deleted to force a rebuild anyway.
2019-08-02rustbuild: correct line lengthSam Elliott-1/+2
2019-08-02rustbuild: WebAssembly is no longer an experimental LLVM backendSam Elliott-2/+2
2019-08-02rustbuild: RISC-V is no longer an experimental LLVM targetSam Elliott-2/+5
This commit moves RISC-V from the experimental LLVM targets to the regular LLVM targets. RISC-V was made non-experimental in https://reviews.llvm.org/rL366399 I have also sorted the list of LLVM targets, and changed the code around setting llvm_exp_targets (and its default) to match the code setting llvm_targets (and its default), ensuring future changes to the defaults, as LLVM targets become stable, affect as few places as possible.
2019-07-27Remove run-pass test suitesVadim Petrochenkov-1/+1
2019-07-17Disable Z3 in LLVM buildNikita Popov-0/+1
2019-07-15ci: Remove Travis/AppVeyor configurationAlex Crichton-3/+0
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-09Pass cflags rather than cxxflags to LLVM as CMAKE_C_FLAGSPetr Hosek-1/+1
We mistakenly pass cxxflags from the configuration to LLVM build as CMAKE_C_FLAGS.
2019-05-27Only build clang_rt when RUSTBUILD_FORCE_CLANG_BASED_TESTS is set.Michael Woerister-1/+15
2019-05-27rustbuild: Also build compiler-rt when building LLDB. This allows ↵Michael Woerister-1/+1
clang-based run-make tests to use PGO.
2019-05-15rustbuild/LLVM: Do not print installation messages for up-to-date filesVadim Petrochenkov-0/+4
2019-05-09remove unneeded `extern crate`s from build toolsAndy Russell-1/+1
2019-04-30Rename to RUSTC_LOGYuki OKUSHI-1/+1
2019-04-15LLD is not supported on DarwinPetr Hosek-2/+4
Don't enable LLD when LTO is enabled on Darwin.
2019-03-30Use a single llvm_info variableJosh Stone-13/+8
2019-03-30Use the existing LLVM GitInfo for checking rebuildsJosh Stone-18/+11
2019-03-27replace llvm-rebuild-trigger with commit hashAndy Russell-15/+33
2019-03-14bootstrap: Default to a sensible llvm-suffix.Emilio Cobos Álvarez-1/+21
I used version-channel-sha, hopefully that should work. I checked that bootstrap builds, but I cannot check anything else since the llvm build process is started from cargo, and thus calls clang, and thus I hit the same bug I hope to fix with this change. Hopefully fixes #59034.
2019-02-27Whitelist containers that allow older toolchainsAlex Crichton-0/+4
We'll use this as a temporary measure to get an LLVM update landed, but we'll have to go through and update images later to make sure they've got the right toolchains.
2019-02-25bootstrap: deny(rust_2018_idioms)Taiki Endo-11/+11
2019-01-31Auto merge of #57514 - michaelwoerister:xlto-tests, r=alexcrichtonbors-0/+4
compiletest: Support opt-in Clang-based run-make tests and use them for testing xLTO. Some cross-language run-make tests need a Clang compiler that matches the LLVM version of `rustc`. Since such a compiler usually isn't available these tests (marked with the `needs-matching-clang` directive) are ignored by default. For some CI jobs we do need these tests to run unconditionally though. In order to support this a `--force-clang-based-tests` flag is added to compiletest. If this flag is specified, `compiletest` will fail if it can't detect an appropriate version of Clang. @rust-lang/infra The PR doesn't yet enable the tests yet. Do you have any recommendation for which jobs to enable them? cc #57438 r? @alexcrichton
2019-01-30bootstrap: Expose LLVM_USE_LINKER cmake option to config.toml.Michael Woerister-0/+4
2019-01-25Set LLDB_NO_DEBUGSERVER=ONJosh Stone-0/+1
2019-01-25Rebase to the llvm-project monorepoJosh Stone-6/+8
The new git submodule src/llvm-project is a monorepo replacing src/llvm and src/tools/{clang,lld,lldb}. This also serves as a rebase for these projects to the new 8.x branch from trunk. The src/llvm-emscripten fork is unchanged for now.
2019-01-13Support passing cflags/cxxflags/ldflags to LLVM buildPetr Hosek-1/+14
This may be needed with some host compilers.
2019-01-12Rollup merge of #57368 - petrhosek:cmake-compiler-launcher, r=alexcrichtonMazdak Farrokhzad-8/+6
Use CMAKE_{C,CXX}_COMPILER_LAUNCHER for ccache CMake 3.4 and newer which is the required minimum version for LLVM supports CMAKE_{C,CXX}_COMPILER_LAUNCHER for settting the compiler launcher such as ccache which doesn't require shifting arguments.
2019-01-07Build LLVM with -static-libstdc++ on dist buildsAlex Crichton-8/+8
This commit is intended on fixing a regression from #57286 where the distributed LLVM shared library unfortunately depends on a dynamic copy of libstdc++, meaning we're no longer as binary compatible as we thought! This tweaks the build of LLVM as out distribution is slightly different now, and is hoped to fix the issue. Closes #57426
2019-01-05Use CMAKE_{C,CXX}_COMPILER_LAUNCHER for ccachePetr Hosek-8/+6
CMake 3.4 and newer which is the required minimum version for LLVM supports CMAKE_{C,CXX}_COMPILER_LAUNCHER for settting the compiler launcher such as ccache which doesn't require shifting arguments.
2018-12-25Remove licensesMark Rousskov-10/+0
2018-12-17Auto merge of #56642 - nikic:llvm-6, r=alexcrichtonbors-2/+2
Bump minimum required LLVM version to 6.0 Based on the discussion in #55842, while the overall position of Rust wrt LLVM continues to be contentious, there does seem to be a consensus that there is no need for continued support of LLVM 5. This PR bumps our version requirement to LLVM 6.0 and makes Travis run against that. I hope that this is going to unblock #52694. If I understand correctly, while this issue still exists in LLVM 6, Ubuntu has backported the relevant patch. r? @alexcrichton
2018-12-10bootstrap: fix editionljedrz-4/+4
2018-12-09Bump minimum required LLVM version to 6.0Nikita Popov-2/+2
2018-12-08Auto merge of #56578 - alexreg:cosmetic-1, r=alexregbors-1/+1
Various minor/cosmetic improvements to code r? @Centril 😄
2018-12-07Various minor/cosmetic improvements to codeAlexander Regueiro-1/+1
2018-12-07use top level `fs` functions where appropriateAndy Russell-6/+3
This commit replaces many usages of `File::open` and reading or writing with `fs::read_to_string`, `fs::read` and `fs::write`. This reduces code complexity, and will improve performance for most reads, since the functions allocate the buffer to be the size of the file. I believe that this commit will not impact behavior in any way, so some matches will check the error kind in case the file was not valid UTF-8. Some of these cases may not actually care about the error.
2018-10-26Typo fixes in configure_cmake commentsEddy Petrișor-2/+2
Signed-off-by: Eddy Petrișor <eddy.petrisor@gmail.com>
2018-10-20Update Cargo, build curl/OpenSSL statically via featuresAlex Crichton-186/+0
In addition to to updating Cargo's submodule and Cargo's dependencies, this also updates Cargo's build to build OpenSSL statically into Cargo as well as libcurl unconditionally. This removes OpenSSL build logic from the bootstrap code, and otherwise requests that even on OSX we build curl statically.
2018-09-14Rollup merge of #53829 - alexcrichton:release-debuginfo, r=michaelwoeristerkennytm-3/+4
Add rustc SHA to released DWARF debuginfo This commit updates the debuginfo that is encoded in all of our released artifacts by default. Currently it has paths like `/checkout/src/...` but these are a little inconsistent and have changed over time. This commit instead attempts to actually define the file paths in our debuginfo to be consistent between releases. All debuginfo paths are now intended to be `/rustc/$sha` where `$sha` is the git sha of the released compiler. Sub-paths are all paths into the git repo at that `$sha`.
2018-09-10Add rustc SHA to released DWARF debuginfoAlex Crichton-3/+4
This commit updates the debuginfo that is encoded in all of our released artifacts by default. Currently it has paths like `/checkout/src/...` but these are a little inconsistent and have changed over time. This commit instead attempts to actually define the file paths in our debuginfo to be consistent between releases. All debuginfo paths are now intended to be `/rustc/$sha` where `$sha` is the git sha of the released compiler. Sub-paths are all paths into the git repo at that `$sha`.
2018-09-07rustbuild: allow configuring llvm version suffixMarc-Antoine Perennou-0/+4
Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
2018-09-05propagate build.python into cmakeNathan Froyd-0/+4
If a suitable value of Python is not on PATH, one can still invoke x.py manually, which propagates BOOTSTRAP_PYTHON into the bootstrap environment. But building LLVM will abort with error messages about not being able to find Python, and instructions to set PYTHON_EXECUTABLE, because nothing is done with BOOTSTRAP_PYTHON when invoking cmake. Setting build.python in config.toml had no effect in this scenario, either To fix this, let's provide PYTHON_EXECUTABLE when invoking cmake; for the "normal" case of Python in PATH, this doesn't alter any behavior. For more unusual cases, however, this ensures cmake finds Python properly. (This change also ensures there are no differences between what bootstrap is using, and what cmake uses, which may be useful for consistency's sake.)
2018-08-31Update LLVM submoduleAlex Crichton-0/+1
This commit updates the LLVM submodule to the current trunk of LLVM itself. This brings a few notable improvements for the wasm target: * Support for wasm atomic instructions is greatly improved * Renamed memory wasm intrinsics are fully supported * LLD has fixed a quadratic execution bug with large numbers of relocations in wasm files. The compiler-rt submodule has been updated in tandem as well.
2018-08-29bootstrap: Link LLVM tools dynamically in order to save time in ThinLTO builds.Michael Woerister-8/+4
2018-08-20bootstrap: Never compiler llvm-emscripten with ThinLTO.Michael Woerister-1/+1
2018-08-20bootstrap: Allow for building LLVM with ThinLTO.Michael Woerister-0/+5
2018-08-20bootstrap: Allow to specify ranlib tool used when compiling C++ code.Michael Woerister-0/+8