Error while running an app in Android Studio

3

Imported an eclipse project for Android Studio (version 1.3.2), so far, but an error occurred when I tried to run the program:

  

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

Can anyone help me solve this problem?

    
asked by anonymous 01.04.2016 / 01:12

1 answer

0

Try the following:

In the gradle of your project within dependencies add:

dependencies {
 compile 'com.android.support:multidex:1.0.1'
}

within android does

android {
 dexOptions {
        preDexLibraries = false
        incremental true
        javaMaxHeapSize "4g"
    }

 defaultConfig {
        multiDexEnabled true
    }
}

Then resync the gradient followed by a clean to the project.

    
01.04.2016 / 11:09