Skip to content

Commit

Permalink
Merge pull request #16 from Sympatron/libosdp-sys-no_std
Browse files Browse the repository at this point in the history
Make libosdp-sys no_std compatible
  • Loading branch information
sidcha authored Oct 2, 2024
2 parents 246a910 + 6c52d9b commit 01c12c9
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
4 changes: 3 additions & 1 deletion libosdp-sys/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,13 @@ categories = ["development-tools", "embedded"]

[build-dependencies]
anyhow = "1.0.75"
bindgen = "0.69.1"
bindgen = "0.70.0"
build-target = "0.4.0"
cc = "1.0.83"

[features]
default = ["std"]
std = []
packet_trace = []
data_trace = []
skip_mark_byte = []
5 changes: 2 additions & 3 deletions libosdp-sys/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -166,10 +166,9 @@ fn main() -> Result<()> {

/* generate bindings */

let args = vec![
format!("-I{}", &out_dir),
];
let args = vec![format!("-I{}", &out_dir)];
let bindings = bindgen::Builder::default()
.use_core()
.header("vendor/include/osdp.h")
.clang_args(args)
.generate()
Expand Down
1 change: 1 addition & 0 deletions libosdp-sys/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#![cfg_attr(not(feature = "std"), no_std)]
//! Auto generated (bindgen) wrapper for LibOSDP C API exposed from osdp.h
//! [here](https://github.com/goToMain/libosdp/blob/master/include/osdp.h).

Expand Down

0 comments on commit 01c12c9

Please sign in to comment.