summaryrefslogtreecommitdiff
path: root/plugins/pdb-ng/demo/build.rs
blob: ed6cec7d276c927a2fba765ca51a03deaffcb162 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
fn main() {
    let link_path = std::env::var_os("DEP_BINARYNINJACORE_PATH")
        .expect("DEP_BINARYNINJACORE_PATH not specified");

    println!("cargo::rustc-link-lib=dylib=binaryninjacore");
    println!("cargo::rustc-link-search={}", link_path.to_str().unwrap());

    #[cfg(not(target_os = "windows"))]
    {
        println!(
            "cargo::rustc-link-arg=-Wl,-rpath,{0},-L{0}",
            link_path.to_string_lossy()
        );
    }
}