Skip to content

Commit c92520a

Browse files
committed
Workaround bug in the linker-warning test
It incorrectly replaces rustc_codegen_cranelift in paths with rustc. It also doesn't handle panic=abort correctly.
1 parent 0376470 commit c92520a

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

scripts/test_rustc_tests.sh

+14
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,20 @@ index e7ae773ffa1d3..04bc2d7787da7 100644
195195
// Provide necessary library search paths for rustc.
196196
.env(dylib_env_var(), &env::join_paths(host_dylib_search_paths).unwrap());
197197
198+
diff --git a/tests/run-make/linker-warning/rmake.rs b/tests/run-make/linker-warning/rmake.rs
199+
index 30387af428c..f7895b12961 100644
200+
--- a/tests/run-make/linker-warning/rmake.rs
201+
+++ b/tests/run-make/linker-warning/rmake.rs
202+
@@ -57,7 +57,8 @@ fn main() {
203+
.actual_text("(linker error)", out.stderr())
204+
- .normalize(r#"/rustc[^/]*/"#, "/rustc/")
205+
+ .normalize(r#"/tmp/rustc[^/]*/"#, "/tmp/rustc/")
206+
+ .normalize("libpanic_abort", "libpanic_unwind")
207+
.normalize(
208+
regex::escape(run_make_support::build_root().to_str().unwrap()),
209+
"/build-root",
210+
)
211+
.run();
198212
EOF
199213

200214
echo "[TEST] rustc test suite"

0 commit comments

Comments
 (0)