Add unstrippedOutputFilePath to the linker interface

Test: m
Change-Id: I85a0cbda6ebb9838451ed8c607c2087460b7b742
This commit is contained in:
Jiyong Park
2019-01-31 12:21:23 +09:00
parent df819e6b0c
commit af6d895941
4 changed files with 15 additions and 4 deletions

View File

@@ -405,6 +405,10 @@ func (binary *binaryDecorator) link(ctx ModuleContext,
return ret return ret
} }
func (binary *binaryDecorator) unstrippedOutputFilePath() android.Path {
return binary.unstrippedOutputFile
}
func (binary *binaryDecorator) symlinkList() []string { func (binary *binaryDecorator) symlinkList() []string {
return binary.symlinks return binary.symlinks
} }

View File

@@ -306,6 +306,7 @@ type linker interface {
link(ctx ModuleContext, flags Flags, deps PathDeps, objs Objects) android.Path link(ctx ModuleContext, flags Flags, deps PathDeps, objs Objects) android.Path
appendLdflags([]string) appendLdflags([]string)
unstrippedOutputFilePath() android.Path
} }
type installer interface { type installer interface {
@@ -406,10 +407,8 @@ func (c *Module) OutputFile() android.OptionalPath {
} }
func (c *Module) UnstrippedOutputFile() android.Path { func (c *Module) UnstrippedOutputFile() android.Path {
if library, ok := c.linker.(*libraryDecorator); ok { if c.linker != nil {
return library.unstrippedOutputFile return c.linker.unstrippedOutputFilePath()
} else if binary, ok := c.linker.(*binaryDecorator); ok {
return binary.unstrippedOutputFile
} }
return nil return nil
} }

View File

@@ -740,6 +740,10 @@ func (library *libraryDecorator) linkShared(ctx ModuleContext,
return ret return ret
} }
func (library *libraryDecorator) unstrippedOutputFilePath() android.Path {
return library.unstrippedOutputFile
}
func getRefAbiDumpFile(ctx ModuleContext, vndkVersion, fileName string) android.Path { func getRefAbiDumpFile(ctx ModuleContext, vndkVersion, fileName string) android.Path {
isLlndk := inList(ctx.baseModuleName(), llndkLibraries) || inList(ctx.baseModuleName(), ndkMigratedLibs) isLlndk := inList(ctx.baseModuleName(), llndkLibraries) || inList(ctx.baseModuleName(), ndkMigratedLibs)

View File

@@ -107,3 +107,7 @@ func (object *objectLinker) link(ctx ModuleContext,
ctx.CheckbuildFile(outputFile) ctx.CheckbuildFile(outputFile)
return outputFile return outputFile
} }
func (object *objectLinker) unstrippedOutputFilePath() android.Path {
return nil
}