diff options
Diffstat (limited to 'java')
| -rw-r--r-- | java/dexpreopt.go | 4 | ||||
| -rw-r--r-- | java/dexpreopt_bootjars.go | 6 |
2 files changed, 7 insertions, 3 deletions
diff --git a/java/dexpreopt.go b/java/dexpreopt.go index a7938c82c..08fd06ed6 100644 --- a/java/dexpreopt.go +++ b/java/dexpreopt.go @@ -111,7 +111,9 @@ func (d *dexpreopter) dexpreopt(ctx android.ModuleContext, dexJarFile android.Mo if len(archs) == 0 { // assume this is a java library, dexpreopt for all arches for now for _, target := range ctx.Config().Targets[android.Android] { - archs = append(archs, target.Arch.ArchType) + if target.NativeBridge == android.NativeBridgeDisabled { + archs = append(archs, target.Arch.ArchType) + } } if inList(ctx.ModuleName(), global.SystemServerJars) && !d.isSDKLibrary { // If the module is not an SDK library and it's a system server jar, only preopt the primary arch. diff --git a/java/dexpreopt_bootjars.go b/java/dexpreopt_bootjars.go index cb2ea9f0a..092a1332e 100644 --- a/java/dexpreopt_bootjars.go +++ b/java/dexpreopt_bootjars.go @@ -197,8 +197,10 @@ func buildBootImage(ctx android.SingletonContext, config bootImageConfig) *bootI } for _, target := range targets { - files := buildBootImageRuleForArch(ctx, image, target.Arch.ArchType, profile, missingDeps) - allFiles = append(allFiles, files.Paths()...) + if target.NativeBridge == android.NativeBridgeDisabled { + files := buildBootImageRuleForArch(ctx, image, target.Arch.ArchType, profile, missingDeps) + allFiles = append(allFiles, files.Paths()...) + } } } |