Annotate paths and deprecate ExtractSource(s)Deps

Add `android:"path"` to all properties that take paths to source
files, and remove the calls to ExtractSource(s)Deps, the
pathsDepsMutator will add the necessary SourceDepTag dependency.

Test: All soong tests
Change-Id: I488ba1a5d680aaa50b04fc38acf693e23c6d4d6d
This commit is contained in:
Colin Cross
2019-03-04 22:35:41 -08:00
parent 1b48842a4b
commit 27b922f53e
23 changed files with 83 additions and 236 deletions

View File

@@ -32,7 +32,7 @@ func init() {
type shBinaryProperties struct {
// Source file of this prebuilt.
Src *string `android:"arch_variant"`
Src *string `android:"path,arch_variant"`
// optional subdirectory under which this file is installed into
Sub_dir *string `android:"arch_variant"`
@@ -61,9 +61,6 @@ func (s *ShBinary) DepsMutator(ctx BottomUpMutatorContext) {
if s.properties.Src == nil {
ctx.PropertyErrorf("src", "missing prebuilt source file")
}
// To support ":modulename" in src
ExtractSourceDeps(ctx, s.properties.Src)
}
func (s *ShBinary) SourceFilePath(ctx ModuleContext) Path {