From 6592e87dbfe1e49b5c57ca8ead0bb48e6354e261 Mon Sep 17 00:00:00 2001 From: Jihoon Kang Date: Tue, 19 Dec 2023 01:13:16 +0000 Subject: Add aconfig_declarations property to droidstubs and java_sdk_library In consideration of the incremental build performance, this change let droidstubs and java_sdk_library (which generates droidstubs per api scope) modules to specify `aconfig_declaration` modules where the dependent flags are defined in via the "aconfig_declarations" property, opposed to passing uniform "all_aconfig_declaration"-generated flag arguments to metalava. When "aconfig_declarations" property is defined for java_sdk_library modules, the property is passed to the generated droidstubs modules. When "aconfig_declarations" property is defined for droidstubs modules, the all aconfig_declaration modules listed in the property are listed as deps, all cache protobuf files are gathered and metalava-consumable flags are generated in "revert-annotations.txt". Although this change introduces scalable implementation to easily support generation of the "runtime" stubs corresponding flags, actual support of the runtime flags/stubs will be done in future changes. This change mostly focuses on the generation of the "exportable" flags. Utilization of the generated "exportable" flags will be done in future changes. Test: go test ./java Bug: 315485740 Change-Id: I37becd1b9dd9069d7ac4abed130906df30b3fdf4 --- java/java.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'java/java.go') diff --git a/java/java.go b/java/java.go index 2a4fafa8b..4227d368e 100644 --- a/java/java.go +++ b/java/java.go @@ -26,6 +26,7 @@ import ( "android/soong/remoteexec" "android/soong/testing" + "github.com/google/blueprint" "github.com/google/blueprint/proptools" @@ -519,6 +520,7 @@ type deps struct { kotlinStdlib android.Paths kotlinAnnotations android.Paths kotlinPlugins android.Paths + aconfigProtoFiles android.Paths disableTurbine bool } -- cgit v1.2.3-59-g8ed1b