Revert "mixed builds correctly reference stubs libs"
This reverts commit ca438e6b72
.
Reason for revert: ci post-submit failures in aosp-master-bazel of targets mixed-droid-clean and mixed-droid-incremental:
FAILED: ninja: 'out/target/product/generic_arm64/obj/SHARED_LIBRARIES/libc_intermediates/libc.so.toc', needed by 'out/target/product/generic_arm64/obj/EXECUTABLES/updater_intermediates/LINKED/updater', missing and no known rule to make it
12:21:27 ninja failed with: exit status 1
Change-Id: I081b499d23f2568cdf6227c4e3b0278164086b69
This commit is contained in:
committed by
Gerrit Code Review
parent
ca438e6b72
commit
1db4348734
@@ -931,17 +931,9 @@ func (handler *ccLibraryBazelHandler) generateSharedBazelBuildActions(ctx androi
|
||||
func (handler *ccLibraryBazelHandler) QueueBazelCall(ctx android.BaseModuleContext, label string) {
|
||||
bazelCtx := ctx.Config().BazelContext
|
||||
bazelCtx.QueueBazelRequest(label, cquery.GetCcInfo, android.GetConfigKeyApexVariant(ctx, GetApexConfigKey(ctx)))
|
||||
if v := handler.module.library.stubsVersion(); v != "" {
|
||||
stubsLabel := label + "_stub_libs-" + v
|
||||
bazelCtx.QueueBazelRequest(stubsLabel, cquery.GetCcInfo, android.GetConfigKeyApexVariant(ctx, GetApexConfigKey(ctx)))
|
||||
}
|
||||
}
|
||||
|
||||
func (handler *ccLibraryBazelHandler) ProcessBazelQueryResponse(ctx android.ModuleContext, label string) {
|
||||
if v := handler.module.library.stubsVersion(); v != "" {
|
||||
// if we are a stubs variant, just use the Bazel stubs target
|
||||
label = label + "_stub_libs-" + v
|
||||
}
|
||||
bazelCtx := ctx.Config().BazelContext
|
||||
ccInfo, err := bazelCtx.GetCcInfo(label, android.GetConfigKeyApexVariant(ctx, GetApexConfigKey(ctx)))
|
||||
if err != nil {
|
||||
@@ -970,9 +962,6 @@ func (handler *ccLibraryBazelHandler) ProcessBazelQueryResponse(ctx android.Modu
|
||||
}
|
||||
|
||||
handler.module.setAndroidMkVariablesFromCquery(ccInfo.CcAndroidMkInfo)
|
||||
|
||||
cctx := moduleContextFromAndroidModuleContext(ctx, handler.module)
|
||||
addStubDependencyProviders(cctx)
|
||||
}
|
||||
|
||||
func (library *libraryDecorator) setFlagExporterInfoFromCcInfo(ctx android.ModuleContext, ccInfo cquery.CcInfo) {
|
||||
@@ -1798,12 +1787,6 @@ func (library *libraryDecorator) linkShared(ctx ModuleContext,
|
||||
Target: ctx.Target(),
|
||||
})
|
||||
|
||||
addStubDependencyProviders(ctx)
|
||||
|
||||
return unstrippedOutputFile
|
||||
}
|
||||
|
||||
func addStubDependencyProviders(ctx ModuleContext) {
|
||||
stubs := ctx.GetDirectDepsWithTag(stubImplDepTag)
|
||||
if len(stubs) > 0 {
|
||||
var stubsInfo []SharedStubLibrary
|
||||
@@ -1818,9 +1801,12 @@ func addStubDependencyProviders(ctx ModuleContext) {
|
||||
}
|
||||
ctx.SetProvider(SharedLibraryStubsProvider, SharedLibraryStubsInfo{
|
||||
SharedStubLibraries: stubsInfo,
|
||||
IsLLNDK: ctx.IsLlndk(),
|
||||
|
||||
IsLLNDK: ctx.IsLlndk(),
|
||||
})
|
||||
}
|
||||
|
||||
return unstrippedOutputFile
|
||||
}
|
||||
|
||||
func (library *libraryDecorator) unstrippedOutputFilePath() android.Path {
|
||||
@@ -2662,7 +2648,7 @@ func LinkageMutator(mctx android.BottomUpMutatorContext) {
|
||||
// normalizeVersions modifies `versions` in place, so that each raw version
|
||||
// string becomes its normalized canonical form.
|
||||
// Validates that the versions in `versions` are specified in least to greatest order.
|
||||
func normalizeVersions(ctx android.BazelConversionPathContext, versions []string) {
|
||||
func normalizeVersions(ctx android.BaseModuleContext, versions []string) {
|
||||
var previous android.ApiLevel
|
||||
for i, v := range versions {
|
||||
ver, err := android.ApiLevelFromUser(ctx, v)
|
||||
|
Reference in New Issue
Block a user