Skip to content

Commit

Permalink
cargo_embargo: generate host variants
Browse files Browse the repository at this point in the history
  • Loading branch information
Gnurou committed Jul 12, 2024
1 parent 00cce08 commit e04dee8
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 7 deletions.
7 changes: 0 additions & 7 deletions cargo_embargo.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,7 @@
"module_blocklist": ["runbindgen", "runbindgen_test_src_main"],
"package": {
"v4l2r": {
"host_supported": false,
"dep_blocklist": ["libctrlc", "libclap"]
},
"v4l2r-ffi": {
"host_supported": false
},
"v4l2r-utils": {
"host_supported": false
}
},
"run_cargo": false,
Expand Down
6 changes: 6 additions & 0 deletions ffi/Android.bp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
// DO NOT SUBMIT: Add license before submitting.
rust_library {
name: "libv4l2r_ffi",
host_supported: true,
crate_name: "v4l2r_ffi",
cargo_env_compat: true,
cargo_pkg_version: "0.0.1",
Expand Down Expand Up @@ -33,6 +34,7 @@ rust_library {

rust_ffi_static {
name: "libv4l2r_ffi_static",
host_supported: true,
crate_name: "v4l2r_ffi",
cargo_env_compat: true,
cargo_pkg_version: "0.0.1",
Expand Down Expand Up @@ -60,12 +62,16 @@ rust_ffi_static {

rust_test {
name: "v4l2r-ffi_test_src_lib",
host_supported: true,
crate_name: "v4l2r_ffi",
cargo_env_compat: true,
cargo_pkg_version: "0.0.1",
crate_root: "src/lib.rs",
test_suites: ["general-tests"],
auto_gen_config: true,
test_options: {
unit_test: true,
},
edition: "2021",
features: [
"default",
Expand Down
5 changes: 5 additions & 0 deletions lib/Android.bp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
// DO NOT SUBMIT: Add license before submitting.
rust_library {
name: "libv4l2r",
host_supported: true,
crate_name: "v4l2r",
cargo_env_compat: true,
cargo_pkg_version: "0.0.2",
Expand All @@ -29,12 +30,16 @@ rust_library {

rust_test {
name: "v4l2r_test_src_lib",
host_supported: true,
crate_name: "v4l2r",
cargo_env_compat: true,
cargo_pkg_version: "0.0.2",
crate_root: "src/lib.rs",
test_suites: ["general-tests"],
auto_gen_config: true,
test_options: {
unit_test: true,
},
edition: "2021",
rustlibs: [
"libanyhow",
Expand Down
5 changes: 5 additions & 0 deletions utils/Android.bp
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
// DO NOT SUBMIT: Add license before submitting.
rust_library {
name: "libv4l2r_utils",
host_supported: true,
crate_name: "v4l2r_utils",
cargo_env_compat: true,
cargo_pkg_version: "0.0.1",
Expand All @@ -28,12 +29,16 @@ rust_library {

rust_test {
name: "v4l2r-utils_test_src_lib",
host_supported: true,
crate_name: "v4l2r_utils",
cargo_env_compat: true,
cargo_pkg_version: "0.0.1",
crate_root: "src/lib.rs",
test_suites: ["general-tests"],
auto_gen_config: true,
test_options: {
unit_test: true,
},
edition: "2021",
rustlibs: [
"libanyhow",
Expand Down

0 comments on commit e04dee8

Please sign in to comment.