ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antoine Lévy-Lambert <>
Subject AW: How to set jdk version for ant
Date Wed, 24 Sep 2003 09:16:23 GMT
maybe you have the problem because you have set your JAVA_HOME, but not your
path accordingly.

export JAVA_HOME="/app/jdk/1.4.2_01"
export PATH=$JAVA_HOME/bin:$PATH


-----Urspr√ľngliche Nachricht-----
Von: Mikael Petterson (KI/EAB) []
Gesendet: Mittwoch, 24. September 2003 09:58
Betreff: How to set jdk version for ant


I have been trying to make sure that jdk1.4.2 is used for my ant 1.5.4 (
tasks java and javac). I am using a  script to execute my build.xml.
How can I make sure that jdk1.4.2 is used instead?


This is how the script looks like:


set JAVA_HOME="/app/jdk/1.4.2_01";export JAVA_HOME

#ant.jar is in the lib directory.
cd ../lib
java -cp ant.jar -debug -buildfile
../build/build.xml all execute

Then when I execute the build.xml I get the following ( using debug):

Apache Ant version 1.5.4 compiled on August 12 2003
Buildfile: ../build/build.xml
Detected Java version: 1.3 in: /afs/
Detected OS: SunOS
Could not load class (
for task propertyfile
Could not load class
( for task
 +User task: sql


     [echo] Compiling with 1.3!
fileset: Setup scanner in dir /home/eraonel/xml2j/src with patternSet{
 [] excludes: [] }


   [java] Executing '/afs/'
h arguments:
     [java] '-classpath'

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message