Skip to content

Commit

Permalink
a
Browse files Browse the repository at this point in the history
  • Loading branch information
xmakro committed Jan 29, 2025
1 parent 5d7844a commit 64c46f8
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions ibverbs-sys/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@ use std::process::Command;

fn main() {
let manifest_dir = env::var("CARGO_MANIFEST_DIR").expect("failed to get current directory");
let out_path = PathBuf::from(env::var("OUT_DIR").unwrap());
println!("cargo:include={manifest_dir}/vendor/rdma-core/build/include");
println!(
"cargo:rustc-link-search=native={manifest_dir}/vendor/rdma-core/build/lib;{}",
out_path.to_str().unwrap()
);
println!("cargo:rustc-link-lib=ibverbs");

if Path::new("vendor/rdma-core/CMakeLists.txt").exists() {
Expand Down Expand Up @@ -83,6 +78,7 @@ fn main() {
.expect("Unable to generate bindings");

// write the bindings to the $OUT_DIR/bindings.rs file.
let out_path = PathBuf::from(env::var("OUT_DIR").unwrap());
bindings
.write_to_file(out_path.join("bindings.rs"))
.expect("Could not write bindings");
Expand Down

0 comments on commit 64c46f8

Please sign in to comment.