You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Tim Gordon <ti...@allustra.com> on 2003/04/07 11:35:34 UTC

Building up a dependent classpath

Hello

Let's say I've got a couple of projects, projecta and projectb. Some classes
in projectb will depend on projecta. I'm thinking of introducing another
projectc, which depends on projecta and projectb.

I'd like to have some kind of mechanism which allows me to construct a
classpath in projectb which will include the built classes from projecta,
together with any third-party jars I may have needed to included to get
projecta to build.

Ultimately, I'd like to be able to create a classpath for projectc which has
on it the projectc classes, any projectc third-party jars, the projectb
classes, any projectb third-party jars, etc (you get the idea).

The key thing would be to (somehow) only specify the classpath for projecta
once and then specify that another project depends on it to include that
classpath.

The only way I can think of to do this is by using properties loaded from
files to define things like the classpath and then having other project
which need to be aware of that classpath also load those properties.

Is there another way to share things like construction of classpaths (it
would be also be useful for the construction of other kinds of paths).

Tim Gordon

Allustra Limited
1 Royal Exchange Avenue
London
EC3V 3LT
Tel 020 7464 4190
Tel 020 7464 4194
http://www.allustra.com/