From 4147550acdd34a7e083ee1d197805ba04648c7f0 Mon Sep 17 00:00:00 2001 From: Paul Duffin Date: Fri, 22 May 2020 17:12:12 +0100 Subject: [PATCH] Disable shared library support for framework modules Defaults shared library to false as the majority of framework modules should not be usable as a shared library. The exception is ike but it does not currently use the defaults and will override this setting when it does. Bug: 156723295 Bug: 155164730 Test: m droid and flash Change-Id: I3e78994a9855110b02c3d71944ff38b986208e9a --- apex/Android.bp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/apex/Android.bp b/apex/Android.bp index f511af570bb11..6fdda867f0efe 100644 --- a/apex/Android.bp +++ b/apex/Android.bp @@ -71,6 +71,11 @@ java_defaults { // stubs libraries. libs: ["framework-annotations-lib"], + // Framework modules are not generally shared libraries, i.e. they are not + // intended, and must not be allowed, to be used in a manifest + // entry. + shared_library: false, + // Enable api lint. This will eventually become the default for java_sdk_library // but it cannot yet be turned on because some usages have not been cleaned up. // TODO(b/156126315) - Remove when no longer needed.