繁体   English   中英

在 Play 商店发布应用程序时如何处理 .so 文件?

[英]How to deal with the .so file while publishing the app on the Play store?

我创建了应用程序的发布版本,它在 AS3.5.1 中具有 java 和 cpp 代码,其默认 gradle。 上传应用程序后,我遇到了按照 Google 说明上传本机代码 zip 文件的问题。 (我的文件结构与 Google 页面上描述的文件结构不匹配 - https://developer.android.com/studio/build/shrink-code#native-crash-support ,我没有名为 Universal 的文件夹,然后在以 zip 格式上传 obj 文件夹,Google 只会通知这些文件无效 -path: app\\build\\intermediates\\cmake\\release\\obj)。 我收到错误,因为The native debug symbols contain an invalid directory obj. Only Android ABIs are supported The native debug symbols contain an invalid directory obj. Only Android ABIs are supported 可能是我无法理解 ABI(应用程序二进制接口)。

将目标文件上传到 Google Play 时,我遇到了同样的问题。 事实证明,问题在于解压缩时 zip 文件层次结构不是 Google Play 处理器所期望的。 您需要确保支持的体系结构的目录都在 zip 文件的根目录下。 此外,您还需要确保 zip 文件中没有其他隐藏的系统文件(例如,如果在 Mac 上执行此操作,则为 .DS_Store)。 在我的 Mac 上:导航到所需的 obj 目录(对我来说是 app/build/intermediates/cmake/release/obj)并运行

zip -r symbols.zip x86* arm*

这将包括 32 位和 64 位 x86 和 arm 架构,这是我在撰写本文时所需要的。 然后上传symbols.zip 文件,它应该可以工作。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM