伐柯伐柯*其則不遠*我覬之子*籩豆有踐

27 , 6月2018

安装apk到模拟器失败Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113]的另一种可能原因

大包安装APK到模拟器失败Error: ADB exited with exit code 1
Performing Streamed Install
adb: failed to install outputs\apk\app.apk: Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113] Install failed

今天在打包出apk想要去模拟器安装并测试的时候出现异常:
 D:\Development\Code\xxx>flutter install
 Initializing gradle…                                              0.9s
 Resolving dependencies…                                           3.4s
 Installing app.apk to Android SDK built for x86…
 Installing build\app\outputs\apk\app.apk…                         0.2s
 Error: ADB exited with exit code 1
 Performing Streamed Install
 adb: failed to install D:\Development\Code\xxx\build\app\outputs\apk\app.apk: Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113]
 Install failed 

网上找的资料大家都说在gradle配置里面加入:

splits {
         abi {
             enable true
             reset()
             include 'x86', 'x86_64', 'armeabi-v7a'
             universalApk true
         }
     }
增加对对应平台的ABI支持。
可是我之前打包都是好的,应该不是这个问题。

后来一想,是不是我之前安装过的原因?
于是上拉果然发现了有这个包。卸载之后再安装,成功了。。。
 
 D:\Development\Code\xxx>flutter install
 Initializing gradle…                                              1.0s
 Resolving dependencies…                                           4.1s
 Installing app.apk to Android SDK built for x86…
 Uninstalling old version…
 Installing build\app\outputs\apk\app.apk…                         1.8s

发表回复

您的电子邮箱地址不会被公开。 必填项已用*标注

© 2011 - 2024 laijim.com