valgrind: make ptest depend on all components
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 4 lines · Randy MacLeod via lists.openembedded.org
From: Randy MacLeod<[email protected]>
When the helper scripts were split into separate packages, they weren't added as ptest dependencies. Fix that.
Well, this is embarrassing...
I'm no longer convinced that this is required.
I think I saw the ../cg_diff errors below:
PASS: memcheck/tests/vcpu_fbench
PASS: memcheck/tests/wcs
PASS: memcheck/tests/wcsncpy
PASS: memcheck/tests/wmemcmp
FAIL: memcheck/tests/wrap1
FAIL: memcheck/tests/wrap2
FAIL: memcheck/tests/wrap3
FAIL: memcheck/tests/wrap4
FAIL: memcheck/tests/wrap5
FAIL: memcheck/tests/wrap6
FAIL: memcheck/tests/wrap7
FAIL: memcheck/tests/wrap8
PASS: memcheck/tests/wrapmalloc
PASS: memcheck/tests/wrapmallocstatic
PASS: memcheck/tests/writev1
PASS: memcheck/tests/xml1
python3: can't open file '/usr/lib/valgrind/ptest/cachegrind/tests/../cg_diff': [Errno 2] No such file or directory
post check failed: python3 ../cg_diff --mod-funcname="s/main/MAIN/" ann1.cgout ann1b.cgout > ann-diff1.cgout && python3 ../cg_annotate --mod-filename="s/a.c/A.c/" --mod-funcname s/MAIN/Main/
PASS: cachegrind/tests/ann-diff1
python3: can't open file '/usr/lib/valgrind/ptest/cachegrind/tests/../cg_diff': [Errno 2] No such file or directory
post check failed: python3 ../cg_diff --mod-filename="s/.*aux\//aux\//i" --mod-funcname="s/(f[a-z]*)[0-9]/\1N/g" ann-diff2a.cgout ann-diff2b.cgout > ann-diff2c.cgout && python3 ../cg_annotat
PASS: cachegrind/tests/ann-diff2
and made an assumption that may not be valid. I think this problem is still present even after this change.
As I said previously, I may not have time to get back to this until next week so if anyone picks up this work, they might want to confirm that this is really required.
I should have just waited until I had time to complete the update before spamming the list.
../Randy
../Randy
Quoted 30 lines
Signed-off-by Randy MacLeod<[email protected]>--- meta/recipes-devtools/valgrind/valgrind_3.21.0.bb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)meta/recipes-devtools/valgrind/valgrind_3.21.0.bb +3
-2@@ -139,7 +139,9 @@ RDEPENDS:${PN}-ptest += " bash coreutils curl file \ perl-module-overloading perl-module-cwd perl-module-ipc-open3 \ perl-module-carp perl-module-symbol \ procps sed ${PN}-dbg ${PN}-src ${TCLIBC}-src gcc-runtime-dbg \ - util-linux-taskset" + util-linux-taskset \ + ${PN}-cachegrind ${PN}-massif ${PN}-callgrind \ +" RDEPENDS:${PN}-ptest:append:libc-glibc = " glibc-utils glibc-gconv-utf-32" # One of the tests contains a bogus interpreter path on purpose. -=-=-=-=-=-=-=-=-=-=-=-Links: You receive all messages sent to this group.
View/Reply Online (#190367):https://lists.openembedded.org/g/openembedded-core/message/190367 Mute This Topic:https://lists.openembedded.org/mt/102477896/3616765
Group Owner:[email protected] Unsubscribe:https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-
Signature · 2 lines
# Randy MacLeod # Wind River Linux
Quoted 4 lines · Randy MacLeod
As I said previously, I may not have time to get back to this until next week so if anyone picks up this work, they might want to confirm that this is really required.
I should have just waited until I had time to complete the update before spamming the list.
Thanks Randy, I hope you find time to complete this, as I'm planning to work on other updates. We're falling behind all over the place, as seen in the latest AUH report. Rust would be nice to do too.
Alex
Quoted 7 lines · Alexander Kanavin
Quoted 4 lines · Randy MacLeod
As I said previously, I may not have time to get back to this until next week so if anyone picks up this work, they might want to confirm that this is really required.
I should have just waited until I had time to complete the update before spamming the list.
Thanks Randy, I hope you find time to complete this, as I'm planning to work on other updates.
Yes, I will get to it but I have some things happening outside of work that will make this take longer than usual. I did make a bit more progress on fixing the ptest regressions.
Quoted 2 lines
We're falling behind all over the place, as
seen in the latest AUH report. Rust would be nice to do too.
Indeed.
Yash and Sundeep have 1.72/1.73 updated and are working on
getting the test suite to work but struggling with that. I asked him to track what's happening in:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=15275
../Randy
Quoted 2 lines
Alex
Signature · 2 lines
# Randy MacLeod # Wind River Linux
Quoted 3 lines · Randy MacLeod via lists.openembedded.org
On 2023-11-15 9:48 a.m., Alexander Kanavin wrote:
...
Quoted 10 lines
Rust would be nice to do too.
Indeed.
Yash and Sundeep have 1.72/1.73 updated and are working on
getting the test suite to work but struggling with that. I asked him to track what's happening in:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=15275
I did start looking at this... mostly I've failed to find enough time to even get to the point where I've got a useful environment for running the tests outside of bitbake (and hence avoid a complete rust build cycle).
Rust 1.74.0 landed yesterday, so I'm going to have another look... if it's useful to anyone my (very much WIP) tree is here:
https://github.com/akiernan/poky
--
Alex Kiernan
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 24 lines · Alex Kiernan via lists.openembedded.org
Quoted 3 lines · Randy MacLeod via lists.openembedded.org
On 2023-11-15 9:48 a.m., Alexander Kanavin wrote:
...
Quoted 10 lines
Rust would be nice to do too.
Indeed.
Yash and Sundeep have 1.72/1.73 updated and are working on
getting the test suite to work but struggling with that. I asked him to track what's happening in:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=15275I did start looking at this... mostly I've failed to find enough time to even get to the point where I've got a useful environment for running the tests outside of bitbake (and hence avoid a complete rust build cycle).
Quoted 5 lines
Rust 1.74.0 landed yesterday, so I'm going to have another look... if it's useful to anyone my (very much WIP) tree is here:
I've finally got this running in a way I can usefully inspect and try things and it's beginning to feel like we've headed into something which simply isn't supported.
The failure is this:
thread 'main' panicked at src/tools/compiletest/src/common.rs:519:30:
no entry found for key
Which is empty because the mapping list is collected by running rustc with -Z unstable-options --print=all-target-specs-json, but that fails because we're not running a nightly compiler:
error: the option Z is only accepted on the nightly compiler
help: consider switching to a nightly toolchain: rustup default nightly
note: selecting a toolchain with +toolchain arguments require a
rustup proxy; see
<https://rust-lang.github.io/rustup/concepts/index.html>
note: for more information about Rust's stability policy, see
<https://doc.rust-lang.org/book/appendix-07-nightly-rust.html#unstable-features>
Basically feels like running the test suite is only supported on the nightlies...
This is the full piece of useful logs for reference:
Testing stage1 compiletest suite=run-coverage mode=run-coverage (aarch64-unknown-linux-gnu -> aarch64-poky-linux-gnu)
thread 'main' panicked at src/tools/compiletest/src/common.rs:519:30:
no entry found for key
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace Note that not all variants of mir-opt tests are going to be blessed, as no mapping between
a 32bit and a 64bit target was found for aarch64-poky-linux-gnu. You can add that mapping by changing MIR_OPT_BLESS_TARGET_MAPPING in src/bootstrap/test.rs
Testing stage1 compiletest suite=mir-opt mode=mir-opt (aarch64-unknown-linux-gnu -> aarch64-poky-linux-gnu)
thread 'main' panicked at src/tools/compiletest/src/common.rs:519:30:
no entry found for key
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
error: the option Z is only accepted on the nightly compiler
help: consider switching to a nightly toolchain: rustup default nightly
note: selecting a toolchain with +toolchain arguments require a rustup proxy; see
<https://rust-lang.github.io/rustup/concepts/index.html>
note: for more information about Rust's stability policy, see
<https://doc.rust-lang.org/book/appendix-07-nightly-rust.html#unstable-features>
error: 1 nightly option were parsed
thread 'main' panicked at synthetic_targets.rs:66:9:
failed to gather the target spec for aarch64-poky-linux-gnu
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
Signature · 1 line
Alex Kiernan
Quoted 24 lines · Alex Kiernan
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.I've finally got this running in a way I can usefully inspect and try things and it's beginning to feel like we've headed into something which simply isn't supported.
The failure is this:
thread 'main' panicked at
src/tools/compiletest/src/common.rs:519:30:
no entry found for keyWhich is empty because the mapping list is collected by running rustc with -Z unstable-options --print=all-target-specs-json, but that fails because we're not running a nightly compiler:
error: the option
Zis only accepted on the nightly compiler
help: consider switching to a nightly toolchain:rustup default nightly
note: selecting a toolchain with+toolchainarguments require a
rustup proxy; see
<https://rust-lang.github.io/rustup/concepts/index.html>
note: for more information about Rust's stability policy, see
<https://doc.rust-lang.org/book/appendix-07-nightly-rust.html#unstable-features>
Quoted 2 lines
Basically feels like running the test suite is only supported on the nightlies...
I saw the same error earlier.
Investigating further, we understood that the issue is not related to running on nightly channel. The '-Z unstable options' were also present in earlier rust versions and removing of the newly added -Z options after 1.70 also didn't solve the problem.
On doing further analysis, we found that the custom target config/specs were not fetched during the rust build.
The log for reference is as follows:
Building stage1 library artifacts (x86_64-unknown-linux-gnu -> x86_64-poky-linux-gnu)
error: failed to run rustc to learn about target-specific information
Caused by:
process didn't exit successfully: ` build-st/tmp/work/core2-64-poky-linux/rust/1.72.0/rustc-1.72.0-src/build/bootstrap/debug/rustc - --crate-name ___ --print=file-names -Csymbol-mangling-version=legacy -Zunstable-options -Zunstable-options '--check-cfg=values(bootstrap)' '--check-cfg=values(stdarch_intel_sde)' '--check-cfg=values(no_fp_fmt_parse)' '--check-cfg=values(no_global_oom_handling)' '--check-cfg=values(no_rc)' '--check-cfg=values(no_sync)' '--check-cfg=values(freebsd12)' '--check-cfg=values(freebsd13)' '--check-cfg=values(backtrace_in_libstd)' '--check-cfg=values(target_env,"libnx")' '--check-cfg=values(target_arch,"asmjs","spirv","nvptx","xtensa")' -Zmacro-backtrace -Clink-args=-Wl,-z,origin '-Clink-args=-Wl,-rpath,$ORIGIN/../lib' -Csplit-debuginfo=off -Cprefer-dynamic -Zinline-mir -Cembed-bitcode=yes '-Zcrate-attr=doc(html_root_url="https://doc.rust-lang.org/1.72.0/")' --target x86_64-poky-linux-gnu --crate-type bin --crate-type rlib --crate-type dylib --crate-type cdylib --crate-type staticlib --crate-type proc-macro --print=sysroot --print=split-debuginfo --print=crate-name --print=cfg` (exit status: 1) --- stderr
error: Error loading target specification: Could not find specification for target "x86_64-poky-linux-gnu". Run rustc --print target-list for a list of built-in targets
Build completed unsuccessfully in 0:04:38
Regards,
Yash.
Quoted 36 lines
This is the full piece of useful logs for reference:
Testing stage1 compiletest suite=run-coverage mode=run-coverage (aarch64-unknown-linux-gnu -> aarch64-poky-linux-gnu)
thread 'main' panicked atsrc/tools/compiletest/src/common.rs:519:30:
no entry found for key
note: run withRUST_BACKTRACE=1environment variable to display a backtrace Note that not all variants of mir-opt tests are going to be blessed, as no mapping between
a 32bit and a 64bit target was found for aarch64-poky-linux-gnu. You can add that mapping by changingMIR_OPT_BLESS_TARGET_MAPPINGinsrc/bootstrap/test.rs
Testing stage1 compiletest suite=mir-opt mode=mir-opt (aarch64-unknown-linux-gnu -> aarch64-poky-linux-gnu)
thread 'main' panicked atsrc/tools/compiletest/src/common.rs:519:30:
no entry found for key
note: run withRUST_BACKTRACE=1environment variable to display a backtrace
error: the optionZis only accepted on the nightly compilerhelp: consider switching to a nightly toolchain:
rustup default nightlynote: selecting a toolchain with
+toolchainarguments require a rustup proxy; see
<https://rust-lang.github.io/rustup/concepts/index.html>note: for more information about Rust's stability policy, see
<https://doc.rust-lang.org/book/appendix-07-nightly-rust.html#unstable-features>error: 1 nightly option were parsed
thread 'main' panicked at synthetic_targets.rs:66:9:
failed to gather the target spec for aarch64-poky-linux-gnu
note: run withRUST_BACKTRACE=1environment variable to display a backtrace--
Alex Kiernan
Quoted 27 lines · Yash Shinde
Quoted 24 lines · Alex Kiernan
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.I've finally got this running in a way I can usefully inspect and try things and it's beginning to feel like we've headed into something which simply isn't supported.
The failure is this:
thread 'main' panicked at
src/tools/compiletest/src/common.rs:519:30:
no entry found for keyWhich is empty because the mapping list is collected by running rustc with -Z unstable-options --print=all-target-specs-json, but that fails because we're not running a nightly compiler:
error: the option
Zis only accepted on the nightly compiler
help: consider switching to a nightly toolchain:rustup default nightly
note: selecting a toolchain with+toolchainarguments require a
rustup proxy; see
<https://rust-lang.github.io/rustup/concepts/index.html>
note: for more information about Rust's stability policy, see
<https://doc.rust-lang.org/book/appendix-07-nightly-rust.html#unstable-features>
Quoted 9 lines
Quoted 2 lines
Basically feels like running the test suite is only supported on the nightlies...
I saw the same error earlier.
Investigating further, we understood that the issue is not related to running on nightly channel. The '-Z unstable options' were also present in earlier rust versions and removing of the newly added -Z options after 1.70 also didn't solve the problem.
There's a fair number of changes in the test framework around the code that calls out to rustc with new paths that use --print=all-target-specs-json unconditionally. Assuming I've read it right, -Zunstable-options is only evaluated at the point where you actually try and use such an option which is covered by unstable-options, so just passing it in doesn't get you a failure.
Quoted 26 lines
On doing further analysis, we found that the custom target config/specs were not fetched during the rust build.
The log for reference is as follows:
Building stage1 library artifacts (x86_64-unknown-linux-gnu -> x86_64-poky-linux-gnu)
error: failed to runrustcto learn about target-specific informationCaused by:
process didn't exit successfully: `
build-st/tmp/work/core2-64-poky-linux/rust/1.72.0/rustc-1.72.0-src/build/bootstrap/debug/rustc
- --crate-name ___ --print=file-names -Csymbol-mangling-version=legacy -Zunstable-options -Zunstable-options '--check-cfg=values(bootstrap)' '--check-cfg=values(stdarch_intel_sde)'
'--check-cfg=values(no_fp_fmt_parse)' '--check-cfg=values(no_global_oom_handling)' '--check-cfg=values(no_rc)' '--check-cfg=values(no_sync)' '--check-cfg=values(freebsd12)' '--check-cfg=values(freebsd13)'
'--check-cfg=values(backtrace_in_libstd)' '--check-cfg=values(target_env,"libnx")' '--check-cfg=values(target_arch,"asmjs","spirv","nvptx","xtensa")' -Zmacro-backtrace -Clink-args=-Wl,-z,origin '-Clink-args=-Wl,-rpath,$ORIGIN/../lib' -Csplit-debuginfo=off
-Cprefer-dynamic -Zinline-mir -Cembed-bitcode=yes '-Zcrate-attr=doc(html_root_url="https://doc.rust-lang.org/1.72.0/")'
Quoted 9 lines
--target x86_64-poky-linux-gnu --crate-type bin --crate-type rlib --crate-type dylib --crate-type cdylib --crate-type staticlib --crate-type proc-macro --print=sysroot --print=split-debuginfo --print=crate-name --print=cfg` (exit status: 1)
--- stderr
error: Error loading target specification: Could not find
specification for target "x86_64-poky-linux-gnu". Runrustc --print target-listfor a list of built-in targets
Out of interest, did you try 1.71.0 to see if that failed? Based on reading the commit log for src/tools/compiletest/src/common.rs, I suspect it will fail.
Signature · 1 line
Alex Kiernan
Quoted 76 lines · Alex Kiernan
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.Quoted 26 lines · Yash Shinde
Quoted 24 lines · Alex Kiernan
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.I've finally got this running in a way I can usefully inspect and try things and it's beginning to feel like we've headed into something which simply isn't supported.
The failure is this:
thread 'main' panicked at
src/tools/compiletest/src/common.rs:519:30:
no entry found for keyWhich is empty because the mapping list is collected by running rustc with -Z unstable-options --print=all-target-specs-json, but that fails because we're not running a nightly compiler:
error: the option
Zis only accepted on the nightly compiler
help: consider switching to a nightly toolchain:rustup default nightly
note: selecting a toolchain with+toolchainarguments require a
rustup proxy; see
<https://rust-lang.github.io/rustup/concepts/index.html>
note: for more information about Rust's stability policy, see
<https://doc.rust-lang.org/book/appendix-07-nightly-rust.html#unstable-features>Quoted 9 lines
Quoted 2 lines
Basically feels like running the test suite is only supported on the nightlies...
I saw the same error earlier.
Investigating further, we understood that the issue is not related to running on nightly channel. The '-Z unstable options' were also present in earlier rust versions and removing of the newly added -Z options after 1.70 also didn't solve the problem.
There's a fair number of changes in the test framework around the code that calls out to rustc with new paths that use --print=all-target-specs-json unconditionally. Assuming I've read it right, -Zunstable-options is only evaluated at the point where you actually try and use such an option which is covered by unstable-options, so just passing it in doesn't get you a failure.
Quoted 30 lines
On doing further analysis, we found that the custom target config/specs were not fetched during the rust build.
The log for reference is as follows:
Building stage1 library artifacts (x86_64-unknown-linux-gnu -> x86_64-poky-linux-gnu)
error: failed to runrustcto learn about target-specific informationCaused by:
process didn't exit successfully: `
build-st/tmp/work/core2-64-poky-linux/rust/1.72.0/rustc-1.72.0-src/build/bootstrap/debug/rustc
- --crate-name ___ --print=file-names -Csymbol-mangling-version=legacy -Zunstable-options -Zunstable-options '--check-cfg=values(bootstrap)' '--check-cfg=values(stdarch_intel_sde)'
'--check-cfg=values(no_fp_fmt_parse)' '--check-cfg=values(no_global_oom_handling)' '--check-cfg=values(no_rc)' '--check-cfg=values(no_sync)' '--check-cfg=values(freebsd12)' '--check-cfg=values(freebsd13)'
'--check-cfg=values(backtrace_in_libstd)' '--check-cfg=values(target_env,"libnx")' '--check-cfg=values(target_arch,"asmjs","spirv","nvptx","xtensa")' -Zmacro-backtrace -Clink-args=-Wl,-z,origin '-Clink-args=-Wl,-rpath,$ORIGIN/../lib' -Csplit-debuginfo=off
-Cprefer-dynamic -Zinline-mir -Cembed-bitcode=yes '-Zcrate-attr=doc(html_root_url="https://doc.rust-lang.org/1.72.0/")'
--target x86_64-poky-linux-gnu --crate-type bin --crate-type rlib
--crate-type dylib --crate-type cdylib --crate-type staticlib
--crate-type proc-macro --print=sysroot --print=split-debuginfo --print=crate-name --print=cfg` (exit status: 1)
Quoted 9 lines
Quoted 5 lines
--- stderr
error: Error loading target specification: Could not find
specification for target "x86_64-poky-linux-gnu". Runrustc --print target-listfor a list of built-in targetsOut of interest, did you try 1.71.0 to see if that failed? Based on reading the commit log for
src/tools/compiletest/src/common.rs, I suspect it will fail.
Yes, that fails in 1.71.0 also. The 1.71 build progresses to check some test suites before failing as follows-
.........Test cases running from different suites like codegen, ui, mir-opt, assembly, incremental....
test [incremental] tests/incremental/issue-79661-missing-def-path-hash.rs ... ok test [incremental] tests/incremental/remapped_paths_cc/main.rs ... ok
test [incremental] tests/incremental/lto.rs ... ok
test result: ok. 161 passed; 0 failed; 2 ignored; 0 measured; 0 filtered out; finished in 12.51s finished in 13.102 seconds
Check compiletest suite=debuginfo mode=debuginfo (x86_64-unknown-linux-gnu -> x86_64-poky-linux-gnu)
WARNING: debuginfo tests are not available when testing with remote
running 0 tests
test result: ok. 0 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 18.92µs
finished in 0.147 seconds
Building stage0 library artifacts (x86_64-poky-linux-gnu)
error: process didn't exit successfully: build-st/tmp/work/core2-64-poky-linux/rust/1.71.0/rustc-1.71.0-src/build/bootstrap/debug/rustc -vV (exit status: 101)
--- stderr
thread 'main' panicked at '
Failed to run:
LD_LIBRARY_PATH="/build-st/tmp/work/core2-64-poky-linux/rust/1.71.0/rustc-1.71.0-src/build/x86_64-poky-linux-gnu/stage0-sysroot/lib" "build-st/tmp/work/core2-64-poky-linux/rust/1.71.0/rustc-1.71.0-src/build/x86_64-poky-linux-gnu/stage0-sysroot/bin/rustc" "-vV" "-Wrust_2018_idioms" "-Wunused_lifetimes" "-Wsemicolon_in_expressions_from_macros" "-Dwarnings" "-Clinker=build-st/tmp/work/core2-64-poky-linux/rust/1.71.0/wrapper/target-rust-ccld" "--cfg=bootstrap" "-Zunstable-options" "--check-cfg=values(bootstrap)" "-Z" "force-unstable-if-unmarked" -------------: Os { code: 2, kind: NotFound, message: "No such file or directory" }', bin/rustc.rs:230:37
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace
Build completed unsuccessfully in 0:06:09
Regards,
Yash
Quoted 2 lines
--
Alex Kiernan
Quoted 88 lines · Yash Shinde
Quoted 76 lines · Alex Kiernan
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.Quoted 26 lines · Yash Shinde
Quoted 24 lines · Alex Kiernan
CAUTION: This email comes from a non Wind River email account!
Do not click links or open attachments unless you recognize the sender and know the content is safe.I've finally got this running in a way I can usefully inspect and try things and it's beginning to feel like we've headed into something which simply isn't supported.
The failure is this:
thread 'main' panicked at
src/tools/compiletest/src/common.rs:519:30:
no entry found for keyWhich is empty because the mapping list is collected by running rustc with -Z unstable-options --print=all-target-specs-json, but that fails because we're not running a nightly compiler:
error: the option
Zis only accepted on the nightly compiler
help: consider switching to a nightly toolchain:rustup default nightly
note: selecting a toolchain with+toolchainarguments require a
rustup proxy; see
<https://rust-lang.github.io/rustup/concepts/index.html>
note: for more information about Rust's stability policy, see
<https://doc.rust-lang.org/book/appendix-07-nightly-rust.html#unstable-features>Quoted 9 lines
Quoted 2 lines
Basically feels like running the test suite is only supported on the nightlies...
I saw the same error earlier.
Investigating further, we understood that the issue is not related to running on nightly channel. The '-Z unstable options' were also present in earlier rust versions and removing of the newly added -Z options after 1.70 also didn't solve the problem.
There's a fair number of changes in the test framework around the code that calls out to rustc with new paths that use --print=all-target-specs-json unconditionally. Assuming I've read it right, -Zunstable-options is only evaluated at the point where you actually try and use such an option which is covered by unstable-options, so just passing it in doesn't get you a failure.
Quoted 30 lines
On doing further analysis, we found that the custom target config/specs were not fetched during the rust build.
The log for reference is as follows:
Building stage1 library artifacts (x86_64-unknown-linux-gnu -> x86_64-poky-linux-gnu)
error: failed to runrustcto learn about target-specific informationCaused by:
process didn't exit successfully: `
build-st/tmp/work/core2-64-poky-linux/rust/1.72.0/rustc-1.72.0-src/build/bootstrap/debug/rustc
- --crate-name ___ --print=file-names -Csymbol-mangling-version=legacy -Zunstable-options -Zunstable-options '--check-cfg=values(bootstrap)' '--check-cfg=values(stdarch_intel_sde)'
'--check-cfg=values(no_fp_fmt_parse)' '--check-cfg=values(no_global_oom_handling)' '--check-cfg=values(no_rc)' '--check-cfg=values(no_sync)' '--check-cfg=values(freebsd12)' '--check-cfg=values(freebsd13)'
'--check-cfg=values(backtrace_in_libstd)' '--check-cfg=values(target_env,"libnx")' '--check-cfg=values(target_arch,"asmjs","spirv","nvptx","xtensa")' -Zmacro-backtrace -Clink-args=-Wl,-z,origin '-Clink-args=-Wl,-rpath,$ORIGIN/../lib' -Csplit-debuginfo=off
-Cprefer-dynamic -Zinline-mir -Cembed-bitcode=yes '-Zcrate-attr=doc(html_root_url="https://doc.rust-lang.org/1.72.0/")'
--target x86_64-poky-linux-gnu --crate-type bin --crate-type rlib
--crate-type dylib --crate-type cdylib --crate-type staticlib
--crate-type proc-macro --print=sysroot --print=split-debuginfo --print=crate-name --print=cfg` (exit status: 1)Quoted 9 lines
Quoted 5 lines
--- stderr
error: Error loading target specification: Could not find
specification for target "x86_64-poky-linux-gnu". Runrustc --print target-listfor a list of built-in targetsOut of interest, did you try 1.71.0 to see if that failed? Based on reading the commit log for
src/tools/compiletest/src/common.rs, I suspect it will fail.
Quoted 3 lines
Yes, that fails in 1.71.0 also. The 1.71 build progresses to check some test suites before failing as follows-
I think this is where our problems start:
commit c075691b825dce55e4261aba570cd2d9665950c0
Author: Pietro Albini <[email protected]> Date: Thu Mar 9 17:14:25 2023 +0100
use --print=all-target-specs-json for stage1+
But there's a bunch of commits in 1.71.0 which build on that, but which aren't isolated to just that code, so I'm struggling to "revert" just that change to prove it.
If it's useful I brought up all the intermediate versions into my tree if it's useful (though I've only build tested 1.71.0 and 1.74.0).
Signature · 1 line
Alex Kiernan