diff options
author | Roopa Sattiraju <sattiraju@google.com> | 2021-12-21 16:22:39 -0800 |
---|---|---|
committer | Joel Galenson <jgalenson@google.com> | 2021-12-22 11:13:43 -0800 |
commit | 4faf647191670eddfe02427a4d02dd591ca7ea0b (patch) | |
tree | 0c63549a54d8fbd95e25d8e5e5c37e47532f155f | |
parent | 66b7f2d79498b6a0448f18dc402670940720faee (diff) | |
download | grpcio-sys-4faf647191670eddfe02427a4d02dd591ca7ea0b.tar.gz |
Adding bluetooth apex
Bug: 206121418
Test: Compile
Change-Id: I8617972c3ce52d7411e649ab277c1ce7233e6ec0
-rw-r--r-- | Android.bp | 12 | ||||
-rw-r--r-- | cargo2android.json | 7 | ||||
-rw-r--r-- | patches/Android.bp.patch | 22 |
3 files changed, 33 insertions, 8 deletions
@@ -58,7 +58,12 @@ rust_library { shared_libs: [ "libgrpc++", "libgrpc_wrap" - ], + ], + apex_available: [ + "//apex_available:platform", + "com.android.bluetooth", + ], + min_sdk_version: "29", } cc_defaults { @@ -68,6 +73,11 @@ cc_defaults { ], cpp_std: "c++11", shared_libs: ["libgrpc++"], + apex_available: [ + "//apex_available:platform", + "com.android.bluetooth", + ], + min_sdk_version: "29", } cc_library { diff --git a/cargo2android.json b/cargo2android.json index 5edf07b4..64c04608 100644 --- a/cargo2android.json +++ b/cargo2android.json @@ -1,8 +1,13 @@ { + "apex_available": [ + "//apex_available:platform", + "com.android.bluetooth" + ], "device": true, "features": "default,secure", "ignore-cargo-errors": true, + "min-sdk-version": "29", "no-pkg-vers": true, "patch": "patches/Android.bp.patch", "run": true -}
\ No newline at end of file +} diff --git a/patches/Android.bp.patch b/patches/Android.bp.patch index 3e0977d5..202a5742 100644 --- a/patches/Android.bp.patch +++ b/patches/Android.bp.patch @@ -14,7 +14,7 @@ index 45707bc..d0369e6 100644 edition: "2018", features: [ "bindgen", -@@ -52,47 +55,64 @@ +@@ -55,52 +55,74 @@ "liblibc", "liblibz_sys", ], @@ -62,17 +62,27 @@ index 45707bc..d0369e6 100644 + shared_libs: [ + "libgrpc++", + "libgrpc_wrap" -+ ], -+} + ], +- shared_libs: ["libstdc++"], + apex_available: [ + "//apex_available:platform", + "com.android.bluetooth", + ], + min_sdk_version: "29", + } + +cc_defaults { + name: "libgrpcio_sys_defaults", + cflags: [ + "-DGRPC_SYS_SECURE", - ], -- shared_libs: ["libstdc++"], ++ ], + cpp_std: "c++11", + shared_libs: ["libgrpc++"], ++ apex_available: [ ++ "//apex_available:platform", ++ "com.android.bluetooth", ++ ], ++ min_sdk_version: "29", +} + +cc_library { @@ -120,4 +130,4 @@ index 45707bc..d0369e6 100644 + auto_gen_config: true, + clippy_lints: "none", + lints: "none", - } ++} |