Re: scomp fails trying javac

2009-09-18 Thread Jerry Brown
As you can see from the example, adding the -compiler parameter caused scomp to 
find javac.

C:\xmlbeans-2.4.0>scomp -compiler c:\Progra~1\Java\jdk1.6.0_05\bin\javac  -out 
tutorials\gettingstar
ted\lib\easypo.jar schemas\easypo.xsd
Time to build schema type system: 1.422 seconds
Time to generate code: 0.188 seconds
Time to compile code: 3.89 seconds
Compiled types to: tutorials\gettingstarted\lib\easypo.jar
C:\xmlbeans-2.4.0>

--
Thanks for everyone's help and ideas.
Jerry Brown

RE: scomp fails trying javac

2009-09-17 Thread Strong.James
If I'm not mistaken, the 'old error' you reference is not an XMLBeans
error at all. This appears to be an environment error with the
installation of Java. You have set the JAVA_HOME environment variable to
your \bin. Have you also added %JAVA_HOME%\bin to your
PATH before the JRE bin? With javac not being found in xmlbeans-2.4.0,
that makes me believe the PATH does not include your JDK. Can you run
javac yourself from a command line?

 

One other problem that I had experienced in the early Java days was the
default installation for Java on Windows was C:\Program Files\Java. The
space in the path was a problem with some paths not to mention the
additional length. I got into the habit of putting my JDK's and JRE's in
a location that was simpler and shorter, C:\java\jdk. The FAQ does
reference trying 8.3 (non-space) names for the Java installation.

 

From: Jerry Brown [mailto:jbr...@dvierow.com] 
Sent: Wednesday, September 16, 2009 8:25 PM
To: user@xmlbeans.apache.org
Subject: Re: scomp fails trying javac

 

 As I said this is an 'old' error.  A response is in the FAQ.  I looked
up where the error occured in the java code statements 373, 1154, and
231,  It is trying to compile but can't.  There is no javac program in
directory xmlbeans-2.4.0; it is in %JAVA_HOME%\bin where it is supposed
to be.  "the JRE's java is being found before the JDK's java" .. that is
what the 'old' error solution is asserting.   My %JAVA_HOME% is correct,
but apparently it is not being searched first.  Thanks for the previous
responses because they helped me to focus on the real problem. Any
ideas? 



-

C:\xmlbeans-2.4.0>scomp -out tutorials\gettingstarted\lib\easypo.jar
schemas\easypo.xsd
Time to build schema type system: 1.672 seconds
Time to generate code: 0.203 seconds
java.io.IOException: Cannot run program "C:\xmlbeans-2.4.0\javac":
CreateProcess error=2, The system
 cannot find the file specified
java.io.IOException: CreateProcess error=2, The system cannot find the
file specified
java.io.IOException: Cannot run program "C:\xmlbeans-2.4.0\javac":
CreateProcess error=2, The system
 cannot find the file specified
at java.lang.ProcessBuilder.start(Unknown Source)
at java.lang.Runtime.exec(Unknown Source)
at java.lang.Runtime.exec(Unknown Source)
at
org.apache.xmlbeans.impl.tool.CodeGenUtil.externalCompile(CodeGenUtil.ja
va:231)
at
org.apache.xmlbeans.impl.tool.SchemaCompiler.compile(SchemaCompiler.java
:1154)
at
org.apache.xmlbeans.impl.tool.SchemaCompiler.main(SchemaCompiler.java:37
3)
Caused by: java.io.IOException: CreateProcess error=2, The system cannot
find the file specified
at java.lang.ProcessImpl.create(Native Method)
at java.lang.ProcessImpl.(Unknown Source)
at java.lang.ProcessImpl.start(Unknown Source)
... 6 more
BUILD FAILED
C:\xmlbeans-2.4.0>





jerry brown

__
CONFIDENTIALITY NOTICE: This email from the State of California is for the sole 
use of the intended recipient and may contain confidential and privileged 
information. Any unauthorized review or use, including disclosure or 
distribution, is prohibited. If you are not the intended recipient, please 
contact the sender and destroy all copies of this email.


Re: scomp fails trying javac

2009-09-16 Thread Jerry Brown
 As I said this is an 'old' error.  A response is in the FAQ.  I looked up 
