I'm currently using Android Studio 3.2.1 and came across an issue I couldn't figure out. I've downloaded an mxparser.jar
file from mathparser.org to help me with proper equation output.
Click on the link, download the first option. I extracted the MathParser.org-mXparser-v.4.2.0/bin-only/jdk 1.10/MathParser.org-mXparser-v.4.2.0-jdk.1.10.jar
file, renamed it to mxparser.jar
and copied to the app\libs
folder in the project.
This is a brand new project, so everything else is as is. Here is the code in my app
file:
apply plugin: 'com.android.application'
android {
compileSdkVersion 27
defaultConfig {
applicationId "com.example.imad.equationtyper"
minSdkVersion 23
targetSdkVersion 27
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
implementation files('libs/mxparser.jar')
}
The project builds just fine, but crashes when I try to execute it and yields this error:
Caused by: com.android.builder.dexing.DexArchiveBuilderException: Failed to process (path to file)\app\libs\mxparser.jar
Does anyone know how I can solve this?