From 9f7b9f4a9ab77d1816e8ae30ac8339e335fb7e92 Mon Sep 17 00:00:00 2001 From: mrziwang Date: Wed, 10 Jul 2024 12:18:06 -0700 Subject: Use OutputFilesProvider on java modules In the context of incremental soong, the output files inter-module-communication will be through OutputFilesProvider. The OutputFileProducer interface will be deprecated. Test: CI Bug: 339477385 Change-Id: I3c9f0b766325dd490bc903dc65259c3953d34606 --- android/module.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'android/module.go') diff --git a/android/module.go b/android/module.go index 66f6e1bcd..2fe822f26 100644 --- a/android/module.go +++ b/android/module.go @@ -2491,6 +2491,8 @@ func outputFilesForModule(ctx PathContext, module blueprint.Module, tag string) if outputFilesFromProvider != nil || err != OutputFilesProviderNotSet { return outputFilesFromProvider, err } + // TODO: add error when outputFilesFromProvider and err are both nil after + // OutputFileProducer and SourceFileProducer are deprecated. if outputFileProducer, ok := module.(OutputFileProducer); ok { paths, err := outputFileProducer.OutputFiles(tag) if err != nil { @@ -2505,7 +2507,7 @@ func outputFilesForModule(ctx PathContext, module blueprint.Module, tag string) paths := sourceFileProducer.Srcs() return paths, nil } else { - return nil, fmt.Errorf("module %q is not an OutputFileProducer or SourceFileProducer", pathContextName(ctx, module)) + return nil, fmt.Errorf("module %q is not an SourceFileProducer or having valid output file for tag %q", pathContextName(ctx, module), tag) } } -- cgit v1.2.3-59-g8ed1b