How can i use a java compiler that differs from installed JDK on Win2K?
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Markus_Keim
Posted On:   Friday, August 29, 2003 08:44 AM

Hello @ all, I'm using Ant 1.5.3 and JDK 1.4.0 on Win2K. I've written an Ant skript to compile a Java project and build a jar-archive, works well so far. Now i'm in need to optional use a different java compiler (JDK 1.3.1). According to the documentation of the Ant task "javac" i've set [...] fork ="true" executable = "C:jdk1.3.1 injavac" compiler = "javac1.3" When running the skript, i get an error message [javac] Registry key 'SoftwareJavaSoftJava Runtime EnvironmentCurrentVersion' [javac] has value '1.4', but '1.3' is required. [javac] Error: could not find java   More>>

Hello @ all,


I'm using Ant 1.5.3 and JDK 1.4.0 on Win2K.

I've written an Ant skript to compile a Java project and build a jar-archive, works well so far.

Now i'm in need to optional use a different java compiler (JDK 1.3.1).

According to the documentation of the Ant task "javac" i've set

			
[...]
fork ="true"
executable = "C:jdk1.3.1 injavac"
compiler = "javac1.3"

When running the skript, i get an error message
			
[javac] Registry key 'SoftwareJavaSoftJava Runtime EnvironmentCurrentVersion'
[javac] has value '1.4', but '1.3' is required.
[javac] Error: could not find java.dll
[javac] Error: could not find Java 2 Runtime Environment.


Any suggestions/hints on this?


Many TIA & Ciao, Markus

   <<Less

Re: How can i use a java compiler that differs from installed JDK on Win2K?

Posted By:   Anonymous  
Posted On:   Wednesday, September 3, 2003 11:30 AM

I have tested something similar on Windows2000 with ant 1.6 alpha.

Here is my build file :


project name="javac" default="javac">







On my PC, jdk1.2.2 is the "current version".
It works, I get simply a warning that "build.compiler" is ignored because fork="true"

Now can you try to start the javac of jdk 1.4 by hand, in a command box ? My guess is that you are going to have the same error messages like ant.

Cheers,

Antoine
About | Sitemap | Contact