Does building libcore for a custom target require to use rust-nightly build?


I used stable-x86_64-unknown-linux-gnu unchanged - rustc 1.18.0 (03fc9d622 2017-06-06) to build a crate for a custom target. Xargo should build the core library even if it’s not specified in the dependency. Unexpectedly, the core build didn’t trigger at all. Instead, it complained of core not being found.

$ xargo build --target x86_64-unknown-none-gnu
error[E0463]: can't find crate for `core`
note: the `x86_64-unknown-none-gnu` target may not be installed

When I switched over to nightly (nightly-x86_64-unknown-linux-gnu unchanged - rustc 1.20.0-nightly (bf0a9e0b4 2017-07-10)), to my utter surprise; Xargo triggered a core build.

Is it like that building require require rust-nightly? What nightly feature does it depend on?


libcore depends on quite a few features:

However, the usual caveats with building code using nightly features don’t apply when compiling libcore with its associated version of rustc. We’d like to be in a place where you can build libcore/libstd/etc with a stable compiler as long as the versions match up - there was some discussion of this at the last Mozilla all hands a couple of weeks ago.