Update: ant2eclipse has been deprecated by Ant2IDE. Please use Ant2IDE instead.
I wrote a simple shell script called ‘ant2eclipse‘. It runs your ant build file with -v switch, gathers essential information such as source path, its output patch and the JAR path that the project depends on, and generates or updates Eclipse .classpath file.
More graceful solution would be to inject some byte code to key Ant tasks such as javac to gather various path information. It shouldn’t be that difficult, but I’m just OK with this simple script. Please feel free to download and modify to meet your need.
This script was tested against the JBoss Remoting, version 3, so there’s no guarantee that it will work for other projects. Use at your own risk. 😉