Skip to content

Commit 72dff16

Browse files
committed
rewrite export-executable-symbols to rmake
1 parent 639b56c commit 72dff16

File tree

3 files changed

+18
-12
lines changed

3 files changed

+18
-12
lines changed

src/tools/tidy/src/allowed_run_make_makefiles.txt

-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ run-make/dep-info-spaces/Makefile
1313
run-make/dep-info/Makefile
1414
run-make/dump-ice-to-disk/Makefile
1515
run-make/emit-to-stdout/Makefile
16-
run-make/export-executable-symbols/Makefile
1716
run-make/extern-diff-internal-name/Makefile
1817
run-make/extern-flag-disambiguates/Makefile
1918
run-make/extern-fn-reachable/Makefile

tests/run-make/export-executable-symbols/Makefile

-11
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
// The unstable flag `-Z export-executable-symbols` exports symbols from executables, as if
2+
// they were dynamic libraries. This test is a simple smoke test to check that this feature
3+
// works by using it in compilation, then checking that the output binary contains the exported
4+
// symbol.
5+
// See https://github.com/rust-lang/rust/pull/85673
6+
7+
//@ ignore-wasm32
8+
//@ ignore-wasm64
9+
//@ ignore-none
10+
// Reason: no-std is not supported
11+
//FIXME(Oneirical): try it on more than only-linux
12+
13+
use run_make_support::{llvm_readobj, rustc};
14+
15+
fn main() {
16+
rustc().arg("-Zexport-executable-symbols").input("main.rs").crate_type("bin").run();
17+
llvm_readobj().symbols().input("main").run().assert_stdout_contains("exported_symbol");
18+
}

0 commit comments

Comments
 (0)