Unrecognized option: -compiler

Jemru picture Jemru · Nov 19, 2013 · Viewed 16.8k times · Source

I'm trying to run XMLBeans with the following command:

scomp -compiler "C:\Program Files\Java\jdk1.5.0_14\bin\javac.exe" -cp "C:\libraries*" -out JarA.jar FileA.xsd

However I'm getting this error below:

Unrecognized option: -compiler
Could not create the Java virtual machine.

Can you please help me if there's anything I need to setup?

java -version

java version "1.6.0_13"
Java(TM) SE Runtime Environment (build 1.6.0_13-b03)
Java HotSpot(TM) Client VM (build 11.3-b02, mixed mode)

Answer

Artem Zankovich picture Artem Zankovich · Nov 19, 2013

Make sure JAVA_HOME is set up pointing to a JDK installation (JRE is not enough).