ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Erik Hatcher" <jakarta-...@ehatchersolutions.com>
Subject Re: exporting classpath references from inner Ant builds to outer Ant builds.
Date Thu, 23 May 2002 09:06:57 GMT
This sounds kinda risky in that a sub-build could stomp on properties (I
assume you'd want those exported back up too?) and references that you did
expect to be altered.  Do you envision any mechanisms for controlling what
gets exported? All references blindly?  Or some selection mechanism?




----- Original Message -----
From: "James Strachan" <james_strachan@yahoo.co.uk>
To: <ant-dev@jakarta.apache.org>
Sent: Wednesday, May 22, 2002 5:05 PM
Subject: exporting classpath references from inner Ant builds to outer Ant
builds.


> I'm moving various projects to Maven at the moment. One feature that'd
make
> my life much easier is if I could call Maven's Ant build file to compile
> some stuff and generate the classpath to use to run sample programs using
> its project.xml dependency information, then for this generated classpath
to
> be exported back to me for use in an outer build.
>
> e.g. imagine if my projects build file looked like this...
>
> <project name="Foo" basedir=".">
>     <property file="${user.home}/build.properties" />
>     <property file="build.properties" />
>     <property file="project.properties" />
>
>     <target name="maven:compile">
>         <!-- call Maven to compile things and export the classpath -->
>         <ant antfile="${maven.home}/build-maven.xml" target="compile"/>
>     </target>
>
>     <target name="foo" depends="maven:compile">
>         <java classname="org.apache.commons.jelly.Jelly">
>         <classpath>
>             <pathelement path="${maven.build.dest}"/>
>
>             <!-- reuse the classpath created inside maven's build -->
>             <path refid="maven.dependency.classpath"/>
>         </classpath>
>         </java>
>     <target>
>
>
> This is kinda the opposite way around for the <ant> targets
> inheritRefs="true" - I guess I want to be able to use an exportRefs="true"
> for references to be exported from the called Ant project to the calling
Ant
> project. This feature would also help making the Maven plugins a bit
easier
> too I should think.
>
> Anyone any comments on whether this seems reasonable or if I've missed
> something? I'm happy to investigate further and have a go at creating a
> patch for Ant; I'd just like a sanity check before I head off in this
> direction.
>
> James
>
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
>
>
> --
> To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>
>
>


--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message