【问题标题】:Why does the Google Play Store reject my Nativescript APK for not being 64bit compliant?为什么 Google Play 商店拒绝我的 Nativescript APK 不兼容 64 位?
【发布时间】:2019-12-28 23:11:40
【问题描述】:

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

此版本不符合 Play 64 位要求

为什么?我有 64 位支持:

Google Play 中列出的原生平台

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

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

【问题讨论】:

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


    【解决方案1】:

    问题在于,由于 nativescript 提供 x86 二进制文件,Google Play 也需要 x86_64 二进制文件。可以通过添加此处指定的 ndk 块在 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

    【讨论】:

    • 非常感谢@Paul!
    猜你喜欢
    • 1970-01-01
    • 2019-12-20
    • 1970-01-01
    • 2019-12-26
    • 1970-01-01
    • 1970-01-01
    • 2017-02-27
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多