about summary refs log tree commit diff
path: root/src/bootstrap/lib.rs
AgeCommit message (Collapse)AuthorLines
2017-07-17Allow remote testing remotely when `TEST_DEVICE_ADDR` is setMátyás Mustoha-1/+2
2017-07-07Fix stage 2 builds with a custom libdir.Matthew Dawson-2/+8
When copying libstd for the stage 2 compiler, the builder ignores the configured libdir/libdir_relative configuration parameters. This causes the compiler to fail to find libstd, which cause any tools built with the stage 2 compiler to fail. To fix this, make the copy steps of rustbuild aware of the libdir_relative parameter when the stage >= 2. Also update the dist target to be aware of the new location of libstd.
2017-07-05rustbuild: Only -Zsave-analysis for libstdAlex Crichton-1/+3
Don't pass the flag when we're compiling the compiler or other related tools
2017-07-04Use build.build instead of build.config.buildMark Simulacrum-1/+1
2017-07-04Move targets, hosts, and build triple into Build.Mark Simulacrum-1/+37
2017-07-04Store verbosity on BuildMark Simulacrum-4/+13
Prevents accidental mistakes in not using the right verbosity by going to only config or flags.
2017-07-04Store positive instead of negative fail_fast.Mark Simulacrum-1/+2
This makes later negation much easier to interpret.
2017-07-04Remove src_is_git, instead call method on rust_info directly.Mark Simulacrum-2/+0
2017-07-04Clarify meaning of Build.cargo, Build.rustc.Mark Simulacrum-24/+14
Rename Build.{cargo, rustc} to {initial_cargo, initial_rustc}.
2017-07-04Update a few comments.Mark Simulacrum-8/+6
2017-07-04Clippy lintsMark Simulacrum-7/+7
2017-06-30rustbuild: set __CARGO_DEFAULT_LIB_METADATA to channelMarc-Antoine Perennou-1/+1
Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
2017-06-22Make Build.cxx() return a Result instead of panickingIan Douglas Scott-7/+10
2017-06-22Set CXX_<target> in bootstrapIan Douglas Scott-0/+1
2017-06-19Bump version and stage0 compilerAlex Crichton-23/+0
2017-06-16Auto merge of #42612 - est31:master, r=nagisabors-0/+5
Autogenerate stubs and SUMMARY.md in the unstable book Removes a speed bump in compiler development by autogenerating stubs for features in the unstable book. See #42454 for discussion. The PR contains three commits, separated in order to make review easy: * The first commit converts the tidy tool from a binary crate to a crate that contains both a library and a binary. In the second commit, we'll use the tidy library * The second and main commit introduces autogeneration of SUMMARY.md and feature stub files * The third commit turns off the tidy lint that checks for features without a stub, and removes the stub files. A separate commit due to the large number of files touched Members of the doc team who wish to document some features can either do this (where `$rustsrc` is the root of the rust repo git checkout): 1. cd to `$rustsrc/src/tools/unstable-book-gen` and then do `cargo run $rustsrc/src $rustsrc/src/doc/unstable-book` to put the stubs into the unstable book 2. cd to `$rustsrc` and run `git ls-files --others --exclude-standard` to list the newly added stubs 3. choose a file to edit, then `git add` it and `git commit` 4. afterwards, remove all changes by the tool by doing `git --reset hard` and `git clean -f` Or they can do this: 1. remove the comment marker in `src/tools/tidy/src/unstable_book.rs` line 122 2. run `./x.py test src/tools/tidy` to list the unstable features which only have stubs 3. revert the change in 1 3. document one of the chosen unstable features The changes done by this PR also allow for further development: * tidy obtains information about tracking issues. We can now forbid differing tracking issues between differing `#![unstable]` annotations. I haven't done this but plan to in a future PR * we now have a general framework for generating stuff for the unstable book at build time. Further changes can autogenerate a list of the API a given library feature exposes. The old way to simply click through the documentation after it has been uploaded to rust-lang.org works as well. r? @nagisa Fixes #42454
2017-06-14Autogenerate stubs and the summary of the unstable bookest31-0/+5
2017-06-04Merge branch 'profiling' of github.com:whitequark/rust into profilingMarco Castelluccio-0/+3
2017-06-02rustbuild: Add `./x.py test --no-fail-fast`Josh Stone-1/+20
This option forwards to each `cargo test` invocation, and applies the same logic across all test steps to keep going after failures. At the end, a brief summary line reports how many commands failed, if any. Note that if a test program fails to even start at all, or if an auxiliary build command related to testing fails, these are still left to stop everything right away. Fixes #40219.
2017-06-02ci: Improve log output (mainly Travis).kennytm-1/+19
* 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-05-22bootstrap: fix minor comment typos in lib.rsAnders Papitto-6/+6
I noticed these while reading through the build system documentation. They're hardly worth fixing, but I'm also using this to get my feet wet with the rustc contribution system.
2017-05-20Auto merge of #42069 - QuietMisdreavus:low_pri, r=alexchrichtonbors-3/+18
Add an option to run rustbuild on low priority on Windows and Unix This is a resurrection of #40776, combining their Windows setup with an additional setup on Unix to set the program group's *nice*ness to +10 (low-but-not-lowest priority, mirroring the priority in the Windows setup) when the `low_priority` option is on.
2017-05-18fix casting of PRIO_PGRPQuietMisdreavus-9/+1
2017-05-18Move submodule initialization to bootstrap.pyTatsuyuki Ishi-118/+1
2017-05-18Add metadata suffix, close rust-lang/cargo#4028Tatsuyuki Ishi-5/+23
2017-05-16Add an option to run rustbuild on low priorityJohn Kåre Alsaker-3/+26
This is a resurrection of #40776, combining their Windows setup with an additional setup on Unix to set the program group's niceness to +10 (low-but-not-lowest priority) when the `low_priority` option is on.
2017-05-11rustbuild: Use `-Z force-unstable-if-unmarked`Alex Crichton-2/+5
2017-05-01Add profiling support, through the rustc -Z profile flag.whitequark-0/+3
When -Z profile is passed, the GCDAProfiling LLVM pass is added to the pipeline, which uses debug information to instrument the IR. After compiling with -Z profile, the $(OUT_DIR)/$(CRATE_NAME).gcno file is created, containing initial profiling information. After running the program built, the $(OUT_DIR)/$(CRATE_NAME).gcda file is created, containing branch counters. The created *.gcno and *.gcda files can be processed using the "llvm-cov gcov" and "lcov" tools. The profiling data LLVM generates does not faithfully follow the GCC's format for *.gcno and *.gcda files, and so it will probably not work with other tools (such as gcov itself) that consume these files.
2017-04-29Update stage0 bootstrap compilerAlex Crichton-3/+3
We've got a freshly minted beta compiler, let's update to use that on nightly! This has a few other changes associated with it as well * A bump to the rustc version number (to 1.19.0) * Movement of the `cargo` and `rls` submodules to their "proper" location in `src/tools/{cargo,rls}`. Now that Cargo workspaces support the `exclude` option this can work. * Updates of the `cargo` and `rls` submodules to their master branches. * Tweak to the `src/stage0.txt` format to be more amenable for Cargo version numbers. On the beta channel Cargo will bootstrap from a different version than rustc (e.g. the version numbers are different), so we need different configuration for this. * Addition of `dev` as a readable key in the `src/stage0.txt` format. If present then stage0 compilers are downloaded from `dev-static.rust-lang.org` instead of `static.rust-lang.org`. This is added to accomodate our updated release process with Travis and AppVeyor.
2017-04-29Auto merge of #41577 - Keruspe:master, r=alexcrichtonbors-0/+5
rustbuild improvements Properly hook up cargo and rls in the build phase, and install them, when extended build is enabled.
2017-04-27travis: Parallelize tests on AndroidAlex Crichton-0/+6
Currently our slowest test suite on android, run-pass, takes over 5 times longer than the x86_64 component (~400 -> ~2200s). Typically QEMU emulation does indeed add overhead, but not 5x for this kind of workload. One of the slowest parts of the Android process is that *compilation* happens serially. Tests themselves need to run single-threaded on the emulator (due to how the test harness works) and this forces the compiles themselves to be single threaded. Now Travis gives us more than one core per machine, so it'd be much better if we could take advantage of them! The emulator itself is still fundamentally single-threaded, but we should see a nice speedup by sending binaries for it to run much more quickly. It turns out that we've already got all the tools to do this in-tree. The qemu-test-{server,client} that are in use for the ARM Linux testing are a perfect match for the Android emulator. This commit migrates the custom adb management code in compiletest/rustbuild to the same qemu-test-{server,client} implementation that ARM Linux uses. This allows us to lift the parallelism restriction on the compiletest test suites, namely run-pass. Consequently although we'll still basically run the tests themselves in single threaded mode we'll be able to compile all of them in parallel, keeping the pipeline much more full and using more cores for the work at hand. Additionally the architecture here should be a bit speedier as it should have less overhead than adb which is a whole new process on both the host and the emulator! Locally on an 8 core machine I've seen the run-pass test suite speed up from taking nearly an hour to only taking 6 minutes. I don't think we'll see quite a drastic speedup on Travis but I'm hoping this change can place the Android tests well below 2 hours instead of just above 2 hours. Because the client/server here are now repurposed for more than just QEMU, they've been renamed to `remote-test-{server,client}`. Note that this PR does not currently modify how debuginfo tests are executed on Android. While parallelizable it wouldn't be quite as easy, so that's left to another day. Thankfully that test suite is much smaller than the run-pass test suite. As a final fix I discovered that the ARM and Android test suites were actually running all library unit tests (e.g. stdtest, coretest, etc) twice. I've corrected that to only run tests once which should also give a nice boost in overall cycle time here.
2017-04-27rustbuild: add rls_package_versMarc-Antoine Perennou-0/+5
Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
2017-04-25Auto merge of #41362 - alexcrichton:run-cargot-ests, r=aturonbors-0/+13
Run tests for the cargo submodule in tree Previously the `cargotest` suite would run some arbitrary revision of Cargo's test suite, but now that we're bundling it in tree we should be running the Cargo submodule's test suite instead.
2017-04-24Auto merge of #40123 - TimNN:llvm40, r=alexcrichtonbors-0/+7
LLVM 4.0 Upgrade Since nobody has done this yet, I decided to get things started: **Todo:** * [x] push the relevant commits to `rust-lang/llvm` and `rust-lang/compiler-rt` * [x] cleanup `.gitmodules` * [x] Verify if there are any other commits from `rust-lang/llvm` which need backporting * [x] Investigate / fix debuginfo ("`<optimized out>`") failures * [x] Use correct emscripten version in docker image --- Closes #37609. --- **Test results:** Everything is green 🎉
2017-04-24Run tests for the cargo submodule in treeAlex Crichton-0/+13
Previously the `cargotest` suite would run some arbitrary revision of Cargo's test suite, but now that we're bundling it in tree we should be running the Cargo submodule's test suite instead.
2017-04-23FIN: Compile LLVM with -fno-omit-frame-pointer on 32bit MinGW buildsTim Neumann-0/+7
to work around an apparently bad optimization.
2017-04-17Disable debuginfo when compiling toolsAlex Crichton-2/+7
Currently the Cargo binary has jumped from 14M to 34M on the beta channel, which appears to be due to the fact that we're compiling tools with debug information inside them. This additionally means that the `rls` binary is 62M right now! This wasn't an intentional change, so be sure to disable debuginfo when compiling tools as it's just intended for the standard library and compile for now.
2017-04-11Touch up rls integrationAlex Crichton-0/+3
* Use the right version when building combined installer * Update dependencies of rls as it depends on rustc and plugins * Fix build-manifest and the versions it uses for the rls
2017-04-10Remove --enable-save-analysis configure flagNick Cameron-1/+1
2017-04-10Reviewer changesNick Cameron-20/+6
2017-04-10Build an RLS package as part of the dist targetNick Cameron-0/+15
2017-04-03Loosen src_is_git to just check exists()Josh Stone-1/+1
2017-04-03Add a common Build::src_is_git flagJosh Stone-4/+4
2017-03-21rustbuild: Don't hardcode 'nightly' for CargoAlex Crichton-0/+5
It now follows rustc release trains
2017-03-19Rollup merge of #40554 - nrc:rls-data, r=alexcrichtonCorey Farwell-2/+23
Use rls-data crate This basically pulls out a bunch of data structures used by save-analysis for serialization into an external crate, and pulls that crate in using Rustbuild. The RLS can then share these data structures with the compiler which in some cases will allow more efficient communication between the compiler and the RLS (i.e., without serialisation). Along the way, I have to pull in rls-span, which is the RLS's way of defining spans (more type-safe than the compiler's built-in way). This is basically just to convert from compiler spans to RLS spans. I also pull in the crates.io version of rustc-serialize, which is a bit annoying, but seems to be the only way to have serialisable data in an external crate. To make this work, all of the save-analysis crate has to use this version too (cc #40527). Finally I pull in a line from #40347 to make the unstable crate checking stuff working. There are a lot of changes to save-analysis but they are all mechanical and trivial - changing from using `From` to `Into` (because of orphan rules) being the main thing. r? @alexcrichton
2017-03-17Rollup merge of #40457 - frewsxcv:frewsxcv-macos, r=steveklabnikCorey Farwell-1/+1
Update usages of 'OSX' (and other old names) to 'macOS'. As of last year with version 'Sierra', the Mac operating system is now called 'macOS'.
2017-03-17Fix handlebars failure by using the `rustbuild` feature less indiscriminately.Nick Cameron-2/+23
2017-03-15Auto merge of #40383 - ishitatsuyuki:easy-dist-analysis, r=alexcrichtonbors-1/+1
rustbuild: Make save-analysis an option This makes save-analysis an option independent from the release channel. The CI build scripts have been modified to enable the flag. *Merge with caution.* I haven't tested this, and this can cause nightly breakage.
2017-03-12Update usages of 'OSX' (and other old names) to 'macOS'.Corey Farwell-1/+1
As of last year with version 'Sierra', the Mac operating system is now called 'macOS'.
2017-03-12Update Cargo to fix nightly channelAlex Crichton-1/+1
This commit updates Cargo with rust-lang/cargo#3820 which includes a fix for rust-lang/cargo#3819. At the same time this also slightly tweaks how rustbuild builds cargo to ensure that all the build information (including git info and such) makes its way into the binary. Closes rust-lang/cargo#3820