Skip to content

Commit d1e8c6b

Browse files
committed
rewrite extern-overrides-distribution to rmake
1 parent dff354e commit d1e8c6b

File tree

3 files changed

+14
-7
lines changed

3 files changed

+14
-7
lines changed

src/tools/tidy/src/allowed_run_make_makefiles.txt

-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ run-make/extern-fn-with-packed-struct/Makefile
4949
run-make/extern-fn-with-union/Makefile
5050
run-make/extern-multiple-copies/Makefile
5151
run-make/extern-multiple-copies2/Makefile
52-
run-make/extern-overrides-distribution/Makefile
5352
run-make/extra-filename-with-temp-outputs/Makefile
5453
run-make/fmt-write-bloat/Makefile
5554
run-make/forced-unwind-terminate-pof/Makefile

tests/run-make/extern-overrides-distribution/Makefile

-6
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
// The --extern flag should override any "crate_type" declarations in the
2+
// Rust files themselves. In this test, libc is compiled as "lib", but
3+
// main.rs will only run with an rlib, which checks if the --extern flag
4+
// is successfully overriding the default behaviour.
5+
// See https://github.com/rust-lang/rust/pull/21782
6+
7+
//@ ignore-cross-compile
8+
9+
use run_make_support::{rust_lib_name, rustc};
10+
11+
fn main() {
12+
rustc().input("libc.rs").metadata("foo").run();
13+
rustc().input("main.rs").extern_("libc", rust_lib_name("libc")).run();
14+
}

0 commit comments

Comments
 (0)