0

Hi all: I am trying to bring a program from Eclipse to Android Studio. Doing so I've encountered many errors which I have solved using the help of Stackoverflow and my intuition. However, I havent been able to solve this issue as I see no duplicates in my program as links have stated to look for and i have no idea where to look.

The complete error is

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

Research and reading has brought me to this link Java finished with non-zero exit value 2 - Android Gradle

However nothing worked, not even multidex true.

would like if anyone could let me know if my situation is somewhat unique.

Project Gradle

    apply plugin: 'com.android.application'

    android {
        compileSdkVersion 23
        buildToolsVersion "23.0.0"




        defaultConfig {
            applicationId "com.iziss.tourismapp"
            minSdkVersion 15
            targetSdkVersion 23


        }
        configurations {
            all*.exclude group: 'com.android.support', module: 'support-v7'

        }

        buildTypes {
            release {
                minifyEnabled false
                proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
            }
        }
    }

    dependencies {
        compile 'com.android.support:appcompat-v7:23.0.0'
        compile project(':facebook')
        compile 'com.google.android.gms:play-services:7.5.0'
     //   compile files('libs/httpclient-4.0.1.jar')
     //   compile files('libs/httpmime-4.2.2.jar')
      //  compile files('libs/signpost-commonshttp4-1.2.1.1.jar')
     //   compile files('libs/signpost-core-1.2.1.1.jar')
    //    compile files('libs/twitter4j-core-4.0.4.jar')
   //     compile files('libs/universal-image-loader-1.2.1.jar')




        compile "org.apache.httpcomponents:httpcore:4.3.2"


        compile fileTree(dir: 'libs', include: ['*.jar'])
    }

Facebook Gradle

apply plugin: 'com.android.library'

android {
    compileSdkVersion 23
    buildToolsVersion "23.0.0"

    defaultConfig {
        minSdkVersion 9
        targetSdkVersion 23
        compileOptions {
            sourceCompatibility JavaVersion.VERSION_1_7
            targetCompatibility JavaVersion.VERSION_1_7
        }
    }

    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
        }
    }
}

dependencies {
    compile 'com.android.support:appcompat-v7:23.1.1'
 //   compile files('libs/bolts-android-1.1.2.jar')
    compile 'com.android.support:support-annotations:+'

    compile fileTree(dir: 'libs', include: ['*.jar'])
}
Community
  • 1
  • 1
Niana
  • 1,057
  • 2
  • 14
  • 42
  • see if the app runs in lollipop and not in any versions lower, if that is the case then you have to enable multidex in your android app. Note: only declaring multidex as true does not enables multidex – Nilabja Jan 14 '16 at 04:41
  • @Nilabja MinSDK version is defined as 15 so it should run lower than lollipop right? I set Multidex to true but that opened a whole new can of errors about not being able to unzip. I wanted to explore all the other options before I headed down that road of trying to fix errors I dont understand. – Niana Jan 14 '16 at 04:54
  • multidex is only applicable for devices with dalvik runtime, i.e. devices with os lower than lollipop, L and higher uses ART runtime, so if your app runs on L or higher but not on L below you can be sure that it is multidex related – Nilabja Jan 14 '16 at 06:08

0 Answers0