android - 为什么 Google Play 商店因不符合 64 位要求而拒绝我的 Nativescript APK?

标签 android google-play 64-bit release 32bit-64bit

Google Play 现在有关于 64 位兼容性的新规则 - 所有具有二进制文件的 APK 也需要提供 64 位版本。我尝试提交我的 NativeScript 应用程序,该应用程序具有 64 位二进制文​​件,但出现警告...

此版本不符合 Play 64 位要求

https://developer.android.com/distribute/best-practices/images/develop/64bit/console_warning.png

为什么?我有 64 位支持:

Google Play 中列出的原生平台

原生平台 arm64-v8a、armeabi-v7a、x86

Google 甚至从我的 aab 生成 64 位 apk。

最佳答案

问题是,由于nativescript提供x86二进制文件,Google Play也需要x86_64二进制文件。可以通过添加此处指定的 ndk block 来在 app.gradle 中禁用生成这些二进制文件 - 因此只会生成 arm 二进制文件。

android {
  defaultConfig {
    applicationId 'your.application.id'
    generatedDensities = []
    ndk {
      abiFilters.clear()
      abiFilters.addAll(['armeabi-v7a','arm64-v8a'])
    }
  }
  aaptOptions {
    additionalParameters "--no-version-vectors"
  }
}

然后,在构建发布 apk 或 aab 时,将不会生成 x86 包,并且 google 不会提示缺少 64 位内容。

Related Nativescript Github issue

关于android - 为什么 Google Play 商店因不符合 64 位要求而拒绝我的 Nativescript APK?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57629469/

相关文章:

c# - Prexisiting dlls (.NET 4 framework) 问题与 mono for android

android - ADT 插件没有出现在 Eclipse 中

java - 仅使用 Java 从 apk 中提取 AndroidManifest.xml 文件

安卓插件

android - 为什么我的应用程序的原始版本在更新后仍继续在 Google Play 上分发?

Android堆栈不清楚

android - 获取 "' 安卓 :icon' attribute: attribute is not a string value” error while uploading an APK to the play store

python - 如何进一步调试 (win7 64bit, py2.7) 上的 SendKeysCtypes?

x86 - 引用 x86 相关 CPU 的 32 位和 64 位版本程序的最正确方法是什么?

.NET 垃圾收集器和 x64 虚拟内存