Surface Java APIs Used By APK-only Modules.
Previously we were only generating used-by API-coverage for APEX modules.
This change adds support for APK-only modules such as NetworkStack and DocumentsUI.
Bug: b/216313756
Forrest Run: https://android-build.googleplex.com/builds/abtd/run/L10800000953846781
Test: TARGET_BUILD_VARIANT=userdebug PRODUCT=mainline_modules_x86 ./vendor/google/build/build_unbundled_coverage_mainline_module.sh -j16
Change-Id: Id17e4a55c2a52e9903632a654e778f8d54982dfc
Merged-In: Id17e4a55c2a52e9903632a654e778f8d54982dfc
(cherry picked from commit 56d75785bd52c8a8f684935eed67fceb2c0e6850)
diff --git a/java/app.go b/java/app.go
index a1a854e..1b65f33 100755
--- a/java/app.go
+++ b/java/app.go
@@ -169,6 +169,8 @@
overriddenManifestPackageName string
android.ApexBundleDepsInfo
+
+ javaApiUsedByOutputFile android.ModuleOutPath
}
func (a *AndroidApp) IsInstallable() bool {
@@ -277,6 +279,7 @@
func (a *AndroidApp) GenerateAndroidBuildActions(ctx android.ModuleContext) {
a.checkAppSdkVersions(ctx)
a.generateAndroidBuildActions(ctx)
+ a.generateJavaUsedByApex(ctx)
}
func (a *AndroidApp) checkAppSdkVersions(ctx android.ModuleContext) {