Loading android/module.go +10 −14 Original line number Diff line number Diff line Loading @@ -848,10 +848,6 @@ type ModuleBase struct { // Merged Aconfig files for all transitive deps. aconfigFilePaths Paths // moduleInfoJSON can be filled out by GenerateAndroidBuildActions to write a JSON file that will // be included in the final module-info.json produced by Make. moduleInfoJSON *ModuleInfoJSON // complianceMetadataInfo is for different module types to dump metadata. // See android.ModuleContext interface. complianceMetadataInfo *ComplianceMetadataInfo Loading Loading @@ -1992,7 +1988,7 @@ func (m *ModuleBase) GenerateBuildActions(blueprintCtx blueprint.ModuleContext) SetProvider(ctx, InstallFilesProvider, installFiles) buildLicenseMetadata(ctx, ctx.licenseMetadataFile) if m.moduleInfoJSON != nil { if ctx.moduleInfoJSON != nil { var installed InstallPaths installed = append(installed, ctx.katiInstalls.InstallPaths()...) installed = append(installed, ctx.katiSymlinks.InstallPaths()...) Loading @@ -2012,28 +2008,28 @@ func (m *ModuleBase) GenerateBuildActions(blueprintCtx blueprint.ModuleContext) data = append(data, d.ToRelativeInstallPath()) } if m.moduleInfoJSON.Uninstallable { if ctx.moduleInfoJSON.Uninstallable { installedStrings = nil if len(m.moduleInfoJSON.CompatibilitySuites) == 1 && m.moduleInfoJSON.CompatibilitySuites[0] == "null-suite" { m.moduleInfoJSON.CompatibilitySuites = nil m.moduleInfoJSON.TestConfig = nil m.moduleInfoJSON.AutoTestConfig = nil if len(ctx.moduleInfoJSON.CompatibilitySuites) == 1 && ctx.moduleInfoJSON.CompatibilitySuites[0] == "null-suite" { ctx.moduleInfoJSON.CompatibilitySuites = nil ctx.moduleInfoJSON.TestConfig = nil ctx.moduleInfoJSON.AutoTestConfig = nil data = nil } } m.moduleInfoJSON.core = CoreModuleInfoJSON{ RegisterName: m.moduleInfoRegisterName(ctx, m.moduleInfoJSON.SubName), ctx.moduleInfoJSON.core = CoreModuleInfoJSON{ RegisterName: m.moduleInfoRegisterName(ctx, ctx.moduleInfoJSON.SubName), Path: []string{ctx.ModuleDir()}, Installed: installedStrings, ModuleName: m.BaseModuleName() + m.moduleInfoJSON.SubName, ModuleName: m.BaseModuleName() + ctx.moduleInfoJSON.SubName, SupportedVariants: []string{m.moduleInfoVariant(ctx)}, TargetDependencies: targetRequired, HostDependencies: hostRequired, Data: data, Required: m.RequiredModuleNames(ctx), } SetProvider(ctx, ModuleInfoJSONProvider, m.moduleInfoJSON) SetProvider(ctx, ModuleInfoJSONProvider, ctx.moduleInfoJSON) } m.buildParams = ctx.buildParams Loading android/module_context.go +6 −2 Original line number Diff line number Diff line Loading @@ -266,6 +266,10 @@ type moduleContext struct { buildParams []BuildParams ruleParams map[blueprint.Rule]blueprint.RuleParams variables map[string]string // moduleInfoJSON can be filled out by GenerateAndroidBuildActions to write a JSON file that will // be included in the final module-info.json produced by Make. moduleInfoJSON *ModuleInfoJSON } var _ ModuleContext = &moduleContext{} Loading Loading @@ -729,11 +733,11 @@ func (m *moduleContext) LicenseMetadataFile() Path { } func (m *moduleContext) ModuleInfoJSON() *ModuleInfoJSON { if moduleInfoJSON := m.module.base().moduleInfoJSON; moduleInfoJSON != nil { if moduleInfoJSON := m.moduleInfoJSON; moduleInfoJSON != nil { return moduleInfoJSON } moduleInfoJSON := &ModuleInfoJSON{} m.module.base().moduleInfoJSON = moduleInfoJSON m.moduleInfoJSON = moduleInfoJSON return moduleInfoJSON } Loading Loading
android/module.go +10 −14 Original line number Diff line number Diff line Loading @@ -848,10 +848,6 @@ type ModuleBase struct { // Merged Aconfig files for all transitive deps. aconfigFilePaths Paths // moduleInfoJSON can be filled out by GenerateAndroidBuildActions to write a JSON file that will // be included in the final module-info.json produced by Make. moduleInfoJSON *ModuleInfoJSON // complianceMetadataInfo is for different module types to dump metadata. // See android.ModuleContext interface. complianceMetadataInfo *ComplianceMetadataInfo Loading Loading @@ -1992,7 +1988,7 @@ func (m *ModuleBase) GenerateBuildActions(blueprintCtx blueprint.ModuleContext) SetProvider(ctx, InstallFilesProvider, installFiles) buildLicenseMetadata(ctx, ctx.licenseMetadataFile) if m.moduleInfoJSON != nil { if ctx.moduleInfoJSON != nil { var installed InstallPaths installed = append(installed, ctx.katiInstalls.InstallPaths()...) installed = append(installed, ctx.katiSymlinks.InstallPaths()...) Loading @@ -2012,28 +2008,28 @@ func (m *ModuleBase) GenerateBuildActions(blueprintCtx blueprint.ModuleContext) data = append(data, d.ToRelativeInstallPath()) } if m.moduleInfoJSON.Uninstallable { if ctx.moduleInfoJSON.Uninstallable { installedStrings = nil if len(m.moduleInfoJSON.CompatibilitySuites) == 1 && m.moduleInfoJSON.CompatibilitySuites[0] == "null-suite" { m.moduleInfoJSON.CompatibilitySuites = nil m.moduleInfoJSON.TestConfig = nil m.moduleInfoJSON.AutoTestConfig = nil if len(ctx.moduleInfoJSON.CompatibilitySuites) == 1 && ctx.moduleInfoJSON.CompatibilitySuites[0] == "null-suite" { ctx.moduleInfoJSON.CompatibilitySuites = nil ctx.moduleInfoJSON.TestConfig = nil ctx.moduleInfoJSON.AutoTestConfig = nil data = nil } } m.moduleInfoJSON.core = CoreModuleInfoJSON{ RegisterName: m.moduleInfoRegisterName(ctx, m.moduleInfoJSON.SubName), ctx.moduleInfoJSON.core = CoreModuleInfoJSON{ RegisterName: m.moduleInfoRegisterName(ctx, ctx.moduleInfoJSON.SubName), Path: []string{ctx.ModuleDir()}, Installed: installedStrings, ModuleName: m.BaseModuleName() + m.moduleInfoJSON.SubName, ModuleName: m.BaseModuleName() + ctx.moduleInfoJSON.SubName, SupportedVariants: []string{m.moduleInfoVariant(ctx)}, TargetDependencies: targetRequired, HostDependencies: hostRequired, Data: data, Required: m.RequiredModuleNames(ctx), } SetProvider(ctx, ModuleInfoJSONProvider, m.moduleInfoJSON) SetProvider(ctx, ModuleInfoJSONProvider, ctx.moduleInfoJSON) } m.buildParams = ctx.buildParams Loading
android/module_context.go +6 −2 Original line number Diff line number Diff line Loading @@ -266,6 +266,10 @@ type moduleContext struct { buildParams []BuildParams ruleParams map[blueprint.Rule]blueprint.RuleParams variables map[string]string // moduleInfoJSON can be filled out by GenerateAndroidBuildActions to write a JSON file that will // be included in the final module-info.json produced by Make. moduleInfoJSON *ModuleInfoJSON } var _ ModuleContext = &moduleContext{} Loading Loading @@ -729,11 +733,11 @@ func (m *moduleContext) LicenseMetadataFile() Path { } func (m *moduleContext) ModuleInfoJSON() *ModuleInfoJSON { if moduleInfoJSON := m.module.base().moduleInfoJSON; moduleInfoJSON != nil { if moduleInfoJSON := m.moduleInfoJSON; moduleInfoJSON != nil { return moduleInfoJSON } moduleInfoJSON := &ModuleInfoJSON{} m.module.base().moduleInfoJSON = moduleInfoJSON m.moduleInfoJSON = moduleInfoJSON return moduleInfoJSON } Loading