summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Hansson <hansson@google.com>2021-09-02 12:42:08 +0100
committerAnton Hansson <hansson@google.com>2021-09-02 13:15:08 +0100
commit8f86a25b771cf6bc84f99ed8562770ed20042d4a (patch)
tree99f4b34769cb3382100a8e470a82704ec56bcfce
parent3ae814f3e1dcd90c9ad51acc010fb746a45b0fee (diff)
downloadCellBroadcastReceiver-8f86a25b771cf6bc84f99ed8562770ed20042d4a.tar.gz
Compile CellBroadcastReceiver with module_current
This sdk_version is one created especially for modules, and includes @SystemApi(client = MODULE_LIBRARIES) on top of normal @SystemApi. Note that to call these APIs the app must be allowed to access hidden APIs, which normal APKs are not but APK-in-apexes are. This allows removing framework-annotations from the module sources, which avoids follow-on problems of depending on shared util libraries. Bug: 198418216 Test: m com.android.cellbroadcast Merged-In: I2be92e9a42e104987519bfd3c617c443d9bfece1 Change-Id: I2be92e9a42e104987519bfd3c617c443d9bfece1
-rw-r--r--Android.bp10
-rw-r--r--legacy/Android.bp8
2 files changed, 11 insertions, 7 deletions
diff --git a/Android.bp b/Android.bp
index 86b568c74..bea02f5dc 100644
--- a/Android.bp
+++ b/Android.bp
@@ -21,14 +21,17 @@ license {
java_defaults {
name: "CellBroadcastCommon",
min_sdk_version: "29",
- sdk_version: "system_current",
+ sdk_version: "module_current",
privileged: true,
srcs: [
"src/**/*.java",
- ":framework-annotations",
":cellbroadcast-constants-shared-srcs",
":statslog-cellbroadcast-java-gen",
- ],
+ ],
+ libs: [
+ "framework-annotations-lib",
+ "framework-statsd",
+ ],
static_libs: [
"androidx.legacy_legacy-support-v4",
"androidx.legacy_legacy-support-v13",
@@ -58,7 +61,6 @@ filegroup {
name: "cellbroadcastreceiver-sources",
srcs: [
"src/**/*.java",
- ":framework-annotations",
":cellbroadcast-constants-shared-srcs",
],
}
diff --git a/legacy/Android.bp b/legacy/Android.bp
index 16d23700d..12008832c 100644
--- a/legacy/Android.bp
+++ b/legacy/Android.bp
@@ -24,14 +24,16 @@ android_app {
"androidx.appcompat_appcompat",
],
- libs: ["app-compat-annotations"],
+ libs: [
+ "app-compat-annotations",
+ "framework-annotations-lib",
+ ],
srcs: [
"src/**/*.aidl",
"src/**/*.java",
- ":framework-annotations",
":cellbroadcast-database-sources",
],
privileged: true,
- sdk_version: "system_current",
+ sdk_version: "module_current",
}