servicepoint/crates/servicepoint_binding_c/build.rs

14 lines
395 B
Rust
Raw Normal View History

use std::env;
use cbindgen::{generate_with_config, Config};
fn main() {
let crate_dir = env::var("CARGO_MANIFEST_DIR").unwrap();
let config = Config::from_file(crate_dir.clone() + "/cbindgen.toml").unwrap();
let servicepoint_dir = crate_dir.clone() + "/../servicepoint";
generate_with_config(servicepoint_dir, config)
.unwrap()
.write_to_file("servicepoint.h");
}