Add Target to cc.SharedLibraryInfo
Dependencies from common arch modules like java libraires to cc modules may need to retrieve the Target of the library, add it to SharedLibraryInfo. Bug: 176593487 Test: cc_test.go Change-Id: I93ab9da5fab2ccc42c6b483a6d83c071b541d1e6
This commit is contained in:
parent
e09ac17466
commit
2df8177575
|
@ -1110,6 +1110,7 @@ func (library *libraryDecorator) linkShared(ctx ModuleContext,
|
|||
UnstrippedSharedLibrary: library.unstrippedOutputFile,
|
||||
CoverageSharedLibrary: library.coverageOutputFile,
|
||||
StaticAnalogue: staticAnalogue,
|
||||
Target: ctx.Target(),
|
||||
})
|
||||
|
||||
stubs := ctx.GetDirectDepsWithTag(stubImplDepTag)
|
||||
|
|
|
@ -168,6 +168,7 @@ func HeaderDepTag() blueprint.DependencyTag {
|
|||
type SharedLibraryInfo struct {
|
||||
SharedLibrary android.Path
|
||||
UnstrippedSharedLibrary android.Path
|
||||
Target android.Target
|
||||
|
||||
TableOfContents android.OptionalPath
|
||||
CoverageSharedLibrary android.OptionalPath
|
||||
|
|
|
@ -188,6 +188,7 @@ func (ndk *ndkPrebuiltStlLinker) link(ctx ModuleContext, flags Flags,
|
|||
ctx.SetProvider(SharedLibraryInfoProvider, SharedLibraryInfo{
|
||||
SharedLibrary: lib,
|
||||
UnstrippedSharedLibrary: lib,
|
||||
Target: ctx.Target(),
|
||||
})
|
||||
}
|
||||
|
||||
|
|
|
@ -185,6 +185,7 @@ func (p *prebuiltLibraryLinker) link(ctx ModuleContext,
|
|||
ctx.SetProvider(SharedLibraryInfoProvider, SharedLibraryInfo{
|
||||
SharedLibrary: outputFile,
|
||||
UnstrippedSharedLibrary: p.unstrippedOutputFile,
|
||||
Target: ctx.Target(),
|
||||
|
||||
TableOfContents: p.tocFile,
|
||||
})
|
||||
|
|
|
@ -605,6 +605,7 @@ func (p *snapshotLibraryDecorator) link(ctx ModuleContext, flags Flags, deps Pat
|
|||
ctx.SetProvider(SharedLibraryInfoProvider, SharedLibraryInfo{
|
||||
SharedLibrary: in,
|
||||
UnstrippedSharedLibrary: p.unstrippedOutputFile,
|
||||
Target: ctx.Target(),
|
||||
|
||||
TableOfContents: p.tocFile,
|
||||
})
|
||||
|
|
|
@ -166,6 +166,7 @@ func (p *vndkPrebuiltLibraryDecorator) link(ctx ModuleContext,
|
|||
ctx.SetProvider(SharedLibraryInfoProvider, SharedLibraryInfo{
|
||||
SharedLibrary: in,
|
||||
UnstrippedSharedLibrary: p.unstrippedOutputFile,
|
||||
Target: ctx.Target(),
|
||||
|
||||
TableOfContents: p.tocFile,
|
||||
})
|
||||
|
|
|
@ -505,6 +505,7 @@ func (library *libraryDecorator) compile(ctx ModuleContext, flags Flags, deps Pa
|
|||
ctx.SetProvider(cc.SharedLibraryInfoProvider, cc.SharedLibraryInfo{
|
||||
SharedLibrary: outputFile,
|
||||
UnstrippedSharedLibrary: outputFile,
|
||||
Target: ctx.Target(),
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue