diff options
author | 2024-02-15 21:53:49 +0000 | |
---|---|---|
committer | 2024-02-28 07:55:32 +0000 | |
commit | 5d701272e44e63504b4c9e106f33d62361b35705 (patch) | |
tree | e52476c9a53d9a2b431af51904a050261012f245 /java/testing.go | |
parent | 60bdd05b213952edbe9d4fbc0ae8511109f67555 (diff) |
Enable non-"everything" stubs generation in java_api_library
This change adds support to generate non-"everything" (i.e. "runtime"
and "exportable") stubs in java_api_library, which generates the stubs
from the api signature files.
Unlike droidstubs module that generates "everything", "exportable" and
"runtime" stubs in a single module, java_api_library generates a single
set of stubs per module, which is set by the default-"everything"
property `stubs_type`. This is because java_api_library is responsible
for both generation and the compilation of the stubs srcjar, and
compilation of the stubs srcjar are done in separate java_library
modules for from-source stubs.
Utilization of this feature will be done in a follow up change that
generates the "exportable" java_api_library modules in java_sdk_library.
Test: m nothing --no-skip-soong-tests
Bug: 318009570
Change-Id: I1051544ac3bcdb3ba1f78bfec28eba4e9fad9c2d
Diffstat (limited to 'java/testing.go')
-rw-r--r-- | java/testing.go | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/java/testing.go b/java/testing.go index 04e8c734e..631d51662 100644 --- a/java/testing.go +++ b/java/testing.go @@ -523,10 +523,11 @@ func gatherRequiredDepsForTest() string { for libName, droidstubs := range extraApiLibraryModules { bp += fmt.Sprintf(` - java_api_library { - name: "%s", - api_contributions: ["%s"], - } + java_api_library { + name: "%s", + api_contributions: ["%s"], + stubs_type: "everything", + } `, libName, droidstubs.name+".api.contribution") } |