2

I am relatively new to app development, and I am attempting to test my app *Just a simple hello world to get started" on the AVD emulator. However, when the emulator is loading, I get the exact error: "Error:Execution failed for task ':app:transformClassesWithDexForDebug'.

com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files\Java\jdk1.7.0_79\bin\java.exe'' finished with non-zero exit value 1"

When the emulator launches, I cant find my app anywhere on the screen, and I believe it is due to this error which occurs during the loading process. Can anyone help me please

Infinite Loops
  • 671
  • 3
  • 11
  • 23
arsenalftw067
  • 241
  • 1
  • 4
  • 16
  • Did you properly configure your JAVA_HOME and JRE_HOME? – Infinite Loops Jul 01 '17 at 23:42
  • Thanks for replying. I am not aware of what JAVA_HOME and JRE_HOME is, where can I find these files? Should I just reinstall ADK? I heard somewhere that this could be fixed my ADK directory is in the same directory as the SDK – arsenalftw067 Jul 01 '17 at 23:45
  • please look out for Java JDK setup. There's something about Variables Environment setting. Or you can look up back to Android Studio setup. – Infinite Loops Jul 01 '17 at 23:47
  • I'm confused about your latest comment on what I should do. I found the java.exe file, ran it and the terminal window poped up for a second and terminated. Is this supposed to happen? Should I reinstall android development studio? – arsenalftw067 Jul 01 '17 at 23:50
  • Go to your PC Properties - Advanced system settings - Environment Variables. Look at the first box, have you set the JAVA_HOME value? If no, then hit New put the Variable JAVA_HOME and set the value to the directory where you've installed jdk. In my case it's in C:\Program Files\Java\jdk1.8.0_77 – Infinite Loops Jul 01 '17 at 23:57
  • I did exactly that, however I am receiving the same error:/ – arsenalftw067 Jul 02 '17 at 00:18
  • These might help: https://stackoverflow.com/questions/29045129/android-java-exe-finished-with-non-zero-exit-value-1 , https://stackoverflow.com/questions/34766206/error-grandle-build-c-program-files-java-jdk1-7-0-79-bin-java-exe-finished-wi – Infinite Loops Jul 02 '17 at 00:25
  • I am getting the above exception when I am adding "minifyEnabled true" in build.gradle app level, when I set "minifyEnabled false" it is working fine.but when I set to "minifyEnabled true" not working both in debug and release modes, giving above exception.Here's the link https://stackoverflow.com/questions/51720018/obfuscation-minifyenabled-true-not-working-in-debug-and-release – Naveen Aug 08 '18 at 11:23

0 Answers0