2005-12-30 17:37:11 -05:00
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
2005-12-12 12:53:59 -05:00
|
|
|
<!--
|
2005-12-30 17:37:11 -05:00
|
|
|
Copyright 2005-2006 The Apache Software Foundation
|
|
|
|
|
2005-12-12 12:53:59 -05:00
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
you may not use this file except in compliance with the License.
|
|
|
|
You may obtain a copy of the License at
|
2005-12-30 17:37:11 -05:00
|
|
|
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
2005-12-12 12:53:59 -05:00
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
See the License for the specific language governing permissions and
|
|
|
|
limitations under the License.
|
|
|
|
-->
|
2005-12-19 04:07:34 -05:00
|
|
|
<project default="default" xmlns:j="jelly:core" xmlns:ant="jelly:ant" xmlns:license="license" xmlns:util="jelly:util" xmlns:maven="jelly:maven" xmlns:artifact="artifact">
|
2005-12-12 12:53:59 -05:00
|
|
|
|
2005-12-21 19:57:43 -05:00
|
|
|
<goal name="default" prereqs="jar:install"/>
|
2005-12-12 12:53:59 -05:00
|
|
|
|
|
|
|
<postGoal name="clean">
|
|
|
|
<delete dir="${basedir}/activemq-data" />
|
|
|
|
<delete dir="${basedir}/foo" />
|
|
|
|
</postGoal>
|
|
|
|
|
|
|
|
<preGoal name="java:compile">
|
|
|
|
<attainGoal name="selector:generate" />
|
|
|
|
</preGoal>
|
|
|
|
|
|
|
|
<postGoal name="java:compile">
|
|
|
|
<attainGoal name="xbean:generate" />
|
|
|
|
</postGoal>
|
|
|
|
|
|
|
|
<postGoal name="test:compile">
|
|
|
|
<!-- Once the tests are compiled... install them -->
|
|
|
|
<ant:jar jarfile="${maven.build.dir}/${pom.artifactId}-test-${pom.currentVersion}.jar" basedir="${maven.test.dest}" index="${maven.jar.index}" compress="${maven.jar.compress}" excludes="${maven.jar.excludes}">
|
|
|
|
|
|
|
|
<j:if test="${maven.jar.manifest.available}">
|
|
|
|
<ant:setProperty name="manifest" value="${maven.jar.manifest}" />
|
|
|
|
</j:if>
|
|
|
|
|
|
|
|
<j:if test="${context.getVariable('maven.jar.includes') != null}">
|
|
|
|
<ant:setProperty name="includes" value="${maven.jar.includes}" />
|
|
|
|
</j:if>
|
|
|
|
|
|
|
|
<j:set var="licenseFileName">
|
|
|
|
<license:fileName />
|
|
|
|
</j:set>
|
|
|
|
<util:file name="${licenseFileName}" var="licenseFile" />
|
|
|
|
<ant:metainf dir="${licenseFile.canonicalFile.parent}">
|
|
|
|
<ant:include name="${licenseFile.canonicalFile.name}" />
|
|
|
|
</ant:metainf>
|
|
|
|
</ant:jar>
|
|
|
|
|
|
|
|
<mkdir dir="${maven.repo.local}/${pom.groupId}/jars" />
|
2006-01-15 22:01:24 -05:00
|
|
|
<echo>Copying ${maven.build.dir}/${pom.artifactId}-test-${pom.currentVersion}.jar to ${maven.repo.local}/${pom.groupId}/jars</echo>
|
2005-12-12 12:53:59 -05:00
|
|
|
<copy todir="${maven.repo.local}/${pom.groupId}/jars" file="${maven.build.dir}/${pom.artifactId}-test-${pom.currentVersion}.jar" />
|
|
|
|
|
|
|
|
</postGoal>
|
|
|
|
|
|
|
|
<goal name="selector:generate" description="Generates the ActiveMQ selector parser.">
|
2005-12-28 12:24:02 -05:00
|
|
|
<mkdir dir="${pom.build.sourceDirectory}/org/apache/activemq/selector" />
|
|
|
|
<javacc target="${basedir}/src/main/grammar/SelectorParser.jj" javacchome="${maven.repo.local}/javacc/jars" outputdirectory="${pom.build.sourceDirectory}/org/apache/activemq/selector" />
|
2005-12-12 12:53:59 -05:00
|
|
|
</goal>
|
|
|
|
|
|
|
|
<goal name="openwire:generate-control-data" description="Generates the openwire control data." prereqs="test:compile">
|
|
|
|
|
|
|
|
<path id="test.classpath">
|
|
|
|
<pathelement path="${maven.build.dest}" />
|
|
|
|
<pathelement path="${basedir}/target/classes" />
|
|
|
|
<pathelement path="${basedir}/target/test-classes" />
|
|
|
|
<path refid="maven.dependency.classpath" />
|
|
|
|
</path>
|
|
|
|
|
2005-12-28 12:24:02 -05:00
|
|
|
<java classname="org.apache.activemq.openwire.DataFileGenerator" fork="true">
|
2005-12-12 12:53:59 -05:00
|
|
|
<classpath refid="test.classpath" />
|
|
|
|
</java>
|
|
|
|
|
|
|
|
</goal>
|
|
|
|
|
|
|
|
<goal name="openwire:generate" description="Generates the openwire marshallers.">
|
|
|
|
|
|
|
|
<ant:mkdir dir="${basedir}/target/gram-classes" />
|
|
|
|
<ant:javac destdir="target/gram-classes" excludes="**/package.html" debug="${maven.compile.debug}" deprecation="${maven.compile.deprecation}" optimize="${maven.compile.optimize}">
|
|
|
|
|
|
|
|
<ant:classpath>
|
|
|
|
<ant:path refid="maven.dependency.classpath" />
|
|
|
|
<ant:pathelement path="target/gram-classes" />
|
|
|
|
</ant:classpath>
|
|
|
|
|
|
|
|
<ant:src path="src/gram/java" />
|
|
|
|
|
|
|
|
<j:if test="${context.getVariable('maven.compile.source') != null}">
|
|
|
|
<ant:setProperty name="source" value="${maven.compile.source}" />
|
|
|
|
</j:if>
|
|
|
|
<j:if test="${context.getVariable('maven.compile.target') != null}">
|
|
|
|
<ant:setProperty name="target" value="${maven.compile.target}" />
|
|
|
|
</j:if>
|
|
|
|
<j:if test="${context.getVariable('maven.compile.verbose') != null}">
|
|
|
|
<ant:setProperty name="verbose" value="${maven.compile.verbose}" />
|
|
|
|
</j:if>
|
|
|
|
</ant:javac>
|
|
|
|
|
|
|
|
<path id="openwire.classpath">
|
2006-03-04 01:56:39 -05:00
|
|
|
<pathelement path="${java.home}/lib/tools.jar" />
|
2005-12-12 12:53:59 -05:00
|
|
|
<pathelement path="target/gram-classes" />
|
|
|
|
<path refid="maven.dependency.classpath" />
|
|
|
|
</path>
|
|
|
|
|
|
|
|
<java classname="org.codehaus.gram.Gram" fork="true">
|
|
|
|
<classpath refid="openwire.classpath" />
|
|
|
|
<sysproperty key="openwire.version" value="${openwire.version}" />
|
2006-03-06 21:32:50 -05:00
|
|
|
<arg value="src/main/java" />
|
2006-03-01 12:03:28 -05:00
|
|
|
<arg value="src/gram/script/GenerateCppMarshallingClasses.groovy" />
|
|
|
|
<arg value="src/gram/script/GenerateCppMarshallingHeaders.groovy" />
|
2006-02-24 13:45:01 -05:00
|
|
|
<arg value="src/gram/script/GenerateJavaMarshalling.groovy" />
|
2006-02-17 14:58:05 -05:00
|
|
|
<arg value="src/gram/script/GenerateJavaTests.groovy" />
|
2006-01-06 12:11:53 -05:00
|
|
|
<arg value="src/gram/script/GenerateCSharpMarshalling.groovy" />
|
2006-02-24 13:45:01 -05:00
|
|
|
<arg value="src/gram/script/GenerateCSharpClasses.groovy" />
|
|
|
|
<arg value="src/gram/script/GenerateCppHeaders.groovy" />
|
|
|
|
<arg value="src/gram/script/GenerateCppClasses.groovy" />
|
2005-12-12 12:53:59 -05:00
|
|
|
<arg value="src/gram/script/GenerateCMarshalling.groovy" />
|
|
|
|
</java>
|
|
|
|
|
|
|
|
</goal>
|
|
|
|
|
|
|
|
<!-- START SNIPPET: xbean -->
|
|
|
|
<goal name="xbean:generate" description="Generates the XBean XSD, documentation and META-INF/services files.">
|
|
|
|
<ant:mkdir dir="${basedir}/target/generated"/>
|
|
|
|
|
|
|
|
<path id="test.classpath">
|
|
|
|
<pathelement path="${maven.build.dest}" />
|
|
|
|
<pathelement path="${basedir}/target/classes" />
|
|
|
|
<pathelement path="${basedir}/target/test-classes" />
|
|
|
|
<path refid="maven.dependency.classpath" />
|
|
|
|
</path>
|
|
|
|
|
2006-02-09 16:41:59 -05:00
|
|
|
<taskdef name="xsdGenerate" classname="org.apache.xbean.spring.generator.MappingGeneratorTask">
|
2005-12-12 12:53:59 -05:00
|
|
|
<classpath refid="test.classpath" />
|
|
|
|
</taskdef>
|
|
|
|
<ant:mkdir dir="${basedir}/target/generated"/>
|
|
|
|
<xsdGenerate destFile="${basedir}/target/activemq-${pom.currentVersion}.xsd" namespace="http://activemq.org/config/1.0"
|
|
|
|
classpathref="test.classpath" srcdir="${basedir}/src/main/java" metaInfDir="${basedir}/target/generated/"/>
|
|
|
|
|
|
|
|
<copy file="${basedir}/target/activemq-${pom.currentVersion}.xsd" todir="${basedir}/../xdocs"/>
|
|
|
|
<copy file="${basedir}/target/activemq-${pom.currentVersion}.xsd.html" todir="${basedir}/../xdocs"/>
|
|
|
|
</goal>
|
|
|
|
<!-- END SNIPPET: xbean -->
|
|
|
|
|
|
|
|
<goal name="setclasspath" prereqs="java:compile">
|
|
|
|
<path id="test.classpath">
|
|
|
|
<pathelement path="${maven.build.dest}" />
|
|
|
|
<pathelement path="${basedir}/target/classes" />
|
|
|
|
<pathelement path="${basedir}/target/test-classes" />
|
|
|
|
<path refid="maven.dependency.classpath" />
|
|
|
|
</path>
|
|
|
|
</goal>
|
|
|
|
|
2005-12-19 04:07:34 -05:00
|
|
|
<!-- ================================================================== -->
|
2005-12-20 02:08:21 -05:00
|
|
|
<!-- GOALs for deploying resources -->
|
2005-12-19 04:07:34 -05:00
|
|
|
<!-- ================================================================== -->
|
|
|
|
|
2006-01-25 23:49:28 -05:00
|
|
|
<!-- goal name="jar:deploy"
|
2005-12-20 02:08:21 -05:00
|
|
|
description="Deploy the core and core test binaries" prereqs="test:compile">
|
|
|
|
|
|
|
|
<artifact:deploy
|
|
|
|
artifact="${basedir}/target/${pom.artifactId}-${pom.currentVersion}.jar"
|
|
|
|
type="jar"
|
|
|
|
project="${pom}"
|
|
|
|
/>
|
2005-12-19 04:07:34 -05:00
|
|
|
|
|
|
|
<artifact:deploy
|
|
|
|
artifact="${basedir}/target/${pom.artifactId}-test-${pom.currentVersion}.jar"
|
|
|
|
type="jar"
|
|
|
|
project="${pom}"
|
|
|
|
/>
|
2006-01-25 23:49:28 -05:00
|
|
|
</goal -->
|
2005-12-20 02:08:21 -05:00
|
|
|
|
2005-12-21 19:57:43 -05:00
|
|
|
<goal name="jar:deploy-javadoc"
|
2006-01-24 22:42:36 -05:00
|
|
|
description="Deploys javadoc binary" prereqs="javadoc:install">
|
2005-12-20 02:08:21 -05:00
|
|
|
|
|
|
|
<artifact:deploy
|
|
|
|
artifact="${basedir}/target/${pom.artifactId}-${pom.currentVersion}_javadoc.jar"
|
|
|
|
type="jar"
|
|
|
|
project="${pom}"
|
|
|
|
/>
|
|
|
|
</goal>
|
|
|
|
|
2005-12-21 00:01:08 -05:00
|
|
|
<goal name="xsd:deploy-xbean"
|
|
|
|
description="Deploys xsd generated files" prereqs="xbean:generate">
|
2005-12-20 02:08:21 -05:00
|
|
|
|
|
|
|
<artifact:deploy
|
2006-01-25 23:49:28 -05:00
|
|
|
artifact="${basedir}/target/activemq-${pom.currentVersion}.xsd"
|
2005-12-20 02:08:21 -05:00
|
|
|
type="distribution"
|
|
|
|
project="${pom}"
|
|
|
|
/>
|
|
|
|
|
|
|
|
<artifact:deploy
|
2006-01-25 23:49:28 -05:00
|
|
|
artifact="${basedir}/target/activemq-${pom.currentVersion}.xsd.html"
|
2005-12-20 02:08:21 -05:00
|
|
|
type="distribution"
|
|
|
|
project="${pom}"
|
|
|
|
/>
|
|
|
|
</goal>
|
2005-12-12 12:53:59 -05:00
|
|
|
|
|
|
|
</project>
|