build-std: always by davidtwco · Pull Request #3874 · rust-lang/rfcs (original) (raw)
Add a new Cargo configuration option, build-std = "always|never", which will unconditionally rebuild standard library dependencies. The set of standard library dependencies can optionally be customised with a new build-std-crates option. It also describes how Cargo (or external tools) should build the standard library crates on stable (i.e., which flags to pass and features to enable).
This proposal limits the ways the built standard library can be customised (such as by settings in the profile) and intends that the build standard library matches the prebuilt one (if available) as closely as possible.
This RFC is is part of the build-std project goal and a series of build-std RFCs:
- build-std context (build-std: context #3873)
build-std="always"(this RFC)- Explicit standard library dependencies (build-std: explicit dependencies #3875)
build-std="compatible"(RFC not opened yet)build-std="match-profile"(RFC not opened yet)
There is also a Zulip channel where you can ask questions about any of the build-std RFCs. This series of RFCs was drafted over many months with the help of stakeholders from many Rust project teams, we thank them for their help!