Loading android/androidmk.go +4 −0 Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ type AndroidMkEntriesProvider interface { type AndroidMkEntries struct { Class string SubName string OverrideName string DistFiles TaggedDistFiles OutputFile OptionalPath Disabled bool Loading Loading @@ -273,6 +274,9 @@ func (a *AndroidMkEntries) fillInEntries(config Config, bpPath string, mod bluep a.EntryMap = make(map[string][]string) amod := mod.(Module).base() name := amod.BaseModuleName() if a.OverrideName != "" { name = a.OverrideName } if a.Include == "" { a.Include = "$(BUILD_PREBUILT)" Loading apex/apex.go +4 −3 Original line number Diff line number Diff line Loading @@ -2383,11 +2383,12 @@ func (a *apexBundle) GenerateAndroidBuildActions(ctx android.ModuleContext) { // system libraries. if !am.DirectlyInAnyApex() { // we need a module name for Make name := cc.BaseModuleName() + cc.Properties.SubName if proptools.Bool(a.properties.Use_vendor) { name := cc.ImplementationModuleName(ctx) if !proptools.Bool(a.properties.Use_vendor) { // we don't use subName(.vendor) for a "use_vendor: true" apex // which is supposed to be installed in /system name = cc.BaseModuleName() name += cc.Properties.SubName } if !android.InList(name, a.requiredDeps) { a.requiredDeps = append(a.requiredDeps, name) Loading apex/apex_test.go +2 −1 Original line number Diff line number Diff line Loading @@ -1270,10 +1270,11 @@ func TestApexDependsOnLLNDKTransitively(t *testing.T) { system_shared_libs: [], stl: "none", stubs: { versions: ["29","30"] }, llndk_stubs: "libbar.llndk", } llndk_library { name: "libbar", name: "libbar.llndk", symbol_file: "", } `, func(fs map[string][]byte, config android.Config) { Loading cc/androidmk.go +2 −0 Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ var ( ) type AndroidMkContext interface { BaseModuleName() string Target() android.Target subAndroidMk(*android.AndroidMkEntries, interface{}) Arch() android.Arch Loading Loading @@ -463,6 +464,7 @@ func (c *stubDecorator) AndroidMkEntries(ctx AndroidMkContext, entries *android. func (c *llndkStubDecorator) AndroidMkEntries(ctx AndroidMkContext, entries *android.AndroidMkEntries) { entries.Class = "SHARED_LIBRARIES" entries.OverrideName = c.implementationModuleName(ctx.BaseModuleName()) entries.ExtraEntries = append(entries.ExtraEntries, func(entries *android.AndroidMkEntries) { c.libraryDecorator.androidMkWriteExportedFlags(entries) Loading cc/cc.go +10 −0 Original line number Diff line number Diff line Loading @@ -1041,6 +1041,16 @@ func (c *Module) HasStubsVariants() bool { return false } // If this is a stubs library, ImplementationModuleName returns the name of the module that contains // the implementation. If it is an implementation library it returns its own name. func (c *Module) ImplementationModuleName(ctx android.BaseModuleContext) string { name := ctx.OtherModuleName(c) if versioned, ok := c.linker.(versionedInterface); ok { name = versioned.implementationModuleName(name) } return name } func (c *Module) bootstrap() bool { return Bool(c.Properties.Bootstrap) } Loading Loading
android/androidmk.go +4 −0 Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ type AndroidMkEntriesProvider interface { type AndroidMkEntries struct { Class string SubName string OverrideName string DistFiles TaggedDistFiles OutputFile OptionalPath Disabled bool Loading Loading @@ -273,6 +274,9 @@ func (a *AndroidMkEntries) fillInEntries(config Config, bpPath string, mod bluep a.EntryMap = make(map[string][]string) amod := mod.(Module).base() name := amod.BaseModuleName() if a.OverrideName != "" { name = a.OverrideName } if a.Include == "" { a.Include = "$(BUILD_PREBUILT)" Loading
apex/apex.go +4 −3 Original line number Diff line number Diff line Loading @@ -2383,11 +2383,12 @@ func (a *apexBundle) GenerateAndroidBuildActions(ctx android.ModuleContext) { // system libraries. if !am.DirectlyInAnyApex() { // we need a module name for Make name := cc.BaseModuleName() + cc.Properties.SubName if proptools.Bool(a.properties.Use_vendor) { name := cc.ImplementationModuleName(ctx) if !proptools.Bool(a.properties.Use_vendor) { // we don't use subName(.vendor) for a "use_vendor: true" apex // which is supposed to be installed in /system name = cc.BaseModuleName() name += cc.Properties.SubName } if !android.InList(name, a.requiredDeps) { a.requiredDeps = append(a.requiredDeps, name) Loading
apex/apex_test.go +2 −1 Original line number Diff line number Diff line Loading @@ -1270,10 +1270,11 @@ func TestApexDependsOnLLNDKTransitively(t *testing.T) { system_shared_libs: [], stl: "none", stubs: { versions: ["29","30"] }, llndk_stubs: "libbar.llndk", } llndk_library { name: "libbar", name: "libbar.llndk", symbol_file: "", } `, func(fs map[string][]byte, config android.Config) { Loading
cc/androidmk.go +2 −0 Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ var ( ) type AndroidMkContext interface { BaseModuleName() string Target() android.Target subAndroidMk(*android.AndroidMkEntries, interface{}) Arch() android.Arch Loading Loading @@ -463,6 +464,7 @@ func (c *stubDecorator) AndroidMkEntries(ctx AndroidMkContext, entries *android. func (c *llndkStubDecorator) AndroidMkEntries(ctx AndroidMkContext, entries *android.AndroidMkEntries) { entries.Class = "SHARED_LIBRARIES" entries.OverrideName = c.implementationModuleName(ctx.BaseModuleName()) entries.ExtraEntries = append(entries.ExtraEntries, func(entries *android.AndroidMkEntries) { c.libraryDecorator.androidMkWriteExportedFlags(entries) Loading
cc/cc.go +10 −0 Original line number Diff line number Diff line Loading @@ -1041,6 +1041,16 @@ func (c *Module) HasStubsVariants() bool { return false } // If this is a stubs library, ImplementationModuleName returns the name of the module that contains // the implementation. If it is an implementation library it returns its own name. func (c *Module) ImplementationModuleName(ctx android.BaseModuleContext) string { name := ctx.OtherModuleName(c) if versioned, ok := c.linker.(versionedInterface); ok { name = versioned.implementationModuleName(name) } return name } func (c *Module) bootstrap() bool { return Bool(c.Properties.Bootstrap) } Loading