Revert "Use OutputFilesProvider on buildinfo_prop and some android test modules"
This reverts commit 89e4ff60d361cc7e0542f5da7a31c64f90b6d3b8.
Reason for revert: build breakage on aosp-main/mainline_modules_sdks-trunk_staging-userdebug
Change-Id: I5ddac59f66a0e7a96fab39647d406499e3875f6a
diff --git a/android/paths_test.go b/android/paths_test.go
index 941f0ca..93b9b9a 100644
--- a/android/paths_test.go
+++ b/android/paths_test.go
@@ -1183,6 +1183,9 @@
Outs []string
Tagged []string
}
+
+ outs Paths
+ tagged Paths
}
func pathForModuleSrcOutputFileProviderModuleFactory() Module {
@@ -1193,17 +1196,24 @@
}
func (p *pathForModuleSrcOutputFileProviderModule) GenerateAndroidBuildActions(ctx ModuleContext) {
- var outs, taggedOuts Paths
for _, out := range p.props.Outs {
- outs = append(outs, PathForModuleOut(ctx, out))
+ p.outs = append(p.outs, PathForModuleOut(ctx, out))
}
for _, tagged := range p.props.Tagged {
- taggedOuts = append(taggedOuts, PathForModuleOut(ctx, tagged))
+ p.tagged = append(p.tagged, PathForModuleOut(ctx, tagged))
}
+}
- ctx.SetOutputFiles(outs, "")
- ctx.SetOutputFiles(taggedOuts, ".tagged")
+func (p *pathForModuleSrcOutputFileProviderModule) OutputFiles(tag string) (Paths, error) {
+ switch tag {
+ case "":
+ return p.outs, nil
+ case ".tagged":
+ return p.tagged, nil
+ default:
+ return nil, fmt.Errorf("unsupported tag %q", tag)
+ }
}
type pathForModuleSrcTestCase struct {