bp2build: convert paths/module refs to Bazel label
This currently expands all globs, still need to support converting glob syntax. Test: go build_conversion_test Test: GENERATE_BAZEL_FILES=true m nothing Test: m nothing Bug: 165114590 Change-Id: If7b26e8e663d17566fad9614ca87a8da1f095284
This commit is contained in:
8
cc/cc.go
8
cc/cc.go
@@ -1741,7 +1741,7 @@ func (c *Module) GenerateAndroidBuildActions(actx android.ModuleContext) {
|
||||
|
||||
func (c *Module) toolchain(ctx android.BaseModuleContext) config.Toolchain {
|
||||
if c.cachedToolchain == nil {
|
||||
c.cachedToolchain = config.FindToolchain(ctx.Os(), ctx.Arch())
|
||||
c.cachedToolchain = config.FindToolchainWithContext(ctx)
|
||||
}
|
||||
return c.cachedToolchain
|
||||
}
|
||||
@@ -1833,6 +1833,12 @@ func (c *Module) deps(ctx DepsContext) Deps {
|
||||
deps.HeaderLibs = android.LastUniqueStrings(deps.HeaderLibs)
|
||||
deps.RuntimeLibs = android.LastUniqueStrings(deps.RuntimeLibs)
|
||||
|
||||
// In Bazel conversion mode, we dependency and build validations will occur in Bazel, so there is
|
||||
// no need to do so in Soong.
|
||||
if ctx.BazelConversionMode() {
|
||||
return deps
|
||||
}
|
||||
|
||||
for _, lib := range deps.ReexportSharedLibHeaders {
|
||||
if !inList(lib, deps.SharedLibs) {
|
||||
ctx.PropertyErrorf("export_shared_lib_headers", "Shared library not in shared_libs: '%s'", lib)
|
||||
|
Reference in New Issue
Block a user