Auto merge of #4817 - alexcrichton:incremental-by-default, r=matklad
authorbors <bors@rust-lang.org>
Thu, 21 Dec 2017 18:57:07 +0000 (18:57 +0000)
committerbors <bors@rust-lang.org>
Thu, 21 Dec 2017 18:57:07 +0000 (18:57 +0000)
commite10c651ea142f0a8c077bc717462b2ea233e7e1c
tree73b65c8c5366631733743d0794c368d190dce116
parentfac7e2559a5ceebcf3e710e2076f9ca3df9ab465
parent45cc30bc7379ae13b079157b660de9d084de7a9e
Auto merge of #4817 - alexcrichton:incremental-by-default, r=matklad

Enable incremental by default

This commit enables incremental compilation by default in Cargo for all
dev-related profiles (aka anything without `--release` or `bench`. A
number of new configuration options were also added to tweak how
incremental compilation is exposed and/or used:

* A `profile.dev.incremental` field is added to `Cargo.toml` to disable
  it on a per-project basis (in case of bugs).
* A `build.incremental` field was added in `.cargo/config` to disable
  globally (or enable if we flip this default back off).

Otherwise `CARGO_INCREMENTAL` can still be used to configure one
particular compilation. The global `build.incremental` configuration
cannot currently be used to enable it for the release profile.