From 784e24eb3f0c100bb3f2da234330b8d93b27b722 Mon Sep 17 00:00:00 2001 From: "Jorge E. Moreira" Date: Thu, 22 Apr 2021 15:16:11 -0700 Subject: Configure apex so crosvm can depend on this crate Bug: 185155959 Test: locally Change-Id: I2ba7694d4d511e64efc2971dc5549d540398c801 --- Android.bp | 7 ++++++- patches/Android.bp.patch | 13 +++++++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 patches/Android.bp.patch diff --git a/Android.bp b/Android.bp index e99d7e0..cdf2b8d 100644 --- a/Android.bp +++ b/Android.bp @@ -1,4 +1,5 @@ -// This file is generated by cargo2android.py --device --run --dependencies. +// This file is generated by cargo2android.py --device --run --dependencies --patch=patches/Android.bp.patch. +// Do not modify this file as changes will be overridden on upgrade. package { default_applicable_licenses: ["external_rust_crates_smallvec_license"], @@ -42,4 +43,8 @@ rust_library { crate_name: "smallvec", srcs: ["src/lib.rs"], edition: "2018", + apex_available: [ + "//apex_available:platform", + "com.android.virt", + ], } diff --git a/patches/Android.bp.patch b/patches/Android.bp.patch new file mode 100644 index 0000000..5943f32 --- /dev/null +++ b/patches/Android.bp.patch @@ -0,0 +1,13 @@ +diff --git a/Android.bp b/Android.bp +index e99d7e0..12fdabd 100644 +--- a/Android.bp ++++ b/Android.bp +@@ -42,4 +42,8 @@ rust_library { + crate_name: "smallvec", + srcs: ["src/lib.rs"], + edition: "2018", ++ apex_available: [ ++ "//apex_available:platform", ++ "com.android.virt", ++ ], + } -- cgit v1.2.3