Please help me out, thanks a lot
This page seems to indicate tha xjc.bat needs Java 1.5+ :
The last JAXB version that is compatible with java 1.4.2 is JAXB 1.0.6 . I've never heard of a version 1.5... Where did you get it?
Edit
This error message is not generated by jaxb but by the JVM. Looks like, the jvm thinks, the '-p' parameter is a jvm parameter. Here's another page where the same error message was generated at a simple java --version
call.
And another explanation for the error.
I faced the similar problem and I resolved it using the following approach. I specified Jdk1.5 as the JDK while installing jwsdp1.5. But the system had jdk1.4 also installed. So I created the following batch file:
set JAVA_HOME=D:\apps\BEA\Weblogic\jdk150_04
set ANT_HOME=H:\Sun\jwsdp-1.5\apache-ant
set JWSDP_HOME=H:\Sun\jwsdp-1.5
set PATH=%JAVA_HOME%\bin;%PATH%;
%JWSDP_HOME%\jaxb\bin\xjc -p package -dtd sample.dtd
This resolved the error. Alternatively we can remove the Jdk1.4 path in the PATH environment variable, in that case, we need to write the batch file.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.