Closed
Description
Since #43320 bumped the bootstrap compiler, stage0 libstd fails to build when jemalloc is disabled:
error[E0463]: can't find crate for `alloc_jemalloc`
error: aborting due to previous error
error: Could not compile `std`.
I believe it needs to restore the logic removed here:
https://github.com/rust-lang/rust/pull/42727/files#diff-242481015141f373dcb178e93cffa850L236
I tried to add this to libstd/lib.rs
:
// Always use alloc_system during stage0 since we don't know if the alloc_*
// crate the stage0 compiler will pick by default is available (most
// obviously, if the user has disabled jemalloc in `./configure`).
#![cfg_attr(any(stage0, feature = "force_alloc_system"), feature(global_allocator))]
#![cfg(any(stage0, feature = "force_alloc_system"))]
#[global_allocator]
static ALLOC: alloc_system::System = alloc_system::System;
Then stage0 passed, but stage1 std failed like:
error[E0463]: can't find crate for `std`
error: aborting due to previous error
error: Could not compile `std`.
😕