Log in or register to post comments

Persistent bug - Unable to convert classes to DEX format

September 20, 2016 - 1:47pm #1

Hello there. I'm encountering a bug that makes development impossible.

Here are the steps to reproduce:

- Using Unity 5.4.1 and JDK 7, create a new project

- It should build fine for android

- Import Vuforia package (vuforia-unity-6-0-117.unitypackage)

- Try to build it for android, get this error:

CommandInvokationFailure: Unable to convert classes into dex format.

C:/Program Files/Java/jdk1.7.0_79\bin\java.exe -Xmx2048M -Dcom.android.sdkmanager.toolsdir="C:/Users/danie/AppData/Local/Android/sdk\tools" -Dfile.encoding=UTF8 -jar "C:\Program Files\Unity\Editor\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar" -

stderr[

Exception in thread "main" java.lang.UnsupportedClassVersionError: com/android/dx/command/Main : Unsupported major.minor version 52.0

at java.lang.ClassLoader.defineClass1(Native Method)

at java.lang.ClassLoader.defineClass(ClassLoader.java:800)

at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)

at java.net.URLClassLoader.defineClass(URLClassLoader.java:449)

at java.net.URLClassLoader.access$100(URLClassLoader.java:71)

at java.net.URLClassLoader$1.run(URLClassLoader.java:361)

at java.net.URLClassLoader$1.run(URLClassLoader.java:355)

at java.security.AccessController.doPrivileged(Native Method)

at java.net.URLClassLoader.findClass(URLClassLoader.java:354)

at java.lang.ClassLoader.loadClass(ClassLoader.java:425)

at java.lang.ClassLoader.loadClass(ClassLoader.java:358)

at java.lang.Class.forName0(Native Method)

at java.lang.Class.forName(Class.java:274)

at SDKMain.main(SDKMain.java:127)

]

stdout[

]

UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)

UnityEditor.Android.AndroidSDKTools.RunCommandInternal (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)

UnityEditor.Android.AndroidSDKTools.RunCommandSafe (System.String javaExe, System.String sdkToolsDir, System.String[] sdkToolCommand, Int32 memoryMB, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)

UnityEditor.HostView:OnGUI()

Any idea on how to solve this? I've tried all google-findable solutions, but none seem to work. Is there an older version of anything that I can use?

Persistent bug - Unable to convert classes to DEX format

September 20, 2016 - 5:52pm #2
Log in or register to post comments