Domanda

I am facing issues with Codenameone after recent JDK upgrade. Tried to resolve it in multiple ways but no luck.

jar:
 [echo] Compile is forcing compliance to the supported API's/features for maximum device       compatibility. This allows smaller
 [echo]             code size and wider device support
 [copy] Copying 2 files to C:\Appstek\Workspace\AppsMobile\build\tmp
[javac] C:\Appstek\Workspace\AppsMobile\build.xml:130: warning: 'includeantruntime' was  not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
[javac] Compiling 13 source files to C:\Appstek\Workspace\AppsMobile\build\tmp
[javac] Error: Could not find or load main class com.sun.tools.javac.Main

BUILD FAILED
C:\Appstek\Workspace\AppsMobile\build.xml:130: Compile failed; see the compiler error output for details.

Total time: 1 second
È stato utile?

Soluzione

I'm guessing you are using Eclipse and that your JAVA_HOME environment variable is pointing to a JRE installed on your machine instead of to a JDK. Make sure the java/javac commands of the JDK are first in your OS path (before the JRE commands) and make sure JAVA_HOME points at the JDK directory then run Eclipse.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top