diff options
author | Joel Galenson <jgalenson@google.com> | 2021-04-27 14:25:48 -0700 |
---|---|---|
committer | Joel Galenson <jgalenson@google.com> | 2021-04-27 14:25:48 -0700 |
commit | 5f19f9fc1f55d75ac5ba425773512631297d18b4 (patch) | |
tree | 3ec477d7b01067633da10d4b2a1808b463f2e281 | |
parent | 7b26f1f2c9d297b9fa4f4c3a193fdadccaedb04e (diff) | |
download | matches-5f19f9fc1f55d75ac5ba425773512631297d18b4.tar.gz |
Generate apex_available from c2a instead of a patch
Test: Run c2a
Test: Build
Change-Id: Ied507cdb50f813a63df496d0d2ba8995f5aab24a
-rw-r--r-- | Android.bp | 3 | ||||
-rw-r--r-- | cargo2android.json | 11 | ||||
-rw-r--r-- | patches/Android.bp.patch | 16 |
3 files changed, 13 insertions, 17 deletions
@@ -1,4 +1,5 @@ -// This file is generated by cargo2android.py --run --device --dependencies --tests --patch=patches/Android.bp.patch. +// This file is generated by cargo2android.py --config cargo2android.json. +// Do not modify this file as changes will be overridden on upgrade. package { default_applicable_licenses: ["external_rust_crates_matches_license"], diff --git a/cargo2android.json b/cargo2android.json new file mode 100644 index 0000000..911c36f --- /dev/null +++ b/cargo2android.json @@ -0,0 +1,11 @@ +{ + "apex-available": [ + "//apex_available:platform", + "com.android.resolv" + ], + "dependencies": true, + "device": true, + "min-sdk-version": "29", + "run": true, + "tests": true +}
\ No newline at end of file diff --git a/patches/Android.bp.patch b/patches/Android.bp.patch deleted file mode 100644 index d7fd1ba..0000000 --- a/patches/Android.bp.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff --git a/Android.bp b/Android.bp -index de4144e..dc2efcc 100644 ---- a/Android.bp -+++ b/Android.bp -@@ -7,6 +7,11 @@ rust_library { - crate_name: "matches", - srcs: ["lib.rs"], - edition: "2015", -+ apex_available: [ -+ "//apex_available:platform", -+ "com.android.resolv", -+ ], -+ min_sdk_version: "29", - } - - rust_defaults { |