Android Studio:缺少剥离工具

Android Studio : Missing Strip Tool(Android Studio:缺少剥离工具)
本文介绍了Android Studio:缺少剥离工具的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在使用终端命令 gradle clean assembleRelease 构建我的 android studio 代码时不断收到此警告:

I am constantly getting this warning while building my android studio code using terminal command gradle clean assembleRelease:

由于缺少 ABI 'ARMEABI' 的剥离工具,无法剥离库 'lib.so'.按原样打包.

请帮助我解决此警告.

注意:我知道这不会影响我的应用程序的行为,但是我的 APK 太庞大了,这肯定会帮助我减小 APK 的大小.所以我需要解决这个问题.

Note: I know this won't affect the behaviour of my app, but my APK is too bulky and this will surely help me reduce APK size. So I need this resolved.

推荐答案

默认安装的 NDK 似乎没有剥离已构建支持 ARMEABI 的二进制文件所需的工具,因此最终打包了整个库,这大大增加了构建的文件大小.

The default installed NDK doesn't seem to have the tools required to strip binaries that have been built with ARMEABI support, so it ends up packaging the whole library, which increases the built file size substantially.

我发现从 Android Studio -> 工具 -> SDK 管理器 -> SDK 工具安装NDK(并排)"工具可以解决这个警告,还可以减少构建的 APK 大小,尤其是对于 React Native项目.

I've found that installing the "NDK (Side by side)" tool from Android Studio -> Tools -> SDK Manager -> SDK Tools takes care of this warning and also reduces the built APK size, especially for React Native projects.

这篇关于Android Studio:缺少剥离工具的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

相关文档推荐

How to target newer versions in .gitlab-ci.yml using auto devops (java 11 instead of 8 and Android 31 instead of 29)(如何在.gitlab-ci.yml中使用自动开发工具(Java 11而不是8,Android 31而不是29)瞄准较新的版本)
Android + coreLibraryDesugaring: which Java 11 APIs can I expect to work?(Android+core LibraryDesugering:我可以期待哪些Java 11API能够工作?)
How to render something in an if statement React Native(如何在If语句中呈现某些内容Reaction Native)
How can I sync two flatList scroll position in react native(如何在本机Reaction中同步两个平面列表滚动位置)
Using Firebase Firestore in offline only mode(在仅脱机模式下使用Firebase FiRestore)
Crash on Google Play Pre-Launch Report: java.lang.NoSuchMethodError(Google Play发布前崩溃报告:java.lang.NoSuchMethodError)