Skip to content

Nightly rustc-dev can't be used in cross-compilation #132728

Open
@tombh

Description

@tombh

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-crossArea: Cross compilationC-bugCategory: This is a bug.T-infraRelevant to the infrastructure team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions