You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Martin van der Plas <mv...@imc.nl> on 2006/02/07 16:21:58 UTC

Re: m2: developing ant plugin - problems passing maven.compile.classpath

Hi All,

I've the same problem here. How to convert the 
${project.testClassPathElements} into an ant  classpath reference?

Any help  is appreciated.
Thanks.

Martin

john.w.law@jpmorgan.com wrote:

>I have created an ant plugin with the following mojo:
>
>gateway.mojos.xml
>
><pluginMetadata>
> <mojos>
>    <!-- mojo to generate the transform -->
>   <mojo>
>      <goal>generate-transform</goal>
>      <!-- this element refers to the Ant target we'll invoke -->
>      <call>generate-xquery</call>
>      <description>this target generates the transform driven from
>pathMappings.xml</description>
>    </mojo>
> </mojos>
></pluginMetadata>
>
>Here is the corresponding target within my build script:
>
><target name="generate-xquery" description="Generates out xquery callback
>module for gateway">
>      <java classpath="${mavenCompileClasspath};${lib.dir}" classname="
>com.saxonica.Query" fork="true" failonerror="true" output="
>${xquery.dir}/Callbacks.xq">
>                  <arg line="-vlax -s ${xquery.dir}/pathMappings.xml
>${resources.dir}/xquery/GenerateCallbacks.xq !method=text "/>
>      </java>
></target>
>
>I need to pass in the ${maven.compile.classpath} so I can pick up the
>saxonsa dependency configured in my plugins pom, so included the xml below
>into the gateway.mojos.xml
>
>      <parameters>
>            <parameter>
>                   <name>mavenCompileClasspath</name>
>                   <property>mavenCompileClasspath</property>
>                   <required>true</required>
>                   <defaultValue>${maven.compile.classpath}</defaultValue>
>                   <type>java.lang.String</type>
>                   <description>maven compile classpath.</description>
>            </parameter>
>      </parameters>
>
>Unfortunately, this does not work. Does anyone know how i can pass the
>maven.compile.classpath into my build script at runtime?
>
>Thanks,
>John
>
>
>
>This communication is for informational purposes only. It is not intended
>as an offer or solicitation for the purchase or sale of any financial
>instrument or as an official confirmation of any transaction. All market prices,
>data and other information are not warranted as to completeness or accuracy and
>are subject to change without notice. Any comments or statements made herein 
>do not necessarily reflect those of JPMorgan Chase & Co., its subsidiaries 
>and affiliates
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>For additional commands, e-mail: users-help@maven.apache.org
>
>
>
>  
>



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org