Handling multiple project dependencies in Eclipse with Ant

I have previously used spring and have moved on to a project that uses ant.

I have searched the manuals and tutorials etc. but can抰 find the answer to this question.

How do I manage multi project dependencies in eclipse with Ant?

Sorry for cross posting, posted in the wrong forum earlier.

[330 byte] By [SpringMana] at [2007-11-27 5:48:09]
# 1
I'd have a separate project just for dependencies. But quite what your problem actually is is unclear
georgemca at 2007-7-12 15:33:20 > top of Java-index,Java Essentials,Java Programming...
# 2
My main question is how to get Ant to compile and use resources in other projects in the eclipse workspace. I have a main build file that builds all sub projects but as soon as it reaches a dependency from another project the build fails.
SpringMana at 2007-7-12 15:33:20 > top of Java-index,Java Essentials,Java Programming...
# 3

What do you mean by a dependency from another project? You mean the projects are dependent on one another, well obviously they are, but is this the problem you're hitting? If so, you just need to ensure they're built in the correct order. Or is it that your dependencies are littered about multiple projects? You know that Ant understands paths that include ".." to go back a directory? That can solve a lot of these kinds of problems. Or, if your multi-project project is even fairly complex, I'd consider using Maven for it rather than Ant. It was designed from day 1 to manage multi-project projects

But I don't see that Eclipse has anything to do with it

georgemca at 2007-7-12 15:33:20 > top of Java-index,Java Essentials,Java Programming...
# 4

The problem is the build order. I have used maven before for this kind of work but this is a new customer project. It will probably be multiple projects dependencies.

Is it possible to give an example of how to handle project dependencies with ant? Should I import the jars or is it possible to setup a dependency check like maven.

AntMana at 2007-7-12 15:33:20 > top of Java-index,Java Essentials,Java Programming...
# 5

Our build process is basically a maven-like set of ant scripts, and it's highly unweildy. But one thing you may want to take away is, we have a text file which dictates the project order. We have 1 master build script, and some sub-scripts which have specific stages defined in them - build, test, deploy - and some properties files. The master build is project-agnostic, we apply it to each project in turn, all that need be done to add a new project to the build is commit it to CVS and put it's name in the build order text file. Don't ask me to post the code because it's massive, and also at work now! I don't particularly like it, a lot of effort that we can get for free with Maven, but the build order file is a good idea IMHO, and worth considering here. We have all our dependencies in a lib project, and we add built projects to that as they are built, too, so as long as the build order is right, everything works

georgemca at 2007-7-12 15:33:20 > top of Java-index,Java Essentials,Java Programming...