DexGuard Java.io.IOException: The Same Input Jar
I'm facing this issue when using dexguard > Task :app:dexguardStaging FAILED The TaskInternal.execute() method has been deprecated and is scheduled to be removed in Gradle 5.0.
Solution 1:
Please try below code & let me know if it works for you
Do changes in your gradle like this
apply plugin: 'com.android.application'
android {
compileSdkVersion 26
buildToolsVersion '26.0.2'
defaultConfig {
applicationId "com.example.testapp"
minSdkVersion 16
targetSdkVersion 26
versionCode 1
versionName "1.1"
multiDexEnabled true // put this line in your gradle
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
//put below code in your gradle
dexOptions {
preDexLibraries = false
javaMaxHeapSize "4g"
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:multidex:1.0.2' //put this dependencies in your gradle
// Rest of your dependencies
}
& also changes in your application file.
public class TestApplication extends MultiDexApplication {
@Override
public void onCreate() {
super.onCreate();
}
}
&
In manifest file >> in application tag >> mention below line
android:name=".TestApplication"
Hope this will work for you & if it is work then let me know.
Post a Comment for "DexGuard Java.io.IOException: The Same Input Jar"