Skip to content

Commit 09385f9

Browse files
committed
use bare_rustc to keep host toolchain
Signed-off-by: Osama Abdelkader <osama.abdelkader@gmail.com>
1 parent 8075c98 commit 09385f9

File tree

1 file changed

+4
-3
lines changed
  • tests/run-make/rustdoc-test-builder

1 file changed

+4
-3
lines changed

tests/run-make/rustdoc-test-builder/rmake.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
//@ needs-target-std
77

8-
use run_make_support::{path, rfs, rustc, rustc_path, rustdoc};
8+
use run_make_support::{bare_rustc, path, rfs, rustc_path, rustdoc};
99

1010
fn main() {
1111
// Test 1: Verify that a non-executable test-builder fails gracefully
@@ -24,9 +24,10 @@ fn main() {
2424
output.assert_not_ice();
2525

2626
// Test 2: Verify that a valid test-builder is invoked with correct arguments
27-
// Build a custom test-builder that logs its arguments and forwards to rustc
27+
// Build a custom test-builder that logs its arguments and forwards to rustc.
28+
// Use `bare_rustc` so we compile for the host architecture even in cross builds.
2829
let builder_bin = path("builder-bin");
29-
rustc().input("builder.rs").output(&builder_bin).run();
30+
bare_rustc().input("builder.rs").output(&builder_bin).run();
3031

3132
let log_path = path("builder.log");
3233
let _ = std::fs::remove_file(&log_path);

0 commit comments

Comments
 (0)