about summary refs log tree commit diff
path: root/src/bootstrap/bootstrap.py
AgeCommit message (Collapse)AuthorLines
2017-04-30Rename os variable in bootstrap.py to avoid shadowing os module.Titus Barik-2/+2
2017-04-29Update stage0 bootstrap compilerAlex Crichton-17/+27
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-26Rollup merge of #41456 - jessicah:haiku-support, r=alexcrichtonAriel Ben-Yehuda-0/+3
Haiku: fix initial platform support
2017-04-26Rollup merge of #41370 - malbarbo:android-bootstrap, r=alexcrichtonAriel Ben-Yehuda-6/+16
Add bootstrap support for android
2017-04-24Haiku: add missing cases of using LIBRARY_PATHJessica Hamilton-0/+3
2017-04-18Add bootstrap support for androidMarco A L Barbosa-6/+16
2017-04-17bootstrap: Don't workaround uname -m on DarwinRicho Healey-8/+0
This no longer manifests on any versions of OSX that I could find.
2017-04-08Rollup merge of #41152 - cuviper:bootstrap-armv7, r=japaricTim Neumann-2/+2
bootstrap.py: fix armv7 detection This matches the logic that was in `./configure` before f8ca805422db8.
2017-04-07bootstrap.py: fix armv7 detectionJosh Stone-2/+2
This matches the logic that was in `./configure` before f8ca805422db8.
2017-04-06Auto merge of #41102 - frewsxcv:rollup, r=frewsxcvbors-2/+5
Rollup of 5 pull requests - Successful merges: #40908, #41011, #41026, #41037, #41050 - Failed merges:
2017-04-02Finish the improvements I planned.Nathan Stocks-2/+3
- No more manual args manipulation -- getopts used for everything. As a result, options can be in any position, now, even before the subcommand. - The additional options for test, bench, and dist now appear in the help output. - No more single-letter variable bindings used internally for large scopes. - Don't output the time measurement when just invoking 'x.py' - Logic is now much more linear. We build strings up, and then print them.
2017-03-30Don't print build statistics if we explicitly asked for the help message.Nathan Stocks-2/+4
2017-03-30Fix stage0->stage1 build when using "pthreads" mingw compiler.Vadim Chugunov-1/+10
2017-03-29rustbuild: Update bootstrap compilerAlex Crichton-12/+5
Now that we've also updated cargo's release process this commit also changes the download location of Cargo from Cargos archives back to the static.r-l.o archives. This should ensure that the Cargo download is the exact Cargo paired with the rustc that we release.
2017-03-11configure: Remove --build detectionAlex Crichton-4/+19
This commit removes detection of CFG_OSTYPE and CFG_CPUTYPE from the configure script, which means that the default value of `--build` is no longer present in the configure script. All this logic is now available in rustbuild itself, so there's no need to duplicate it.
2017-03-10Support armhf abi on 64-bit ARM cpusXimin Luo-1/+1
They report their `uname -m` as armv8l rather than aarch64. Patch originally by Matthias Klose <doko@debian.org>
2017-03-04bootstrap.py: Report build statusVadim Petrochenkov-6/+15
Move some code from x.py to bootstrap.py
2017-02-25Rollup merge of #39950 - ishitatsuyuki:stop-trashing-ldpath, r=alexcrichtonEduard-Mihai Burtescu-2/+6
bootstrap: stop trashing (DY)LD_LIBRARY_PATH This generated an ugly error with fakeroot before.
2017-02-25Rollup merge of #39903 - binarycrusader:issue-39901, r=alexcrichtonEduard-Mihai Burtescu-0/+2
add solaris sparcv9 support Fixes #39901
2017-02-23rustbuild: Retry downloads by defaultAlex Crichton-4/+17
Don't rely on curl's --retry, it appears to not work for some errors like SSL errors.
2017-02-20bootstrap: stop trashing (DY)LD_LIBRARY_PATHTatsuyuki Ishi-2/+6
This generated an ugly error with fakeroot before.
2017-02-17Auto merge of #39578 - canndrew:nixos-bootstrap-fix, r=alexcrichtonbors-0/+56
Fix for bootstrapping on NixOS NixOS puts Linux's dynamic loader in wierd place. Detect when we're on NixOS and patch the downloaded bootstrap executables appropriately.
2017-02-17Style fixupsAndrew Cann-5/+6
2017-02-16add solaris sparcv9 supportShawn Walker-Salas-0/+2
* Update bootstrap to recognize the cputype 'sparcv9' (used on Solaris) * Change to never use -fomit-frame-pointer on Solaris or for sparc * Adds rust target sparcv9-sun-solaris Fixes #39901
2017-02-14Auto merge of #39728 - eddyb:vendeur-tres-bien, r=alexcrichtonbors-0/+5
Automate vendoring by invoking cargo-vendor when building src dist tarballs. This avoids #39633 bringing the `src/vendor` checked into git by #37524, past 200,000 lines of code. I believe the strategy of having rustbuild run `cargo vendor` during the `dist src` step is sound. However, the only way to be sure `cargo-vendor` exists is to run `cargo install --force cargo-vendor`, which will recompile it every time (not passing `--force` means you can't tell between "already exists" and "build error"). ~~This is quite suboptimal and I'd like to somehow do it in each `Dockerfile` that would need it.~~ * [ ] Cache `CARGO_HOME` (i.e. `~/.cargo`) between CI runs * `bin/cargo-vendor` and the actual caches are the relevant bits * [x] Do not build `cargo-vendor` all the time * ~~Maybe detect `~/.cargo/bin/cargo-vendor` already exists?~~ * ~~Could also try to build it in a `Dockerfile` but do we have `cargo`/`rustc` there?~~ * Final solution: check `cargo install --list` for a line starting with `cargo-vendor ` cc @rust-lang/tools
2017-02-14Automatically vendor Cargo deps when building the source tarballs.Eduard-Mihai Burtescu-0/+5
2017-02-12fix portability issue in error handling of build_tripleShawn Walker-Salas-1/+1
2017-02-11fix exception handling for isainfo execution failureShawn Walker-Salas-1/+1
remove unnecessary gcc_s addition in libstd for Solaris
2017-02-11fix copy pastaShawn Walker-Salas-1/+1
Don't need to catch WindowsError. That was very silly of me.
2017-02-11Add Solaris as recognized ostypeShawn Walker-Salas-0/+15
Add cputype recognition for Solaris Fixes #39729
2017-02-11Change test for being on nixos againAndrew Cann-1/+1
2017-02-11Change test for being on NixOSAndrew Cann-1/+1
2017-02-06Fix for bootstrapping on NixOSAndrew Cann-1/+56
NixOS puts Linux's dynamic loader in wierd place. Detect when we're on NixOS and patch the downloaded bootstrap executables appropriately.
2017-02-05Rollup merge of #39491 - dumbbell:support-aarch64-unknown-freebsd, ↵Corey Farwell-0/+2
r=alexcrichton Support aarch64-unknown-freebsd
2017-02-03`aarch64` CPU type is called `arm64` on FreeBSDJean-Sébastien Pédron-0/+2
2017-02-02Fix typo in bootstrap.py info messageDirkjan Ochtman-1/+1
2017-02-02Guard against USER not existing in the environmentDirkjan Ochtman-1/+1
2017-02-02Don't check for sudo environment if vendored sources are already configuredDirkjan Ochtman-1/+1
2017-01-07rustbuild: Pass --retry 3 to curlAlex Crichton-1/+1
Try to handle spurious network failures on Travis by automatically retrying failed downloads on Travis.
2016-12-19rustbuild: Update Cargo download locationAlex Crichton-13/+9
I updated the beta compiler used to bootstrap the master branch in #38438 with the intention of fixing Travis OSX linkage issues but I mistakenly forgot that the PR only updated rustc, not Cargo itself. Cargo has a new release process with downloads in a different location, so this commit updates rustbuild to download from this new location by tracking revisions instead of Cargo nightly dates.
2016-12-19add and document `--incremental` flag along with misc other changesNiko Matsakis-0/+2
For example: - we now support `-vv` to get very verbose output. - RUSTFLAGS is respected by `x.py` - better error messages for some cases
2016-12-07mk: Switch rustbuild to the default build systemAlex Crichton-26/+67
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-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-3/+24
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: Tweak for vendored dependenciesAlex Crichton-3/+24
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-02rustbuild: Rewrite user-facing interfaceAlex Crichton-4/+2
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-09-17inherit from objectEitan Adler-5/+6
2016-09-16Try to support py3 with rustbuild betterSimonas Kazlauskas-3/+5
2016-07-06Rollup merge of #34558 - GlenDC:master, r=alexcrichtonSteve Klabnik-1/+1
rustbuild: propagate bootstrap.py '--help' flag Fixes #34534. r? @alexcrichton