about summary refs log tree commit diff
path: root/src/bootstrap
AgeCommit message (Collapse)AuthorLines
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-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
2016-11-03Set RUSTC_BOOTSTRAP to some value.Brian Anderson-1/+1
Environment variables on windows can't be empty.
2016-11-02rustbuild: Rewrite user-facing interfaceAlex Crichton-969/+1107
This commit is a rewrite of the user-facing interface to the rustbuild build system. The intention here is to make it much easier to compile/test the project without having to remember weird rule names and such. An overall view of the new interface is: # build everything ./x.py build # document everyting ./x.py doc # test everything ./x.py test # test libstd ./x.py test src/libstd # build libcore stage0 ./x.py build src/libcore --stage 0 # run stage1 run-pass tests ./x.py test src/test/run-pass --stage 1 The `src/bootstrap/bootstrap.py` script is now aliased as a top-level `x.py` script. This `x` was chosen to be both short and easily tab-completable (no collisions in that namespace!). The build system now accepts a "subcommand" of what to do next, the main ones being build/doc/test. Each subcommand then receives an optional list of arguments. These arguments are paths in the source repo of what to work with. That is, if you want to test a directory, you just pass that directory as an argument. The purpose of this rewrite is to do away with all of the arcane renames like "rpass" is the "run-pass" suite, "cfail" is the "compile-fail" suite, etc. By simply working with directories and files it's much more intuitive of how to run a test (just pass it as an argument). The rustbuild step/dependency management was also rewritten along the way to make this easy to work with and define, but that's largely just a refactoring of what was there before. The *intention* is that this support is extended for arbitrary files (e.g. `src/test/run-pass/my-test-case.rs`), but that isn't quite implemented just yet. Instead directories work for now but we can follow up with stricter path filtering logic to plumb through all the arguments.
2016-10-31rustbuild+configure: convert unix style paths on windowsTim Neumann-14/+37
2016-10-31rustbuild+configure: improve bin/exe joiningTim Neumann-3/+23
2016-10-31detect gdb version & rust support in compiletestTim Neumann-5/+17
2016-10-30Use quieter test output when running tests on Travis CI.Corey Farwell-1/+18
Fixes https://github.com/rust-lang/rust/issues/36788.
2016-10-22Rollup merge of #37209 - srinivasreddy:bootstrap_bin, r=nrcGuillaume Gomez-13/+16
run rustfmt on bootstrap/bin folder
2016-10-20Auto merge of #37280 - alexcrichton:debuginfo, r=brsonbors-0/+10
Enable line number debuginfo in releases This commit enables by default passing the `-C debuginfo=1` argument to the compiler for the stable, beta, and nightly release channels. A new configure option was also added, `--enable-debuginfo-lines`, to enable this behavior in developer builds as well. Closes #36452
2016-10-19Enable line number debuginfo in releasesAlex Crichton-0/+10
This commit enables by default passing the `-C debuginfo=1` argument to the compiler for the stable, beta, and nightly release channels. A new configure option was also added, `--enable-debuginfo-lines`, to enable this behavior in developer builds as well. Closes #36452
2016-10-19Detect local-rebuild by just the MAJOR.MINOR versionJosh Stone-3/+3
A new point-release shouldn't change any language semantics, so a local stage0 that matches MAJOR.MINOR version should still be considered a local-rebuild as far as `--cfg stageN` features go. e.g. `1.14.0` should be considered a local-rebuild for any `1.14.X`. (Bootstrap keys used to be an issue too, until #37265.)
2016-10-19Rollup merge of #37265 - brson:bootstrap, r=alexcrichtonEduard-Mihai Burtescu-14/+8
Allow bootstrapping without a key. Fixes #36548 This will make it easier for packagers to bootstrap rustc when they happen to have a bootstrap compiler with a slightly different version number. It's not ok for anything other than the build system to set this environment variable. r? @alexcrichton
2016-10-19Allow bootstrapping without a key. Fixes #36548Brian Anderson-14/+8
This will make it easier for packagers to bootstrap rustc when they happen to have a bootstrap compiler with a slightly different version number. It's not ok for anything other than the build system to set this environment variable.
2016-10-16run rustfmt on bootstrap/bin folderSrinivas Reddy Thatiparthy-13/+16
2016-10-14Add AppVeyor configuration to the repoAlex Crichton-9/+21
We hope to move to AppVeyor in the near future off of Buildbot + EC2. This adds an `appveyor.yml` configuration file which is ready to run builds on the auto branch. This is also accompanied with a few minor fixes to the build system and such to accomodate AppVeyor. The intention is that we're not switching over to AppVeyor entirely just yet, but rather we'll watch the builds for a week or so. If everything checks out then we'll start gating on AppVeyor instead of Buildbot!
2016-10-13rustbuild: Less panics in musl_rootAlex Crichton-1/+2
Don't panic if the target wasn't configured.
2016-10-11Auto merge of #36983 - alexcrichton:configure-multiple-musl, r=brsonbors-0/+30
configure: Add options for separate musl roots This allows using the `./configure` script to enable rustbuild to compile multiple musl targets at once. We'll hopefully use this soon on our bots to produce a bunch of targets.
2016-10-08rustbuild: Optimize build times slightlyAlex Crichton-46/+27
As the entry point for building the Rust compiler, a good user experience hinges on this compiling quickly to get to the meat of the problem. To that end use `#[cfg]`-specific dependencies to avoid building Windows crates on Unix and drop the `regex` crate for now which was easily replacable with some string searching.
2016-10-08Auto merge of #37039 - Manishearth:rollup, r=Manishearthbors-212/+75
Rollup of 6 pull requests - Successful merges: #36937, #37016, #37028, #37029, #37031, #37034 - Failed merges: #37027
2016-10-08Rollup merge of #37028 - alexcrichton:fix-deps, r=japaricManish Goregaokar-1/+1
rustbuild: Fix dependencies of check-docs step Some of the doc tests depend on `extern crate test`, so depend on libtest instead of libstd here.
2016-10-07rustbuild: Use `cargo metadata` to learn about DAGAlex Crichton-61/+70
This updates the commit to use workspaces to use `cargo metadata` instead of hardcoded lists about what to test. This should help us be resilient to updates in the future on behalf of the crate DAG and minimize the amount of files that need to be touched.
2016-10-07rustbuild: Fix dependencies of check-docs stepAlex Crichton-1/+1
Some of the doc tests depend on `extern crate test`, so depend on libtest instead of libstd here.
2016-10-07Use workspaces and switch to a single Cargo.lock.Ahmed Charles-189/+43
This involves hacking the code used to run cargo test on various packages, because it reads Cargo.lock to determine which packages should be tested. This change implements a blacklist, since that will catch new crates when they are added in the future.
2016-10-06Prevent accidentally running 'make install' as sudo.Ahmed Charles-0/+4
2016-10-06Auto merge of #35641 - ahmedcharles:install, r=alexcrichtonbors-7/+91
rustbuild: Add install target. #34675 It just prints to the screen currently. r? @alexcrichton I'm working on the next commit to actually have it install.
2016-10-05Add support for docdir, libdir and mandir.Ahmed Charles-5/+30
2016-10-05Install docs, std and rustc using results from dist.Ahmed Charles-6/+32
2016-10-05rustbuild: Add install target. #34675Ahmed Charles-4/+37
It just prints to the screen currently.