Remove error from AndroidMkDataProvider.AndroidMk

It's never anything except nil, and it unnecessarily complicates
the implementations.

Test: m -j checkbuild
Change-Id: I3e3b7251f32ffa84dbdfd0448faf248c306ca808
This commit is contained in:
Colin Cross
2017-08-10 17:00:19 -07:00
parent 91825d2279
commit a18e9cfa29
5 changed files with 60 additions and 46 deletions

View File

@@ -48,13 +48,14 @@ func (p *phony) GenerateAndroidBuildActions(ctx android.ModuleContext) {
}
}
func (p *phony) AndroidMk() (ret android.AndroidMkData, err error) {
ret.Custom = func(w io.Writer, name, prefix, moduleDir string) {
fmt.Fprintln(w, "\ninclude $(CLEAR_VARS)")
fmt.Fprintln(w, "LOCAL_PATH :=", moduleDir)
fmt.Fprintln(w, "LOCAL_MODULE :=", name)
fmt.Fprintln(w, "LOCAL_REQUIRED_MODULES := "+strings.Join(p.requiredModuleNames, " "))
fmt.Fprintln(w, "include $(BUILD_PHONY_PACKAGE)")
func (p *phony) AndroidMk() android.AndroidMkData {
return android.AndroidMkData{
Custom: func(w io.Writer, name, prefix, moduleDir string) {
fmt.Fprintln(w, "\ninclude $(CLEAR_VARS)")
fmt.Fprintln(w, "LOCAL_PATH :=", moduleDir)
fmt.Fprintln(w, "LOCAL_MODULE :=", name)
fmt.Fprintln(w, "LOCAL_REQUIRED_MODULES := "+strings.Join(p.requiredModuleNames, " "))
fmt.Fprintln(w, "include $(BUILD_PHONY_PACKAGE)")
},
}
return
}