os/kernel/build.rs
2024-07-09 08:05:07 +02:00

14 lines
468 B
Rust

use bindgen::Builder;
fn main() {
println!("cargo::rustc-link-search=../lib/acpica-build");
println!("cargo::rustc-link-lib=acpica");
let bindings = Builder::default()
.use_core()
.clang_arg("-I../lib/acpica-build")
.header("../lib/acpica-build/acpica.h")
.parse_callbacks(Box::new(bindgen::CargoCallbacks::new()))
.generate()
.unwrap();
bindings.write_to_file("src/sys/acpica-bindings.rs").unwrap();
}