Skip to content
This repository has been archived by the owner on Nov 8, 2023. It is now read-only.

Commit

Permalink
Merge "Add include_dirs to all libraries" into main
Browse files Browse the repository at this point in the history
  • Loading branch information
Manish Goregaokar authored and Gerrit Code Review committed Jan 31, 2025
2 parents a1f3aff + 0ec10ed commit 25c54fc
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
5 changes: 0 additions & 5 deletions tools/cargo_embargo/src/cargo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,6 @@ impl CrateType {
pub fn is_test(self) -> bool {
matches!(self, Self::Test | Self::TestNoHarness)
}

/// Returns whether the crate type is a kind of C ABI library.
pub fn is_c_library(self) -> bool {
matches!(self, Self::CDyLib | Self::StaticLib)
}
}

/// Info extracted from `CargoOut` for a crate.
Expand Down
2 changes: 1 addition & 1 deletion tools/cargo_embargo/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1114,7 +1114,7 @@ fn crate_to_bp_modules(
if !crate_type.is_test() && package_cfg.host_supported && package_cfg.host_first_multilib {
m.props.set("compile_multilib", "first");
}
if crate_type.is_c_library() {
if crate_type.is_library() {
m.props.set_if_nonempty("include_dirs", package_cfg.exported_c_header_dir.clone());
}

Expand Down

0 comments on commit 25c54fc

Please sign in to comment.