diff --git a/cc/bp2build.go b/cc/bp2build.go index c42a7e8ba..33eafe3e7 100644 --- a/cc/bp2build.go +++ b/cc/bp2build.go @@ -1357,6 +1357,9 @@ func setStubsForDynamicDeps(ctx android.BazelConversionPathContext, axis bazel.C // that tests of an apex library gets its implementation and not stubs. // TODO (b/280343104): Discuss if we can drop this special handling for platform variants. sameApiDomain = availableToSameApexes(apexAvailable, dep.(*Module).ApexAvailable()) + if linkable, ok := ctx.Module().(LinkableInterface); ok && linkable.Bootstrap() { + sameApiDomain = true + } } else { sameApiDomain = android.InList(apiDomain, dep.(*Module).ApexAvailable()) }