When you try to start the application, the following error appears:
Error:Execution failed for task ':app:transformClassesWithDexForDebug'. > com.android.build.transform.api.TransformException: com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command '/usr/lib/jvm/java-7-openjdk-amd64/bin/java'' finished with non-zero exit value 3
Here is my build.gradle application build.gradle :
buildscript { repositories { maven { url 'https://maven.fabric.io/public' } } dependencies { classpath 'io.fabric.tools:gradle:1.+' } } apply plugin: 'com.android.application' apply plugin: 'io.fabric' apply plugin: 'com.google.gms.google-services' android { compileSdkVersion 23 buildToolsVersion "23.0.1" defaultConfig { applicationId 'com.galleri5.android' multiDexEnabled true minSdkVersion 16 targetSdkVersion 23 versionCode 9 versionName "0.8.1" } buildTypes { release { minifyEnabled true proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } } repositories { mavenCentral() mavenLocal() jcenter() maven { url 'https://maven.fabric.io/public' } maven { url "https://jitpack.io" } } dependencies { compile fileTree(include: ['*.jar'], dir: 'libs') compile 'com.android.support:appcompat-v7:23.1.0' compile 'com.android.support:support-v4:23.1.0' compile 'com.squareup.picasso:picasso:2.5.2' compile 'com.android.support:design:23.1.0' compile 'com.facebook.android:facebook-android-sdk:4.3.0' compile 'com.squareup.okhttp:okhttp:2.4.0' compile 'com.squareup.okhttp:okhttp-urlconnection:2.4.0' compile 'com.android.support:recyclerview-v7:23.1.0' compile 'com.android.support:cardview-v7:23.1.0' compile 'com.squareup.retrofit:retrofit:1.9.0' compile 'com.jakewharton:butterknife:7.0.1' compile 'com.github.clans:fab:1.6.1' compile 'com.facebook.fresco:fresco:0.8.0+' compile 'com.facebook.fresco:imagepipeline-okhttp:0.8.0+' compile 'uk.co.chrisjenx:calligraphy:2.1.0' compile 'com.google.android.gms:play-services-analytics:8.1.0' compile 'com.commit451:PhotoView:1.2.4' compile 'com.github.liuguangqiang.swipeback:library: 1.0.2@aar ' compile('com.crashlytics.sdk.android:crashlytics: 2.5.2@aar ') { transitive = true; } }
And here is my build.gradle project build.gradle :
buildscript { repositories { jcenter() } dependencies { classpath 'com.android.tools.build:gradle:1.3.0' classpath 'com.google.gms:google-services:1.4.0-beta3'
Why does this error occur and how to solve it?
source share