where the error occured in the java code statements 373, 1154, and 231,  It is 
trying to compile but can't.  There is no javac program in directory 
xmlbeans-2.4.0; it is in %JAVA_HOME%\bin where it is supposed to be.  "the 
JRE's java is being found before the JDK's java" .. that is what the 'old' 
error solution is asserting.   My %JAVA_HOME% is correct, but apparently it is 
not being searched first.  Thanks for the previous responses because they 
helped me to focus on the real problem. Any ideas? 
-
C:\xmlbeans-2.4.0>scomp -out tutorials\gettingstarted\lib\easypo.jar 
schemas\easypo.xsd
Time to build schema type system: 1.672 seconds
Time to generate code: 0.203 seconds
java.io.IOException: Cannot run program "C:\xmlbeans-2.4.0\javac": 
CreateProcess error=2, The system
 cannot find the file specified
java.io.IOException: CreateProcess error=2, The system cannot find the file 
specified
java.io.IOException: Cannot run program "C:\xmlbeans-2.4.0\javac": 
CreateProcess error=2, The system
 cannot find the file specified
at java.lang.ProcessBuilder.start(Unknown Source)
at java.lang.Runtime.exec(Unknown Source)
at java.lang.Runtime.exec(Unknown Source)
at 
org.apache.xmlbeans.impl.tool.CodeGenUtil.externalCompile(CodeGenUtil.java:231)
at 
org.apache.xmlbeans.impl.tool.SchemaCompiler.compile(SchemaCompiler.java:1154)
at 
org.apache.xmlbeans.impl.tool.SchemaCompiler.main(SchemaCompiler.java:373)
Caused by: java.io.IOException: CreateProcess error=2, The system cannot find 
the file specified
at java.lang.ProcessImpl.create(Native Method)
at java.lang.ProcessImpl.(Unknown Source)
at java.lang.ProcessImpl.start(Unknown Source)
... 6 more
BUILD FAILED
C:\xmlbeans-2.4.0>

jerry brown

RE: scomp fails trying javac

2009-09-14 Thread Strong.James
Jerry,

Not sure if you actually had a problem with scomp.cmd or are reading
documentation that indicates Java 1.5. Either way, if you have the JDK
installed, a PATH setting to include your JDK\bin and a JAVA_HOME
environment variable defined, you should not really have any problem
with scomp.cmd from a Java perspective. Nor should you need to modify
scomp.cmd to use XMLBeans. 

 

From: Jerry Brown [mailto:jbr...@dvierow.com] 
Sent: Saturday, September 12, 2009 5:14 AM
To: user@xmlbeans.apache.org
Subject: scomp fails trying javac

 

I am a newbie and this is an 'old' error.  But I have the JDK ahead of
the JRE on my PATH.  It is Java 1.6.  Do you really mean xmbeans 2.4.0
goes with Java 1.5, or does this mean Java 1.5+?  I have not yet tried
%JAVA_HOME%\bin\java (or javac?) in the scomp.cmd file.

 

Please give me your thoughts -- what would the revised script look like?
Do I really need to convert from Java 1.6 back to Java 1.5?

 

Jerry Brown

__
CONFIDENTIALITY NOTICE: This email from the State of California is for the sole 
use of the intended recipient and may contain confidential and privileged 
information. Any unauthorized review or use, including disclosure or 
distribution, is prohibited. If you are not the intended recipient, please 
contact the sender and destroy all copies of this email.


Re: scomp fails trying javac

2009-09-12 Thread Jacob Danner
I'm not sure of the question, but I've been using scomp with JDK 1.6
version 04, 10 and now 14 without problems for many months.
HTH,
-jacobd

On 9/12/09, Jerry  Brown  wrote:
> I am a newbie and this is an 'old' error.  But I have the JDK ahead of the
> JRE on my PATH.  It is Java 1.6.  Do you really mean xmbeans 2.4.0 goes with
> Java 1.5, or does this mean Java 1.5+?  I have not yet tried
> %JAVA_HOME%\bin\java (or javac?) in the scomp.cmd file.
>
> Please give me your thoughts -- what would the revised script look like?  Do
> I really need to convert from Java 1.6 back to Java 1.5?
>
> Jerry Brown

-
To unsubscribe, e-mail: user-unsubscr...@xmlbeans.apache.org
For additional commands, e-mail: user-h...@xmlbeans.apache.org



scomp fails trying javac

2009-09-12 Thread Jerry Brown
I am a newbie and this is an 'old' error.  But I have the JDK ahead of the JRE 
on my PATH.  It is Java 1.6.  Do you really mean xmbeans 2.4.0 goes with Java 
1.5, or does this mean Java 1.5+?  I have not yet tried %JAVA_HOME%\bin\java 
(or javac?) in the scomp.cmd file.

Please give me your thoughts -- what would the revised script look like?  Do I 
really need to convert from Java 1.6 back to Java 1.5?

Jerry Brown