aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBill Peckham <bpeckham@google.com>2019-10-17 18:07:39 -0700
committerBill Peckham <bpeckham@google.com>2019-10-18 10:57:54 -0700
commit2a13eb6fe4d765bfc6782696908c3239625b3864 (patch)
treeea36a0d5b6bba8bd6e957f1cb16344a04875d6d5
parent9fc2117ca66fd5c41b47161c69fcedd21063387a (diff)
downloadbrotli-2a13eb6fe4d765bfc6782696908c3239625b3864.tar.gz
Restrict visibility of libraries that are newly vendor_available: true.
As part of fixing b/68319577, some libraries were made vendor_available: true. To minimize new dependencies from vendor on these libraries, this change restricts the visibility of the libraries to only the framework projects that currently use them. Additionally, the only user of the libbrotli shared library is brotli itself, so we eliminate the shared library, preventing the shared library from entering the vndk. The brotli executable now links to the static libbrotli. Bug: 141649008 Test: Targets build successfully. Change-Id: I5b9ebdaa44214598f36540cd0dae023d5bf11e42
-rwxr-xr-xAndroid.bp12
1 files changed, 10 insertions, 2 deletions
diff --git a/Android.bp b/Android.bp
index f5551db..8390a3d 100755
--- a/Android.bp
+++ b/Android.bp
@@ -13,11 +13,19 @@
// limitations under the License.
//
-cc_library {
+cc_library_static {
name: "libbrotli",
host_supported: true,
vendor_available: true,
recovery_available: true,
+
+ visibility: [
+ "//bootable/recovery:__subpackages__",
+ "//external/bsdiff:__subpackages__",
+ "//external/puffin:__subpackages__",
+ "//system/update_engine:__subpackages__",
+ ],
+
cflags: [
"-Werror",
"-O2",
@@ -46,7 +54,7 @@ cc_binary {
enabled: true,
},
},
- shared_libs: ["libbrotli"],
+ static_libs: ["libbrotli"],
}
//