0

I everyone, I have aproblem with my android studio proyect, I was developing 3 o 4 days ago, when I finished I update SDK and IDE. When I try to compile now not working, I doing all that I know but I can't to do works. I bring off to guild gradle, but when I try run my app this is error:

    Error:Execution failed for task ':app:dexDebug'.
> com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files\Java\jdk1.8.0_65\bin\java.exe'' finished with non-zero exit value 2

and this is my gradle:

apply plugin: 'com.android.application'

android {
    compileSdkVersion 23
    buildToolsVersion "23.0.0"
    useLibrary  'org.apache.http.legacy'
    packagingOptions {
        exclude 'META-INF/DEPENDENCIES'
        exclude 'META-INF/NOTICE'
        exclude 'META-INF/LICENSE'
    }


    defaultConfig {
        applicationId "com.paskuton.canyoners"
        minSdkVersion 13
        targetSdkVersion 21
        versionCode 16
        versionName "1.2"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:appcompat-v7:23.0.+'
    //compile "com.android.support:support-v13:23.0.+"
    compile 'com.android.support:support-v4:23.0.+'
    //compile 'com.android.support:design:21.0.1'
    //compile 'com.viewpagerindicator:library:2.4.1'
    compile 'com.github.JakeWharton:ViewPagerIndicator:2.4.1'
    compile 'com.google.android.gms:play-services:+'
    /*compile 'org.apache.commons:commons-collections4:4.0'
    compile 'org.apache.httpcomponents:httpclient:4.2.3'
    compile "org.apache.httpcomponents:httpmime:4.2.3"
    compile 'org.apache.httpcomponents:httpcore:4.4.1'*/
    compile ('org.apache.httpcomponents:httpmime:4.3'){
        exclude group: 'org.apache.httpcomponents', module: 'httpclient'
    }
    compile ('org.apache.httpcomponents:httpcore:4.4.1'){
        exclude group: 'org.apache.httpcomponents', module: 'httpclient'

    }
}

I have an app whith tabs with viewpagerindicator, httpcomponents with json comunication to server, action bar and push notifications.

Anyone know whats append?

thanks to all.

Toni Puche
  • 41
  • 1
  • 4
  • http://stackoverflow.com/questions/29756188/java-finished-with-non-zero-exit-value-2-android-gradle – Nouman Ghaffar Jan 26 '16 at 11:44
  • Add a required module of play-services lib will solve your issue. – Nouman Ghaffar Jan 26 '16 at 11:46
  • See this for batter understanding . https://developer.android.com/intl/ko/tools/building/multidex.html – Nouman Ghaffar Jan 26 '16 at 11:49
  • Thanks for your answer, and how I know what is my required module of play-services lib???, I think my problem is not multidex limit because last friday was work. thanks a lot for your answer Nouman Ghaffar – Toni Puche Jan 26 '16 at 15:36
  • Use gradlew assemble --info to get more info. – Gabriele Mariotti Jan 26 '16 at 18:55
  • Ok I done gradlew assemble --info and it is was response `code` * What went wrong: Execution failed for task ':app:dexDebug'. > com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files (x86)\Java\jre1.8.0_66\bin\java.exe'' finished with non-zero exi t value 2 * Try: Run with --stacktrace option to get the stack trace. Run with --debug option to get more log output. BUILD FAILED `code` Thanks @GabrieleMariotti – Toni Puche Jan 26 '16 at 21:42

0 Answers0