aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVictor Hsieh <victorhsieh@google.com>2021-03-12 09:16:11 -0800
committerVictor Hsieh <victorhsieh@google.com>2021-03-12 09:16:11 -0800
commit59ca1d53d81673e491714b0846147a559fb7caa5 (patch)
tree6c3afa3ae1368d57850eba6b17fc94eb4386a3f6
parent032c1fc274991798df43e9c37acbf36354909aeb (diff)
downloadtextwrap-59ca1d53d81673e491714b0846147a559fb7caa5.tar.gz
Allow textwrap crate in com.android.virt apex
Bug: 182570135 Test: m Change-Id: Id9a2ad6db365dec13cbd8d29a8f3984b0d18033f
-rw-r--r--Android.bp23
-rw-r--r--TEST_MAPPING3
-rw-r--r--patches/Android.bp.patch13
3 files changed, 21 insertions, 18 deletions
diff --git a/Android.bp b/Android.bp
index 4e01879..5033087 100644
--- a/Android.bp
+++ b/Android.bp
@@ -1,27 +1,14 @@
-// This file is generated by cargo2android.py --run --dependencies --device --features=.
+// This file is generated by cargo2android.py --run --dependencies --device --features= --patch=patches/Android.bp.patch.
// Do not modify this file as changes will be overridden on upgrade.
-package {
- default_applicable_licenses: ["external_rust_crates_textwrap_license"],
-}
-
-// Added automatically by a large-scale-change
-// See: http://go/android-license-faq
-license {
- name: "external_rust_crates_textwrap_license",
- visibility: [":__subpackages__"],
- license_kinds: [
- "SPDX-license-identifier-MIT",
- ],
- license_text: [
- "LICENSE",
- ],
-}
-
rust_library {
name: "libtextwrap",
host_supported: true,
crate_name: "textwrap",
srcs: ["src/lib.rs"],
edition: "2018",
+ apex_available: [
+ "//apex_available:platform",
+ "com.android.virt",
+ ],
}
diff --git a/TEST_MAPPING b/TEST_MAPPING
index f1cd786..661ac5c 100644
--- a/TEST_MAPPING
+++ b/TEST_MAPPING
@@ -5,6 +5,9 @@
"name": "authfs_device_test_src_lib"
},
{
+ "name": "vpnprofilestore_test"
+ },
+ {
"name": "keystore2_test"
},
{
diff --git a/patches/Android.bp.patch b/patches/Android.bp.patch
new file mode 100644
index 0000000..356e1c2
--- /dev/null
+++ b/patches/Android.bp.patch
@@ -0,0 +1,13 @@
+diff --git a/Android.bp b/Android.bp
+index f879002..893238d 100644
+--- a/Android.bp
++++ b/Android.bp
+@@ -7,4 +7,8 @@ rust_library {
+ crate_name: "textwrap",
+ srcs: ["src/lib.rs"],
+ edition: "2018",
++ apex_available: [
++ "//apex_available:platform",
++ "com.android.virt",
++ ],
+ }