rust-lang / rust-lang/rust

Rust v1.91.1 bootstrap build fails (tier-check) on custom target (poky) build

Open
#149,171 14 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

C-bug O-yocto S-needs-info T-bootstrap
Dominant language
Rust
Stars
119k
Forks
16.1k
PR merge metrics
PR metrics pending

Description

When building Rust 1.91.1 inside the Yocto build system, the bootstrap process fails during the execution of the tier-check tool. The failure consistently occurs in the step where cargo run executes the src/tools/tier-check binary.

I believe "Building stage1 run_make_support (stage0 -> stage1, x86_64-unknown-linux-gnu)" and "Building stage2 cargo (stage1 -> stage2, x86_64-unknown-linux-gnu)" are the new build steps starting from v1.91.

Perhaps this PR might be related:
https://github.com/rust-lang/rust/pull/145663/commits

The issue was observed when testing with x86-64 target.
However, it passed for arm64 target.
How to fix this issue or am I overlooking something?

Command used
python3 src/bootstrap/bootstrap.py test  --exclude src/bootstrap  --exclude src/doc/rustc  --exclude src/doc/rustdoc  --exclude src/doc/unstable-book  --exclude src/etc/test-float-parse  --exclude src/librustdoc  --exclude src/rustdoc-json-types  --exclude src/tools/coverage-dump  
--exclude src/tools/jsondoclint  --exclude src/tools/lint-docs  --exclude src/tools/replace-version-placeholder  --exclude src/tools/rust-analyzer  --exclude src/tools/rustdoc-themes  --exclude src/tools/rust-installer  
--exclude src/tools/test-float-parse  --exclude src/tools/suggest-tests  --exclude src/tools/tidy  --exclude tests/assembly-llvm/asm/aarch64-outline-atomics.rs  
--exclude tests/codegen-llvm/issues/issue-122805.rs  --exclude tests/codegen-llvm/thread-local.rs  --exclude tests/mir-opt/  --exclude tests/run-make  --exclude tests/run-make-fulldeps  --exclude tests/rustdoc  --exclude tests/rustdoc-json  
--exclude tests/rustdoc-js-std  --exclude tests/ui/abi/stack-probes-lto.rs  --exclude tests/ui/abi/stack-probes.rs  --exclude tests/ui/codegen/mismatched-data-layouts.rs  --exclude tests/codegen-llvm/rust-abi-arch-specific-adjustment.rs  
--exclude tests/ui/feature-gates/version_check.rs  --exclude tests/ui-fulldeps/  
--exclude tests/ui/panics/panic-abort-backtrace-without-debuginfo.rs  
--exclude tests/ui/process/nofile-limit.rs  --exclude tidyselftest --no-doc --no-fail-fast --bless --target x86_64-oe-linux-gnu' returned non-zero exit status 1:

Result
1 command(s) did not execute successfully: 69225 69226   

- Command /home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/recipe-sysroot-native/usr/bin/cargo run --target x86_64-unknown-linux-gnu -Zbinary-dep-depinfo -j 192 
-Zroot-dir=/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src --frozen --release --manifest-path /home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src/src/tools/tier-check/Cargo.toml 
/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src/src/doc/rustc/src/platform-support.md /home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src/build/x86_64-oe-linux-gnu/stage2/bin/rustc 
[workdir=/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src] failed with exit code 101 

Created at: src/bootstrap/src/core/build_steps/tool.rs:191:21 
Executed at: src/bootstrap/src/core/build_steps/test.rs:3436:55
Bootstrap configuration (bootstrap.toml)
change-id = 116881

[target.x86-64-oe-linux-gnu]
llvm-config = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/recipe-sysroot/usr/bin/llvm-config"
cxx = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/wrapper/target-rust-cxx"
cc = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/wrapper/target-rust-cc"
linker = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/wrapper/target-rust-ccld"

[target.x86_64-unknown-linux-gnu]
llvm-config = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/recipe-sysroot-native/usr/bin/llvm-config"
cxx = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/wrapper/build-rust-cxx"
cc = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/wrapper/build-rust-cc"
linker = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/wrapper/build-rust-ccld"

[llvm]
static-libstdcpp = false
download-ci-llvm = false

[rust]
rpath = true
remap-debuginfo = true
download-rustc = false
llvm-tools = false
lld = false
use-lld = false
channel = "stable"
optimize = true
verbose-tests = true

[build]
submodules = false
docs = false
rustc = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/recipe-sysroot-native/usr/bin/rustc"
cargo = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/recipe-sysroot-native/usr/bin/cargo"
extended = false
vendor = true
target = ["x86-64-oe-linux-gnu"]
host = ["x86-64-oe-linux-gnu"]
build = "x86_64-unknown-linux-gnu"

[install]
prefix = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/image/usr"
bindir = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/image/usr/bin"
libdir = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/image/usr/lib"
datadir = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/image/usr/share"
mandir = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/image/usr/share/man"
sysconfdir = "/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/image/etc"
HEAD

Rust v1.91.1
ed61e7d7e242494fb7057f2657300d9e77bb4fcb

Building bootstrap Compiling proc-macro2 v1.0.89 Compiling memchr v2.7.4 Compiling unicode-ident v1.0.13 Compiling typenum v1.17.0 . . . Skipping Suite(test::tests/run-make) because it is excluded Building stage1 run_make_support (stage0 -> stage1, x86_64-unknown-linux-gnu) . . Building stage2 cargo (stage1 -> stage2, x86_64-unknown-linux-gnu) Compiling rusqlite v0.37.0 Finished `release` profile [optimized] target(s) in 3m 48s Testing stage2 with compiletest suite=run-make-cargo mode=run-make (x86_64-oe-linux-gnu)

running 0 tests

test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 8 filtered out; finished in 15.90µs

1 command(s) did not execute successfully:

  • Command /home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/recipe-sysroot-native/usr/bin/cargo run --target x86_64-unknown-linux-gnu -Zbinary-dep-depinfo -j 192 -Zroot-dir=/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src --frozen --release --manifest-path /home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src/src/tools/tier-check/Cargo.toml /home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src/src/doc/rustc/src/platform-support.md /home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src/build/x86_64-oe-linux-gnu/stage2/bin/rustc [workdir=/home/user/rust91/openembedded-core/build-st/tmp/work/x86-64-v3-oe-linux/rust/1.91.1/sources/rustc-1.91.1-src] failed with exit code 101
    Created at: src/bootstrap/src/core/build_steps/tool.rs:191:21
    Executed at: src/bootstrap/src/core/build_steps/test.rs:3436:55

Build completed unsuccessfully in 0:35:08

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the bootstrap test using the provided command and configuration, focusing on the cargo run invocation for src/tools/tier-check/Cargo.toml. Read src/bootstrap/src/core/build_steps/tool.rs around line 191 and src/bootstrap/src/core/build_steps/test.rs around line 3436, then compare the tier-check inputs in platform-support.md. Done means the tier-check step completes successfully for the custom target.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
build-system, compilers
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.