summaryrefslogtreecommitdiff
path: root/java/java.go
diff options
context:
space:
mode:
author Jihoon Kang <jihoonkang@google.com> 2023-05-19 00:12:22 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2023-05-19 00:12:22 +0000
commit0393174fe78afa42a6bac036b96cd4a690563535 (patch)
treec940964087402b50ca87a4243e47c0fdc7f60cd6 /java/java.go
parenta38fb02a25f68cc050aef808bc180a782ca2e83b (diff)
parent795319fadb84b4e65c9fb3defbaf25b612acd53b (diff)
Merge "Disallow missing api source files for java_api_library module"
Diffstat (limited to 'java/java.go')
-rw-r--r--java/java.go6
1 files changed, 2 insertions, 4 deletions
diff --git a/java/java.go b/java/java.go
index 65bfce088..bb8fe62aa 100644
--- a/java/java.go
+++ b/java/java.go
@@ -1650,7 +1650,7 @@ type JavaApiLibraryProperties struct {
// list of api.txt files relative to this directory that contribute to the
// API surface.
// This is a list of relative paths
- Api_files []string
+ Api_files []string `android:"path"`
// List of flags to be passed to the javac compiler to generate jar file
Javacflags []string
@@ -1832,9 +1832,7 @@ func (al *ApiLibrary) GenerateAndroidBuildActions(ctx android.ModuleContext) {
// Add the api_files inputs
for _, api := range al.properties.Api_files {
- // Use MaybeExistentPathForSource since the api file might not exist during analysis.
- // This will be provided by the orchestrator in the combined execution.
- srcFiles = append(srcFiles, android.MaybeExistentPathForSource(ctx, ctx.ModuleDir(), api))
+ srcFiles = append(srcFiles, android.PathForModuleSrc(ctx, api))
}
if srcFiles == nil {