|
|
|
@ -17,6 +17,18 @@ fn main() {
|
|
|
|
|
|
|
|
|
|
let manifest_dir = var("CARGO_MANIFEST_DIR").unwrap();
|
|
|
|
|
|
|
|
|
|
if target.contains("msvc") {
|
|
|
|
|
println!("cargo:rustc-link-search={}/deps/zstd/build/VS2010/bin/x64_Release", manifest_dir);
|
|
|
|
|
println!("cargo:rustc-link-search={}/deps/lz4/build/VS2017/bin/x64_Release", manifest_dir);
|
|
|
|
|
println!("cargo:rustc-link-search={}/deps/rocksdb/cmake_build/Release", manifest_dir);
|
|
|
|
|
println!("cargo:rustc-link-search={}/deps/gflags/cmake_build/lib/Release", manifest_dir);
|
|
|
|
|
println!("cargo:rustc-link-lib=static=rocksdb");
|
|
|
|
|
println!("cargo:rustc-link-lib=static=gflags_static");
|
|
|
|
|
println!("cargo:rustc-link-lib=libzstd");
|
|
|
|
|
println!("cargo:rustc-link-lib=static=liblz4_static");
|
|
|
|
|
println!("cargo:rustc-link-lib=rpcrt4");
|
|
|
|
|
println!("cargo:rustc-link-lib=shlwapi");
|
|
|
|
|
} else {
|
|
|
|
|
println!("cargo:rustc-link-search={}/deps/rocksdb/cmake_build/", manifest_dir);
|
|
|
|
|
println!("cargo:rustc-link-search={}/deps/zstd/lib/", manifest_dir);
|
|
|
|
|
println!("cargo:rustc-link-search={}/deps/lz4/lib/", manifest_dir);
|
|
|
|
@ -25,16 +37,9 @@ fn main() {
|
|
|
|
|
println!("cargo:rustc-link-lib=static=rocksdb");
|
|
|
|
|
println!("cargo:rustc-link-lib=static=lz4");
|
|
|
|
|
println!("cargo:rustc-link-lib=static=jemalloc");
|
|
|
|
|
// println!("cargo:rustc-link-lib=z");
|
|
|
|
|
//
|
|
|
|
|
// if target.contains("msvc") {
|
|
|
|
|
// println!("cargo:rustc-link-lib=rpcrt4");
|
|
|
|
|
// println!("cargo:rustc-link-lib=shlwapi");
|
|
|
|
|
// } else if target.contains("darwin") {
|
|
|
|
|
// println!("cargo:rustc-link-lib=bz2");
|
|
|
|
|
// }
|
|
|
|
|
//
|
|
|
|
|
// println!("cargo:rustc-link-lib=snappy");
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
println!("cargo:rerun-if-changed=src/bridge/mod.rs");
|
|
|
|
|
println!("cargo:rerun-if-changed=bridge/bridge.h");
|
|
|
|
|
println!("cargo:rerun-if-changed=bridge/common.h");
|
|
|
|
|