Convert appsearch to java_sdk_library
AppSearch build file only defined a subset of the stubs and api
tracking, which prevents making progress on creating a correct "merged"
current.txt. Convert it to the standard build setup modules should use.
Implementation wise, this is a little bit special in that it's somewhere
between a module and not. The implementation library requires platform
internals to compile. The stubs do not, and we rely on this to make
the build work at all -- via impl_only_libs we compile the stubs
*without* framework-minus-apex, which allows framework-minus-apex to
depend on the stubs.
Bug: 169304493
Test: m checkapi
Change-Id: I10a331bb6df56072cb9e9ada99ae47c5446869fd
diff --git a/Android.bp b/Android.bp
index 06f3666..d4cd474 100644
--- a/Android.bp
+++ b/Android.bp
@@ -374,7 +374,7 @@
java_library {
name: "framework-updatable-stubs-module_libs_api",
static_libs: [
- "framework-appsearch-stubs", // TODO: Update to module_libs_api when there is one.
+ "framework-appsearch.stubs.module_lib",
"framework-graphics.stubs.module_lib",
"framework-media.stubs.module_lib",
"framework-mediaprovider.stubs.module_lib",
@@ -393,7 +393,7 @@
installable: false,
static_libs: [
"framework-minus-apex",
- "framework-appsearch",
+ "framework-appsearch.impl",
"framework-graphics.impl",
"framework-mediaprovider.impl",
"framework-permission.impl",
@@ -623,8 +623,7 @@
static_libs: [
"app-compat-annotations",
"framework-minus-apex",
- // TODO(b/146218515): should be removed
- "framework-appsearch",
+ "framework-appsearch.impl", // TODO(b/146218515): should be removed
"framework-updatable-stubs-module_libs_api",
],
sdk_version: "core_platform",