Closed
Description
After cloning, I expected python3 x.py test --stage 1 tests/ui
to succeed but instead I got many test failures like this one:
---- [ui] tests/ui/async-await/track-caller/panic-track-caller.rs#afn stdout ----
error in revision `afn`: test compilation failed although it shouldn't!
status: exit status: 1
command: env -u RUSTC_LOG_COLOR RUSTC_ICE="0" RUST_BACKTRACE="short" "/Users/wesley/Code/rust/build/aarch64-apple-darwin/stage1/bin/rustc" "/Users/wesley/Code/rust/tests/ui/async-await/track-caller/panic-track-caller.rs" "-Zthreads=1" "-Zsimulate-remapped-rust-src-base=/rustc/FAKE_PREFIX" "-Ztranslate-remapped-path-to-local-path=no" "-Z" "ignore-directory-in-diagnostics-source-blocks=/Users/wesley/.cargo" "-Z" "ignore-directory-in-diagnostics-source-blocks=/Users/wesley/Code/rust/vendor" "--sysroot" "/Users/wesley/Code/rust/build/aarch64-apple-darwin/stage1" "--target=aarch64-apple-darwin" "--cfg" "afn" "--check-cfg" "cfg(FALSE,afn,cls,nofeat)" "-O" "--error-format" "json" "--json" "future-incompat" "-Ccodegen-units=1" "-Zui-testing" "-Zdeduplicate-diagnostics=no" "-Zwrite-long-types-to-disk=no" "-Cstrip=debuginfo" "-C" "prefer-dynamic" "-o" "/Users/wesley/Code/rust/build/aarch64-apple-darwin/test/ui/async-await/track-caller/panic-track-caller.afn/a" "-A" "internal_features" "-Crpath" "-Cdebuginfo=0" "-Lnative=/Users/wesley/Code/rust/build/aarch64-apple-darwin/native/rust-test-helpers" "--edition=2021"
stdout: none
--- stderr -------------------------------
error: unable to run `rust-objcopy`: No such file or directory (os error 2)
error: aborting due to 1 previous error
------------------------------------------
However, if I create a config.toml
by cp config.example.toml config.toml
, then the problem goes away.
I instrumented the code here with a println!()
and I can see that when config.toml
exists, this block runs but when config.toml
does not exist, it does not run:
rust/src/bootstrap/src/core/build_steps/compile.rs
Lines 1980 to 1988 in b71fb5e
Possibly related to #132720 cc @jieyouxu
Meta
Cloned rust-lang/rust at b71fb5e
Host is aarch64-apple-darwin