about summary refs log tree commit diff
path: root/tests/run-make/no-duplicate-libs/rmake.rs
blob: b67067909b24bb2a9ad1f438a7c7b729f34a078c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// The rust compiler used to try to detect duplicated libraries in
// the linking order and remove the duplicates... but certain edge cases,
// such as the one presented in `foo` and `bar` in this test, demand precise
// control over the link order, including duplicates. As the anti-duplication
// filter was removed, this test should now successfully see main be compiled
// and executed.
// See https://github.com/rust-lang/rust/pull/12688

//@ ignore-cross-compile
// Reason: the compiled binary is executed

use run_make_support::{build_native_static_lib, run, rustc};

fn main() {
    build_native_static_lib("foo");
    build_native_static_lib("bar");
    rustc().input("main.rs").run();
    run("main");
}