Use OutputFilesProvider on sh_binary
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: I77929210f4ee2d83d110bca1391edc54be69f0db
This commit is contained in:
@@ -15,7 +15,6 @@
|
|||||||
package sh
|
package sh
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
@@ -188,15 +187,6 @@ func (s *ShBinary) OutputFile() android.OutputPath {
|
|||||||
return s.outputFilePath
|
return s.outputFilePath
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *ShBinary) OutputFiles(tag string) (android.Paths, error) {
|
|
||||||
switch tag {
|
|
||||||
case "":
|
|
||||||
return android.Paths{s.outputFilePath}, nil
|
|
||||||
default:
|
|
||||||
return nil, fmt.Errorf("unsupported module reference tag %q", tag)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
func (s *ShBinary) SubDir() string {
|
func (s *ShBinary) SubDir() string {
|
||||||
return proptools.String(s.properties.Sub_dir)
|
return proptools.String(s.properties.Sub_dir)
|
||||||
}
|
}
|
||||||
@@ -271,6 +261,8 @@ func (s *ShBinary) generateAndroidBuildActions(ctx android.ModuleContext) {
|
|||||||
Input: s.sourceFilePath,
|
Input: s.sourceFilePath,
|
||||||
})
|
})
|
||||||
android.SetProvider(ctx, blueprint.SrcsFileProviderKey, blueprint.SrcsFileProviderData{SrcPaths: []string{s.sourceFilePath.String()}})
|
android.SetProvider(ctx, blueprint.SrcsFileProviderKey, blueprint.SrcsFileProviderData{SrcPaths: []string{s.sourceFilePath.String()}})
|
||||||
|
|
||||||
|
ctx.SetOutputFiles(android.Paths{s.outputFilePath}, "")
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *ShBinary) GenerateAndroidBuildActions(ctx android.ModuleContext) {
|
func (s *ShBinary) GenerateAndroidBuildActions(ctx android.ModuleContext) {
|
||||||
|
Reference in New Issue
Block a user