Loading apex/apex.go +2 −2 Original line number Diff line number Diff line Loading @@ -2744,12 +2744,12 @@ func (a *apexBundle) checkApexAvailability(ctx android.ModuleContext) { // checkStaticExecutable ensures that executables in an APEX are not static. func (a *apexBundle) checkStaticExecutables(ctx android.ModuleContext) { ctx.VisitDirectDeps(func(module android.Module) { ctx.VisitDirectDepsProxy(func(module android.ModuleProxy) { if ctx.OtherModuleDependencyTag(module) != executableTag { return } if l, ok := module.(cc.LinkableInterface); ok && l.StaticExecutable() { if android.OtherModuleProviderOrDefault(ctx, module, cc.LinkableInfoKey).StaticExecutable { apex := a.ApexVariationName() exec := ctx.OtherModuleName(module) if isStaticExecutableAllowed(apex, exec) { Loading cc/cc.go +11 −0 Original line number Diff line number Diff line Loading @@ -53,6 +53,13 @@ type CcObjectInfo struct { var CcObjectInfoProvider = blueprint.NewProvider[CcObjectInfo]() type LinkableInfo struct { // StaticExecutable returns true if this is a binary module with "static_executable: true". StaticExecutable bool } var LinkableInfoKey = blueprint.NewProvider[LinkableInfo]() func init() { RegisterCCBuildComponents(android.InitRegistrationContext) Loading Loading @@ -2119,6 +2126,10 @@ func (c *Module) GenerateAndroidBuildActions(actx android.ModuleContext) { android.SetProvider(ctx, CcObjectInfoProvider, ccObjectInfo) } android.SetProvider(ctx, LinkableInfoKey, LinkableInfo{ StaticExecutable: c.StaticExecutable(), }) c.setOutputFiles(ctx) if c.makeVarsInfo != nil { Loading rust/rust.go +4 −0 Original line number Diff line number Diff line Loading @@ -1001,6 +1001,10 @@ func (mod *Module) GenerateAndroidBuildActions(actx android.ModuleContext) { ctx.Phony("rust", ctx.RustModule().OutputFile().Path()) } android.SetProvider(ctx, cc.LinkableInfoKey, cc.LinkableInfo{ StaticExecutable: mod.StaticExecutable(), }) mod.setOutputFiles(ctx) buildComplianceMetadataInfo(ctx, mod, deps) Loading Loading
apex/apex.go +2 −2 Original line number Diff line number Diff line Loading @@ -2744,12 +2744,12 @@ func (a *apexBundle) checkApexAvailability(ctx android.ModuleContext) { // checkStaticExecutable ensures that executables in an APEX are not static. func (a *apexBundle) checkStaticExecutables(ctx android.ModuleContext) { ctx.VisitDirectDeps(func(module android.Module) { ctx.VisitDirectDepsProxy(func(module android.ModuleProxy) { if ctx.OtherModuleDependencyTag(module) != executableTag { return } if l, ok := module.(cc.LinkableInterface); ok && l.StaticExecutable() { if android.OtherModuleProviderOrDefault(ctx, module, cc.LinkableInfoKey).StaticExecutable { apex := a.ApexVariationName() exec := ctx.OtherModuleName(module) if isStaticExecutableAllowed(apex, exec) { Loading
cc/cc.go +11 −0 Original line number Diff line number Diff line Loading @@ -53,6 +53,13 @@ type CcObjectInfo struct { var CcObjectInfoProvider = blueprint.NewProvider[CcObjectInfo]() type LinkableInfo struct { // StaticExecutable returns true if this is a binary module with "static_executable: true". StaticExecutable bool } var LinkableInfoKey = blueprint.NewProvider[LinkableInfo]() func init() { RegisterCCBuildComponents(android.InitRegistrationContext) Loading Loading @@ -2119,6 +2126,10 @@ func (c *Module) GenerateAndroidBuildActions(actx android.ModuleContext) { android.SetProvider(ctx, CcObjectInfoProvider, ccObjectInfo) } android.SetProvider(ctx, LinkableInfoKey, LinkableInfo{ StaticExecutable: c.StaticExecutable(), }) c.setOutputFiles(ctx) if c.makeVarsInfo != nil { Loading
rust/rust.go +4 −0 Original line number Diff line number Diff line Loading @@ -1001,6 +1001,10 @@ func (mod *Module) GenerateAndroidBuildActions(actx android.ModuleContext) { ctx.Phony("rust", ctx.RustModule().OutputFile().Path()) } android.SetProvider(ctx, cc.LinkableInfoKey, cc.LinkableInfo{ StaticExecutable: mod.StaticExecutable(), }) mod.setOutputFiles(ctx) buildComplianceMetadataInfo(ctx, mod, deps) Loading