Merge "Do not add bootstrap libs as providing from apex" am: 570147469f am: 40f770951d am: 557b3d228a

Change-Id: I076542ad1f1c42ea01cf6fb46515764d17d1ab19
This commit is contained in:
Automerger Merge Worker 2020-02-07 08:20:49 +00:00
commit b86c8583bf
1 changed files with 5 additions and 4 deletions

View File

@ -2059,11 +2059,12 @@ func (a *apexBundle) GenerateAndroidBuildActions(ctx android.ModuleContext) {
}
switch depTag {
case sharedLibTag:
if cc, ok := child.(*cc.Module); ok {
if cc.HasStubsVariants() {
provideNativeLibs = append(provideNativeLibs, cc.OutputFile().Path().Base())
if c, ok := child.(*cc.Module); ok {
// bootstrap bionic libs are treated as provided by system
if c.HasStubsVariants() && !cc.InstallToBootstrap(c.BaseModuleName(), ctx.Config()) {
provideNativeLibs = append(provideNativeLibs, c.OutputFile().Path().Base())
}
filesInfo = append(filesInfo, apexFileForNativeLibrary(ctx, cc, handleSpecialLibs))
filesInfo = append(filesInfo, apexFileForNativeLibrary(ctx, c, handleSpecialLibs))
return true // track transitive dependencies
} else {
ctx.PropertyErrorf("native_shared_libs", "%q is not a cc_library or cc_library_shared module", depName)