Merge "Remove special-casing of DCLA libraries" am: 557423d96e
am: fb9a124921
am: a337ffa1d0
am: ce175a4cc6
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/2638680 Change-Id: Ic206109fbc9bec16d7f7e430d26789ad08eeb048 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -176,8 +176,6 @@ type BazelContext interface {
|
|||||||
// (for example, that it is MixedBuildBuildable).
|
// (for example, that it is MixedBuildBuildable).
|
||||||
IsModuleNameAllowed(moduleName string, withinApex bool) bool
|
IsModuleNameAllowed(moduleName string, withinApex bool) bool
|
||||||
|
|
||||||
IsModuleDclaAllowed(moduleName string) bool
|
|
||||||
|
|
||||||
// Returns the bazel output base (the root directory for all bazel intermediate outputs).
|
// Returns the bazel output base (the root directory for all bazel intermediate outputs).
|
||||||
OutputBase() string
|
OutputBase() string
|
||||||
|
|
||||||
@@ -316,10 +314,6 @@ func (m MockBazelContext) IsModuleNameAllowed(_ string, _ bool) bool {
|
|||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
func (m MockBazelContext) IsModuleDclaAllowed(_ string) bool {
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
|
|
||||||
func (m MockBazelContext) OutputBase() string { return m.OutputBaseDir }
|
func (m MockBazelContext) OutputBase() string { return m.OutputBaseDir }
|
||||||
|
|
||||||
func (m MockBazelContext) BuildStatementsToRegister() []*bazel.BuildStatement {
|
func (m MockBazelContext) BuildStatementsToRegister() []*bazel.BuildStatement {
|
||||||
@@ -461,10 +455,6 @@ func (n noopBazelContext) IsModuleNameAllowed(_ string, _ bool) bool {
|
|||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
func (n noopBazelContext) IsModuleDclaAllowed(_ string) bool {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
func (m noopBazelContext) BuildStatementsToRegister() []*bazel.BuildStatement {
|
func (m noopBazelContext) BuildStatementsToRegister() []*bazel.BuildStatement {
|
||||||
return []*bazel.BuildStatement{}
|
return []*bazel.BuildStatement{}
|
||||||
}
|
}
|
||||||
@@ -598,17 +588,13 @@ func (context *mixedBuildBazelContext) IsModuleNameAllowed(moduleName string, wi
|
|||||||
if context.bazelEnabledModules[moduleName] {
|
if context.bazelEnabledModules[moduleName] {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
if withinApex && context.IsModuleDclaAllowed(moduleName) {
|
if withinApex && context.bazelDclaEnabledModules[moduleName] {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
func (context *mixedBuildBazelContext) IsModuleDclaAllowed(moduleName string) bool {
|
|
||||||
return context.bazelDclaEnabledModules[moduleName]
|
|
||||||
}
|
|
||||||
|
|
||||||
func pwdPrefix() string {
|
func pwdPrefix() string {
|
||||||
// Darwin doesn't have /proc
|
// Darwin doesn't have /proc
|
||||||
if runtime.GOOS != "darwin" {
|
if runtime.GOOS != "darwin" {
|
||||||
|
3
cc/cc.go
3
cc/cc.go
@@ -1997,9 +1997,6 @@ func allEnabledSanitizersSupportedByBazel(ctx android.BaseModuleContext, c *Modu
|
|||||||
func GetApexConfigKey(ctx android.BaseModuleContext) *android.ApexConfigKey {
|
func GetApexConfigKey(ctx android.BaseModuleContext) *android.ApexConfigKey {
|
||||||
apexInfo := ctx.Provider(android.ApexInfoProvider).(android.ApexInfo)
|
apexInfo := ctx.Provider(android.ApexInfoProvider).(android.ApexInfo)
|
||||||
if !apexInfo.IsForPlatform() {
|
if !apexInfo.IsForPlatform() {
|
||||||
if !ctx.Config().BazelContext.IsModuleDclaAllowed(ctx.Module().Name()) {
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
apexKey := android.ApexConfigKey{
|
apexKey := android.ApexConfigKey{
|
||||||
WithinApex: true,
|
WithinApex: true,
|
||||||
ApexSdkVersion: findApexSdkVersion(ctx, apexInfo).String(),
|
ApexSdkVersion: findApexSdkVersion(ctx, apexInfo).String(),
|
||||||
|
Reference in New Issue
Block a user