ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From (Dirk V. Schesmer)
Subject <javac>-tag problem with Sun JDK 1.4.x and ANT 1.4.1 and ANT 1.5
Date Thu, 15 Aug 2002 05:17:30 GMT
Hi all,
I have a problem using the <javac> tag when trying to get ANT 1.4.1 or
ANT 1.5 to work with Sun J2SDK 1.4.1 I'd like to ask you for help:

The ANT testscript below (build.xml) runs perfectly when using Sun JDK
1.3.x, but when using Sun JDK 1.4.x the ant tool tells me:

>J:\projects\ant\build.xml:22: Cannot use classic compiler, as it is
>available A common solution is to set the environment variable
>JAVA_HOME to your jdk directory.

My JAVA_HOME, ANT_HOME and Windows path entries are set 
correctly. OpSys is NT 2000 German.

Can you please tell me what I have to change to get it up and running
with j2sdk 1.4.x, as well?

Thanks for help,

Dirk V. Schesmer
----------------- build.xml -----------------
<!-- Simple Ant build script to test an Ant installation -->
<project name="TestInstall" default="run" basedir=".">
<target name="init">
<available file=""
<target name="ASimpleHelloObject" unless="ASimpleHelloObject"
<echo file="">
public class ASimpleHelloObject {
public static void main(String[] args) {
System.out.println("ASimpleHelloObject.main was called");
<echo message="Wrote" />
<target name="compile" depends="ASimpleHelloObject">
<javac destdir="." srcdir="." debug="on" classpath=".">
<include name=""/>
<target name="run" depends="compile">
<java classname="ASimpleHelloObject" classpath="." />
<echo message="Ant appears to be successfully installed" />

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

View raw message