-
Notifications
You must be signed in to change notification settings - Fork 13.3k
/
Copy pathrmake.rs
36 lines (29 loc) · 856 Bytes
/
rmake.rs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// Test that if we build `b` against a version of `a` that has
// one set of types, it will not run with a dylib that has a different set of types.
//@ ignore-cross-compile
// Reason: the compiled binary is executed
use run_make_support::{run, run_fail, rustc};
fn main() {
rustc()
.input("a.rs")
.cfg("x")
.arg("-Zunstable-options")
.arg("-Cprefer-dynamic")
.arg("-Csymbol-mangling-version=legacy")
.run();
rustc()
.input("b.rs")
.arg("-Zunstable-options")
.arg("-Cprefer-dynamic")
.arg("-Csymbol-mangling-version=legacy")
.run();
run("b");
rustc()
.input("a.rs")
.cfg("y")
.arg("-Zunstable-options")
.arg("-Cprefer-dynamic")
.arg("-Csymbol-mangling-version=legacy")
.run();
run_fail("b");
}