Open
Description
Bug
I've made a minimal reproducible repo: https://github.com/tombh/nightly_cross_minimal_repro
Pasting main.rs
:
#![feature(rustc_private)]
extern crate rustc_ast;
extern crate rustc_driver;
extern crate rustc_macros;
fn main() {
println!("{}", rustc_ast::node_id::CRATE_NODE_ID)
}
The build commands are here: https://github.com/tombh/nightly_cross_minimal_repro/blob/main/.github/workflows/ci.yml
Pasting the most relevant part:
rustup toolchain install nightly-2024-09-30
rustup default nightly-2023-09-30
rustup target add aarch64-unknown-linux-gnu
rustup component add rust-src rustc-dev-aarch64-unknown-linux-gnu llvm-tools
...
cargo -v build --locked --release --target aarch64-unknown-linux-gnu
And here is the failing build: https://github.com/tombh/nightly_cross_minimal_repro/actions/runs/11463471346/job/31897390824#step:5:9
Also, just out of interest, here is a failing build with a more recent nightly (nightly-2024-10-21
), it fails differently, it can't find derive_where
: https://github.com/tombh/nightly_cross_minimal_repro/actions/runs/11463505291/job/31897508604#step:5:9
Relevant Issues
- The bug is being discussed in a
rustup
issue: "Can't find crate forrustc_*
" when cross-compiling a crate withrustc_private
on rustup#3255. That is where it was suggested that this is rather arust
orcargo
issue. - build fails with error[E0463]: can't find crate for
rustc_macros
whichrustc
depends on in rustc_llvm #62447 - Duplication of libLLVM-*.so in the distributed rustc component. #70838