loro/crates/loro-ffi/build.rs
2023-07-05 14:43:58 +08:00

8 lines
327 B
Rust

fn main() {
let crate_dir = std::env::var("CARGO_MANIFEST_DIR").unwrap();
let config = cbindgen::Config::from_file("cbindgen.toml")
.expect("Unable to find cbindgen.toml configuration file");
cbindgen::generate_with_config(crate_dir, config)
.unwrap()
.write_to_file("target/loro_ffi.h");
}