io_uring_header 0.1.3

linux kernel 6.1 include/uapi/linux/io_uring.h
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
fn main() {
    println!("cargo:rerun-if-changed=build.rs");

    let out_path = std::path::PathBuf::from(std::env::var("OUT_DIR").unwrap());

    bindgen::builder()
        .header("io_uring.h")
        .allowlist_file("io_uring.h")
        .use_core()
        .anon_fields_prefix("anon")
        .default_enum_style(bindgen::EnumVariation::ModuleConsts)
        .default_non_copy_union_style(bindgen::NonCopyUnionStyle::ManuallyDrop)
        .generate()
        .unwrap()
        .write_to_file(out_path.join("bindings.rs"))
        .unwrap();
}