about summary refs log tree commit diff
path: root/src/bootstrap
AgeCommit message (Collapse)AuthorLines
2016-12-12rustbuild: Fix dist of save-analysis infoAlex Crichton-10/+3
We don't need an extra bare tarball, the save-analysis info is already produced with a version/target in the filename.
2016-12-12rustbuild: Check for .git as a dirAlex Crichton-2/+2
Git worktrees have this as a file and typically won't work inside docker containers, but that's ok, so instead of just checking for existence check for a directory to see if the git commands will succeed.
2016-12-12rustbuild: Enable unstable features in rustdocAlex Crichton-0/+1
This ensures that stable releases produced by rustbuild will succeed in testing as some of the rustdoc tests use unstable features.
2016-12-11Auto merge of #38252 - pnkfelix:mildly-robustify-configure-msg, r=alexcrichtonbors-1/+1
Make configure message re x.py not assume build dir == src dir Fix #38251 but perhaps not BEST fix for it. As driveby, fix copyright year in `Makefile.in`
2016-12-10Auto merge of #38231 - vadimcn:errormode, r=alexcrichtonbors-0/+11
Prevent Windows from displaying UI on errors. Otherwise tests like run-pass/out-of-stack get wedged on Windows error reporting dialog (unless error reporting has been disabled, of course).
2016-12-10Auto merge of #38233 - alexcrichton:more-errors, r=japaricbors-2/+1
rustbuild: Print out failing commands Just ensure that we always print out the command line which should aid in debugging. Closes #38228
2016-12-09Create tar balls of save-analysis-api metadata for the standard libraries as ↵Nick Cameron-1/+58
part of `make dist`.
2016-12-08rustbuild: Implement distcheckAlex Crichton-9/+42
This commit implements the `distcheck` target for rustbuild which is only ever run on our nightly bots. This essentially just creates a tarball, un-tars it, and then runs a full build, validating that the release tarballs do indeed have everything they need to build Rust.
2016-12-08Fix #38251 but perhaps not BEST fix for it.Felix S. Klock II-1/+1
2016-12-08Auto merge of #38076 - alexcrichton:another-rustbuild-bug, r=japaricbors-0/+8
rustbuild: Use src/rustc for assembled compilers The `src/rustc` path is intended for assembling a compiler (e.g. the bare bones) not actually compiling the whole compiler itself. This path was accidentally getting hijacked to represent the whole compiler being compiled, so let's redirect that elsewhere for that particular cargo project. Closes #38039
2016-12-07Preserve inherited mode flags.Vadim Chugunov-1/+2
2016-12-07Prevent Windows from displaying UI on errors.Vadim Chugunov-0/+10
2016-12-07rustbuild: Print out failing commandsAlex Crichton-2/+1
Just ensure that we always print out the command line which should aid in debugging. Closes #38228
2016-12-07mk: Switch rustbuild to the default build systemAlex Crichton-142/+516
This commit switches the default build system for Rust from the makefiles to rustbuild. The rustbuild build system has been in development for almost a year now and has become quite mature over time. This commit is an implementation of the proposal on [internals] which slates deletion of the makefiles on 2016-01-02. [internals]: https://internals.rust-lang.org/t/proposal-for-promoting-rustbuild-to-official-status/4368 This commit also updates various documentation in `README.md`, `CONTRIBUTING.md`, `src/bootstrap/README.md`, and throughout the source code of rustbuild itself. Closes #37858
2016-12-03Rollup merge of #38073 - cardoe:fix-typo, r=frewsxcvCorey Farwell-1/+1
bootstrap/README: fix small typo
2016-12-02Auto merge of #38050 - alexcrichton:fix-llvm-deps, r=japaricbors-0/+7
rustbuild: Cross-compiled LLVM depens on host We use the host's tblgen so we need to be sure to always build the host first. Closes #38037
2016-11-30Update the bootstrap compilerAlex Crichton-35/+5
Now that we've got a beta build, let's use it!
2016-11-29rustbuild: Use src/rustc for assembled compilersAlex Crichton-0/+8
The `src/rustc` path is intended for assembling a compiler (e.g. the bare bones) not actually compiling the whole compiler itself. This path was accidentally getting hijacked to represent the whole compiler being compiled, so let's redirect that elsewhere for that particular cargo project. Closes #38039
2016-11-29bootstrap/README: fix small typoDoug Goldstein-1/+1
2016-11-28rustbuild: Cross-compiled LLVM depens on hostAlex Crichton-0/+7
We use the host's tblgen so we need to be sure to always build the host first. Closes #38037
2016-11-26Auto merge of #38008 - bluss:rustbuild-benches, r=alexcrichtonbors-14/+88
Add rustbuild command `bench` Add command bench to rustbuild, so that `./x.py bench <path>` can compile and run benchmarks. `./x.py bench --stage 1 src/libcollections` and `./x.py bench --stage 1 src/libstd` should both compile well. Just `./x.py bench` runs all benchmarks for the libstd crates. Fixes #37897
2016-11-25rustbuild: Add bench subcommandUlrik Sverdrup-14/+88
Add command `./x.py bench`; use `./x.py bench --help -v` to list all available benchmark targets.
2016-11-23std: make compilation of libpanic_unwind optional via a Cargo featureJorge Aparicio-1/+1
with this feature disabled, you can (Cargo) compile std with "panic=abort" rustbuild will build std with this feature enabled, to maintain the status quo fixes #37252
2016-11-19Auto merge of #37822 - cuviper:llvm-link-shared, r=alexcrichtonbors-0/+5
rustbuild: allow dynamically linking LLVM The makefiles and `mklldeps.py` called `llvm-config --shared-mode` to find out if LLVM defaulted to shared or static libraries, and just went with that. But under rustbuild, `librustc_llvm/build.rs` was assuming that LLVM should be static, and even forcing `--link-static` for 3.9+. Now that build script also uses `--shared-mode` to learn the default, which should work better for pre-3.9 configured for dynamic linking, as it wasn't possible back then to choose differently via `llvm-config`. Further, the configure script now has a new `--enable-llvm-link-shared` option, which allows one to manually override `--link-shared` on 3.9+ instead of forcing static. Update: There are now four static/shared scenarios that can happen for the supported LLVM versions: - 3.9+: By default use `llvm-config --link-static` - 3.9+ and `--enable-llvm-link-shared`: Use `--link-shared` instead. - 3.8: Use `llvm-config --shared-mode` and go with its answer. - 3.7: Just assume static, maintaining the status quo.
2016-11-18Auto merge of #37769 - alexcrichton:rustbuild-python, r=brsonbors-8/+38
rustbuild: Allow configuration of python interpreter Add a configuration key to `config.toml`, read it from `./configure`, and add auto-detection if none of those were specified. Closes #35760
2016-11-16rustbuild: allow dynamically linking LLVMJosh Stone-0/+5
The makefiles and `mklldeps.py` called `llvm-config --shared-mode` to find out if LLVM defaulted to shared or static libraries, and just went with that. But under rustbuild, `librustc_llvm/build.rs` was assuming that LLVM should be static, and even forcing `--link-static` for 3.9+. Now that build script also uses `--shared-mode` to learn the default, which should work better for pre-3.9 configured for dynamic linking, as it wasn't possible back then to choose differently via `llvm-config`. Further, the configure script now has a new `--enable-llvm-link-shared` option, which allows one to manually override `--link-shared` on 3.9+ instead of forcing static.
2016-11-15Auto merge of #37742 - mrhota:llvm_debuginfo, r=alexcrichtonbors-0/+1
Add llvm debuginfo configure option CC @nnethercote @Mark-Simulacrum We add a new configure option, `--enable-llvm-debuginfo`, to do exactly what you'd think. Re: #31033 Fixes #37738
2016-11-15Auto merge of #37672 - japaric:msp430, r=alexcrichtonbors-1/+2
enable the MSP430 LLVM backend to let people experiment with this target out of tree. The MSP430 architecture is used in 16-bit microcontrollers commonly used in Digital Signal Processing applications. --- How this was tested: Declaring a custom target with the following specification: ``` json { "arch": "msp430", "data-layout": "e-m:e-p:16:16-i32:16:32-a:16-n8:16", "executables": true, "linker": "msp430-gcc", "llvm-target": "msp430", "max-atomic-width": 0, "no-integrated-as": true, "os": "none", "panic-strategy": "abort", "relocation-model": "static", "target-endian": "little", "target-pointer-width": "16" } ``` And this minimal file: ``` rust pub fn start() -> ! { loop {} } trait Copy {} trait Sized {} ``` Produces the following object files: ``` $ rustc --target=msp430 --emit=obj foo.rs $ msp430-objdump -Cd foo.o foo.o: file format elf32-msp430 Disassembly of section .text.start: 00000000 <start>: 0: 21 83 decd r1 2: 00 3c jmp $+2 ;abs 0x4 4: 00 3c jmp $+2 ;abs 0x6 6: ff 3f jmp $+0 ;abs 0x6 $ rustc --target=msp430 --emit=obj foo.rs -O $ msp430-objdump -Cd foo.o foo.o: file format elf32-msp430 Disassembly of section .text.start: 00000000 <start>: 0: ff 3f jmp $+0 ;abs 0x0 ``` --- r? @alexcrichton ~~TODO get this working with Makefiles so nightly releases include this backend~~ ~~TODO measure the increase in binary size~~ +187KiB (+0.47%) ~~FIXME --emit=obj produces empty object files~~
2016-11-14rustbuild: Tweak default rule inclusionAlex Crichton-2/+4
If a rule is flagged with `default(true)` then the pseudo-rule `default:foo` will include that. If a rule is also flagged with `.host(true)`, however, then the rule shouldn't be included for targets that aren't in the host array. This adds a filter to ensure we don't pull in host rules for targets by accident.
2016-11-14rustbuild: Allow configuration of python interpreterAlex Crichton-8/+38
Add a configuration key to `config.toml`, read it from `./configure`, and add auto-detection if none of those were specified. Closes #35760
2016-11-13Make LLVM debuginfo option names consistentA.J. Gardner-1/+1
2016-11-13Let rustbuild parse llvm debuginfo optionA.J. Gardner-0/+1
update_with_config_mk() needs to read the new llvm debuginfo config option from config.mk. Other than that, rustbuild already supports LLVM's RelWithDebInfo build type.
2016-11-12oops, forgot to commit a rustbuild related fileJorge Aparicio-1/+2
2016-11-12Auto merge of #37611 - Mark-Simulacrum:tari-nodejs-runner-detect, r=alexcrichtonbors-6/+9
compile-test: allow overriding nodejs binary location Add a command-line argument to manually specify which nodejs binary should be used, which disables the default search. Original work done by @tari. Fixes #34188.
2016-11-12Rollup merge of #37690 - TimNN:llvm-rel-dbg, r=alexcrichtonEduard-Mihai Burtescu-1/+14
rustbuild: support RelWithDebInfo for llvm r? @alexcrichton
2016-11-12Rollup merge of #37682 - cuviper:local-cargo, r=alexcrichtonEduard-Mihai Burtescu-1/+4
rustbuild: enable an initial local cargo This allows the initial build of src/bootstrap itself to use a local cargo taken from `configure --local-rust-root`. It was already finding rustc this way, but was always downloading cargo since it didn't know where to find it. It now matches the same logic that `config.rs` will use for stage0, where both rustc and cargo are taken from `CFG_LOCAL_RUST_ROOT`.
2016-11-12Rollup merge of #37584 - alexcrichton:travis, r=brsonEduard-Mihai Burtescu-1/+4
Move all Linux/OSX CI infastructure to Travis This commit configures our `.travis.yml` to test the full suite of tests we have on Buildbot right now. A whole mess of docker images are added to the `src/ci` directory which represent all the build environments for each configuration. Each of these environments is then configured in `.travis.yml` to run on the auto branch. Note that the full matrix of tests aren't intended to be run on all PRs. Instead, we continue to run only one entry in the matrix, forcing all others to finish quickly. Only the `auto` branch should run the full matrix of builds. Also note that the infrastructure hasn't quite been allocated yet to the rust-lang/rust repository, so everything is disabled for now except for the one build that happens on PRs. Once that infrastructure is allocated though we can enable this and let it fly! Notable modifications from the current test suite today: * Android tests are run in rustbuild instead of the makefiles, for whatever reason I couldn't get the makefiles to work on Travis. * A debuginfo test was updated to work with the current version of the Android NDK. * Some dependencies in `mk/tests.mk` were fixed to allow running tests in parallel.
2016-11-11bootstrap: rust-docs is a default packageBrian Anderson-0/+1
This will cause it to be built as part of `make dist`.
2016-11-11Move all Linux/OSX CI infastructure to TravisAlex Crichton-1/+4
This commit configures our `.travis.yml` to test the full suite of tests we have on Buildbot right now. A whole mess of docker images are added to the `src/ci` directory which represent all the build environments for each configuration. Each of these environments is then configured in `.travis.yml` to run on the auto branch. Note that the full matrix of tests aren't intended to be run on all PRs. Instead, we continue to run only one entry in the matrix, forcing all others to finish quickly. Only the `auto` branch should run the full matrix of builds. Also note that the infrastructure hasn't quite been allocated yet to the rust-lang/rust repository, so everything is disabled for now except for the one build that happens on PRs. Once that infrastructure is allocated though we can enable this and let it fly! Notable modifications from the current test suite today: * Android tests are run in rustbuild instead of the makefiles, for whatever reason I couldn't get the makefiles to work on Travis. * A debuginfo test was updated to work with the current version of the Android NDK. * Some dependencies in `mk/tests.mk` were fixed to allow running tests in parallel.
2016-11-10compiletest: detect nodejs binary, allow overrideMark-Simulacrum-6/+9
Allow passing a custom nodejs directory in configure.
2016-11-10rustbuild: support RelWithDebInfo for llvmTim Neumann-1/+14
2016-11-09rustbuild: enable an initial local cargoJosh Stone-1/+4
This allows the initial build of src/bootstrap itself to use a local cargo taken from `configure --local-rust-root`. It was already finding rustc this way, but was always downloading cargo since it didn't know where to find it. It now matches the same logic that `config.rs` will use for stage0, where both rustc and cargo are taken from `CFG_LOCAL_RUST_ROOT`.
2016-11-09Rollup merge of #37524 - alexcrichton:vendor, r=brsonEduard-Mihai Burtescu-12/+106
Vendor all rustbuild dependencies in this repo This commit vendors all crates.io dependencies into the rust-lang/rust repository using the `cargo-vendor` tool. This is done in an effort to make rustbuild distro-ready by ensuring that our source tarballs are self-contained units which don't need extraneous network downloads. A new `src/vendor` directory is created with all vendored crates, and Cargo, when using rustbuild, is configured to use this directory. Over time we can deduplicate this directory with the actual src tree (e.g. src/librustc_serialize, src/liblibc, src/libgetopts, ...). For now though that's left to a separate commit.
2016-11-08rustbuild: Fix check-error-index stepAlex Crichton-1/+3
If it ran too soon there wasn't a `test` directory lying around but we'll need one!
2016-11-08rustbuild: Tweak for vendored dependenciesAlex Crichton-12/+106
A few changes are included here: * The `winapi` and `url` dependencies were dropped. The source code for these projects is pretty weighty, and we're about to vendor them, so let's not commit to that intake just yet. If necessary we can vendor them later but for now it shouldn't be necessary. * The `--frozen` flag is now always passed to Cargo, obviating the need for tidy's `cargo_lock` check. * Tidy was updated to not check the vendor directory Closes #34687
2016-11-07rustbuild: support MIPS host buildsWang Xuerui-0/+16
There is a *little* code duplication, but primarily for sake of "match exhaustiveness". Let's blame Linux/MIPS for not exposing endianness explicitly in `uname -m` (that's user-space interface and as such is frozen). Currently the build won't work as we have to wait for a new stage0 for the MIPS host compilers, but this paves the way to self-hosted Rust on MIPS. The cross-compiled MIPS binaries are confirmed to work on the Loongson 3A2000 (MIPS64r2-compatible) so we have plenty of confidence that they'll work on other MIPS platforms too, as Linux/MIPS user-space ABI is consistent across machines of the same bitness.
2016-11-05Only test docs and such for the hostAlex Crichton-5/+14
2016-11-05Merge branch 'gdb-next-gen' of https://github.com/TimNN/rust into rollupAlex Crichton-20/+52
2016-11-05Fix tests from the rollupAlex Crichton-6/+64
2016-11-05Merge branch 'new-rustbuild' into rollupAlex Crichton-969/+1107