ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From m1ke <>
Subject Getting Ant to compile to a different VM?
Date Wed, 03 Jan 2007 11:50:14 GMT

Hi. I am using Ant within Eclipse and need to compile to java 1.3. The
problem is Eclipse is loaded up with 1.5 - and as its loaded up in this, Ant
uses 1.5. All the settings in Eclipse are set to compile to 1.3, but I'm
having a lot of trouble finding how to do this within the Ant settings also.
There is a Runtime JRE option which is currently set to "run in the same JRE
as the workspace", whenever a separate JRE is selected for 1.3 the compiler
produces an error
Unable to load default ProjectHelper due to java.lang.NoClassDefFoundError:

Within Windows > preferences > Ant > runtime, under global entries I have
replaced tools.jar from 1.5 to 1.3 one, which then produces the error:
       :6: cannot access java.util.Collection
       [javac] bad class file:
       [javac] class file has wrong version 49.0, should be 47.0
       [javac] Please remove or make sure it appears in the correct
subdirectory of the classpath.
       [javac] import java.util.Collection;
       [javac]                  ^
       [javac] 1 error
So it's still looking in 1.5 directory.. I'm hoping any Eclipse users can
help or even if there is a general ant solution, as I'm not sure how to get
to stop looking in the 1.5 directory and look in the 1.3.. thanks a lot
View this message in context:
Sent from the Ant - Users mailing list archive at

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

View raw message