summaryrefslogtreecommitdiff
path: root/apex
diff options
context:
space:
mode:
authorPaul Duffin <paulduffin@google.com>2020-05-29 09:50:20 +0100
committerPaul Duffin <paulduffin@google.com>2020-05-29 09:50:20 +0100
commit1a0ba1ef241f8713bb4ca4882516db4ec2a1e1e2 (patch)
tree0d508a4db2e4bc3704a44de133acb20851eded2e /apex
parent8dc6549e05230769f6439bf5429d799e489383d5 (diff)
Prevent default use of framework module implementation
Prevent dependencies that do not specify an sdk_version from accessing the implementation library of a framework module by default and force them to use stubs instead. Bug: 155164730 Test: m nothing Change-Id: Ib60e538a4017857eefa3465e56745c00306887e1
Diffstat (limited to 'apex')
-rw-r--r--apex/Android.bp4
1 files changed, 4 insertions, 0 deletions
diff --git a/apex/Android.bp b/apex/Android.bp
index 505c3fc12d05..380b4c6cc0be 100644
--- a/apex/Android.bp
+++ b/apex/Android.bp
@@ -76,6 +76,10 @@ java_defaults {
// entry.
shared_library: false,
+ // Prevent dependencies that do not specify an sdk_version from accessing the
+ // implementation library by default and force them to use stubs instead.
+ default_to_stubs: true,
+
// 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.