ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antoine Lévy-Lambert <anto...@antbuild.com>
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

Antoine

-----Urspr√ľngliche Nachricht-----
Von: Mikael Petterson (KI/EAB) [mailto:mikael.petterson@ericsson.com]
Gesendet: Mittwoch, 24. September 2003 09:58
An: user@ant.apache.org
Betreff: How to set jdk version for ant


Hi,

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?

//Mikael

This is how the script looks like:

-------------------------------------------
#!/bin/sh

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 org.apache.tools.ant.Main -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/sunrise.company.se/EDUP/Jdk/1.3.1/jre
Detected OS: SunOS
Could not load class (org.apache.tools.ant.taskdefs.optional.PropertyFile)
for task propertyfile
Could not load class
(org.apache.tools.ant.taskdefs.optional.vss.MSVSSCHECKIN) for task
vsscheckin
 +User task: sql     org.apache.tools.ant.taskdefs.SQLExec

........

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

........

   [java] Executing '/afs/sunrise.company.se/EDUP/Jdk/1.3.1/jre/bin/java'
wit
h arguments:
     [java] '-classpath'




---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message