Skip to content

Commit

Permalink
libosdp-sys: Pull in __BARE_METAL__ target fix
Browse files Browse the repository at this point in the history
Signed-off-by: Siddharth Chandrasekaran <sidcha.dev@gmail.com>
  • Loading branch information
sidcha committed Nov 10, 2024
1 parent 6ffd7bc commit 6220a37
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions libosdp-sys/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,10 @@ fn main() -> Result<()> {
build = build.warnings_into_errors(true)
}

if Os::target().unwarap() == Os::Other {

Check failure on line 126 in libosdp-sys/build.rs

View workflow job for this annotation

GitHub Actions / test

no method named `unwarap` found for enum `std::result::Result` in the current scope

Check failure on line 126 in libosdp-sys/build.rs

View workflow job for this annotation

GitHub Actions / lint

no method named `unwarap` found for enum `std::result::Result` in the current scope
build = build.define("__BARE_METAL__", "1")
}

let source_files = vec![
"vendor/utils/src/list.c",
"vendor/utils/src/queue.c",
Expand Down Expand Up @@ -158,6 +162,7 @@ fn main() -> Result<()> {
if cfg!(feature = "data_trace") {
build = build
.define("CONFIG_OSDP_DATA_TRACE", "1")
.define("__BARE_METAL__", "1")
.file("vendor/utils/src/pcap_gen.c")
.file("vendor/src/osdp_pcap.c");
}
Expand Down

0 comments on commit 6220a37

Please sign in to comment.