I am trying to build my app connecting my Pixel phone. I recently upgraded my phone to Android 8. I was able to build and open the app in my phone until the last upgrade, but after this upgrade, I get Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113] error.
Below is my gradle file. Can someone please tell me what is the issue ??
apply plugin: 'com.android.application'
android {
compileSdkVersion 26
buildToolsVersion '26.0.1'
defaultConfig {
applicationId "com.my.app.googlemaps"
minSdkVersion 16
targetSdkVersion 26
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
multiDexEnabled = true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
splits {
abi {
enable true
reset()
include 'x86', 'armeabi-v7a'
universalApk true
}
}
lintOptions {
abortOnError false
}
packagingOptions {
exclude 'META-INF/DEPENDENCIES'
exclude 'META-INF/NOTICE'
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE.txt'
exclude 'META-INF/NOTICE.txt'
}
productFlavors {
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
...
testCompile 'junit:junit:4.12'
}
apply plugin: 'com.google.gms.google-services'
It had the same problem, it worked after replacing an apache library (commons-io) with a different commons-io, that was from another bundle.
The problem occured to me after switching to a new development device (Pixel Phone w/ Android 8.0 Oreo).
In your case, you could stop using your local jars from the filesystem (compile fileTree(include: ['*.jar'], dir: 'libs')
) and use proper gradle dependencies from bintray (e.g.).
ERROR: Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113]
dependencies {
compile 'org.apache.directory.studio:org.apache.commons.io:2.4'
compile 'commons-cli:commons-cli:1.4'
}
build.gradle
with proper commons-io
artifacts:dependencies {
...
compile group: 'commons-io', name: 'commons-io', version: '2.5'
compile group: 'commons-cli', name: 'commons-cli', version: '1.4'
...
}
Ignore the different dependency notation, it doesn't matter
You define multiple target ABI, did you check, which one your device supports. Perhaps you have to add another one, to be compatible to your device ABI.
You can define them in the Application.mk
Also see:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With