diff options
| author | bors <bors@rust-lang.org> | 2023-04-20 13:03:31 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2023-04-20 13:03:31 +0000 |
| commit | 791a7f22e3360bdbbc7fb7dab9f80e19fca4dd2b (patch) | |
| tree | 3369694af592591fad925f1c39c7aec01dbd7aa7 /src/tools | |
| parent | 7e23d180c1db42941b3bd32542a899e9eee7cbcb (diff) | |
| parent | 56d08d1bcddcba8e3fbdbb0231b992a328ee62b3 (diff) | |
| download | rust-791a7f22e3360bdbbc7fb7dab9f80e19fca4dd2b.tar.gz rust-791a7f22e3360bdbbc7fb7dab9f80e19fca4dd2b.zip | |
Auto merge of #110598 - matthiaskrgr:rollup-0ybd9i3, r=matthiaskrgr
Rollup of 5 pull requests
Successful merges:
- #110240 (Add `indent_style = tab` for `Makefile`s to `.editorconfig`)
- #110545 (Add `GenericArgKind::as_{type,const,region}`)
- #110574 ( fix out-of-date comment about rpath in bootstrap)
- #110581 (Style fix for loongarch-linux.md)
- #110584 (Allow overwriting the sysroot compile flag in compile tests)
Failed merges:
r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'src/tools')
| -rw-r--r-- | src/tools/compiletest/src/runtest.rs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs index 1a4e9b58383..0c17ae79808 100644 --- a/src/tools/compiletest/src/runtest.rs +++ b/src/tools/compiletest/src/runtest.rs @@ -1900,8 +1900,11 @@ impl<'test> TestCx<'test> { // Use a single thread for efficiency and a deterministic error message order rustc.arg("-Zthreads=1"); - // In stage 0, make sure we use `stage0-sysroot` instead of the bootstrap sysroot. - rustc.arg("--sysroot").arg(&self.config.sysroot_base); + // Optionally prevent default --sysroot if specified in test compile-flags. + if !self.props.compile_flags.iter().any(|flag| flag.starts_with("--sysroot")) { + // In stage 0, make sure we use `stage0-sysroot` instead of the bootstrap sysroot. + rustc.arg("--sysroot").arg(&self.config.sysroot_base); + } // Optionally prevent default --target if specified in test compile-flags. let custom_target = self.props.compile_flags.iter().any(|x| x.starts_with("--target")); |
