dain 2004/09/06 20:05:45
Modified: . maven.xml project.xml
Log:
Removed old assembly code
Revision Changes Path
1.3 +129 -219 openejb/maven.xml
Index: maven.xml
===================================================================
RCS file: /home/projects/openejb/scm/openejb/maven.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- maven.xml 10 Aug 2004 01:41:54 -0000 1.2
+++ maven.xml 7 Sep 2004 00:05:45 -0000 1.3
@@ -12,11 +12,11 @@
xmlns:modules="local:modules">
<j:set var="release.id"
value="${pom.standardToLegacyId(pom.id)}-${pom.currentVersion}"/>
+ <j:set var="distDir" value="target/${pom.groupId}-${pom.currentVersion}"/>
<!-- ======= -->
<!-- Modules -->
<!-- ======= -->
-
<goal name="modules:reactor:init">
<!--
| Determine the includes which the reactor will use.
@@ -25,7 +25,7 @@
|
| module.types Comma seperated list of module types (ie. specs or
modules)
| module.includes Comma seperated list of module names (ie. common,
core, ...)
- | modules Same as module.includes, module.includes
initializes to this value
+ | modules Same as module.includes, module.includes initializes
to this value
| module.excludes Comma seperated list of module names to exclude
|
| The end result is that modules.reactor.includes is set to the
project.xml files
@@ -37,7 +37,7 @@
-->
<j:if test="${context.getVariable('module.types') == null}">
- <j:set var="module.types" value="modules,specs"/>
+ <j:set var="module.types" value="modules,applications"/>
</j:if>
<j:if test="${context.getVariable('modules') == null}">
@@ -96,13 +96,15 @@
| the baseddir portion of the file's name. So this will essentially
strip off
| ${basedir}
-->
- <j:set var="filename"
-
value="${file.parentFile.parentFile.name}/${file.parentFile.name}/${file.name}"/>
+ <j:set var="directory"
value="${file.parentFile.parentFile.name}/${file.parentFile.name}"/>
+ <j:set var="filename" value="${directory}/${file.name}"/>
<j:choose>
<j:when test="${context.getVariable('modules.reactor.includes') ==
null}">
+ <j:set var="modules.directories" value="${directory}"/>
<j:set var="modules.reactor.includes" value="${filename}"/>
</j:when>
<j:otherwise>
+ <j:set var="modules.directories"
value="${modules.directories},${directory}"/>
<j:set var="modules.reactor.includes"
value="${modules.reactor.includes},${filename}"/>
</j:otherwise>
</j:choose>
@@ -111,15 +113,7 @@
<!-- Helper tags for modules -->
<define:taglib uri="local:modules">
-
<define:tag name="reactor">
- <j:if test="${aggregate != null}">
- <j:set var="modules.aggregate.skip" value="true"/>
- <j:if test="${aggregate}">
- <j:set var="modules.aggregate.skip" value="false"/>
- </j:if>
- </j:if>
-
<attainGoal name="modules:reactor:init"/>
<j:choose>
@@ -146,13 +140,7 @@
<!-- Set reactor projects in parent scope so goals have access to it -->
<j:set var="reactorProjects" value="${reactorProjects}" scope="parent"/>
-
- <!-- Optionaly perform module aggregation -->
- <j:if test="${context.getVariable('modules.aggregate.skip') != 'true'}">
- <attainGoal name="modules:aggregate"/>
- </j:if>
</define:tag>
-
</define:taglib>
<goal name="modules:reactor">
@@ -167,28 +155,70 @@
<modules:reactor goals="build"/>
</goal>
+ <goal name="modules:test">
+ <modules:reactor goals="test"/>
+ </goal>
+
<goal name="modules:site">
- <modules:reactor goals="site" aggregate="false"/>
+ <modules:reactor goals="site"/>
+ </goal>
+
+ <goal name="modules:eclipse">
+ <modules:reactor goals="eclipse"/>
</goal>
<goal name="modules:javadoc">
- <modules:reactor goals="javadoc" aggregate="false"/>
+ <modules:reactor goals="javadoc"/>
</goal>
<goal name="modules:clover">
- <modules:reactor goals="clover" aggregate="false"/>
+ <modules:reactor goals="clover.wrapper"/>
</goal>
+ <goal name="modules:jar-deploy">
+ <modules:reactor goals="jar:deploy"/>
+ </goal>
+
<goal name="modules:clean">
- <modules:reactor goals="clean" aggregate="false"/>
- </goal>
+ <!-- DMB: don't know why we are cleaning this way when we could invoke
clean on the submodules -->
+ <attainGoal name="modules:reactor:init"/>
+ <u:tokenize var="directories" delim=",">${modules.directories}</u:tokenize>
+ <j:forEach var="directory" items="${directories}">
+ <ant:echo>+----------------------------------------</ant:echo>
+ <ant:echo>| Cleaning: ${directory} </ant:echo>
+ <ant:echo>+----------------------------------------</ant:echo>
+ <ant:delete dir="${directory}/target"/>
+ <ant:delete file="${directory}/velocity.log" quiet="true"
failonerror="false"/>
+ <ant:echo></ant:echo>
+ </j:forEach>
- <goal name="modules:clobber">
- <modules:reactor goals="clobber" aggregate="false"/>
+ <ant:echo>+----------------------------------------</ant:echo>
+ <ant:echo>| Cleaning: ${distDir} </ant:echo>
+ <ant:echo>+----------------------------------------</ant:echo>
+ <ant:delete dir="${distDir}"/>
</goal>
- <goal name="modules:jar:deploy">
- <modules:reactor goals="jar:deploy"/>
+ <goal name="modules:clobber">
+ <attainGoal name="modules:reactor:init"/>
+ <u:tokenize var="directories" delim=",">${modules.directories}</u:tokenize>
+ <j:forEach var="directory" items="${directories}">
+ <ant:echo>+----------------------------------------</ant:echo>
+ <ant:echo>| Clobbering: ${directory} </ant:echo>
+ <ant:echo>+----------------------------------------</ant:echo>
+ <ant:delete dir="${directory}/target"/>
+ <ant:delete quiet="false" failonerror="false">
+ <ant:fileset dir="${directory}">
+ <ant:include name="maven.log"/>
+ <ant:include name="velocity.log*"/>
+ <ant:include name="junit*.properties"/>
+ </ant:fileset>
+ </ant:delete>
+ <ant:echo></ant:echo>
+ </j:forEach>
+ <ant:echo>+----------------------------------------</ant:echo>
+ <ant:echo>| Clobbering: ${distDir} </ant:echo>
+ <ant:echo>+----------------------------------------</ant:echo>
+ <ant:delete dir="${distDir}"/>
</goal>
<preGoal name="clean:clean">
@@ -203,206 +233,28 @@
<attainGoal name="modules:clobber"/>
</preGoal>
- <goal name="jar:deploy">
- <attainGoal name="modules:jar:deploy"/>
- </goal>
-
<goal name="default">
<attainGoal name="modules:default"/>
</goal>
+ <goal name="test">
+ <attainGoal name="modules:test"/>
+ </goal>
- <!-- ========================= -->
- <!-- Module Output Aggregation -->
- <!-- ========================= -->
-
- <goal name="aggregate">
- <attainGoal name="modules:reactor"/>
- <attainGoal name="modules:aggregate"/>
- </goal>
-
- <!-- Helper tags for module aggregation -->
- <define:taglib uri="local:aggregate">
-
- <define:tag name="copy">
- <u:available file="${source}" xmlns="jelly:ant">
- <mkdir dir="${target}"/>
- <copy todir="${target}">
- <fileset dir="${source}">
- <include name="${include}"/>
- <exclude name="${exclude}"/>
- </fileset>
- </copy>
- </u:available>
- </define:tag>
-
- <define:tag name="mkdir">
- <mkdir dir="${dir}"/>
- </define:tag>
-
- <define:tag name="scripts">
- <aggregate:copy
- source="${module.root}/src/bin"
- target="${aggregate.dir}/bin"
- include="**/*"/>
- <aggregate:mkdir dir="${aggregate.dir}/logs"/>
- </define:tag>
-
- <define:tag name="config">
- <aggregate:copy
- source="${module.root}/src/conf"
- target="${aggregate.dir}/conf"
- include="**/*"/>
- </define:tag>
-
- <define:tag name="deploy">
- <aggregate:copy
- source="${module.root}/src/deploy"
- target="${aggregate.dir}/beans"
- include="**/*"/>
- </define:tag>
-
- <define:tag name="libraries">
- <aggregate:copy
- source="${module.root}/target"
- target="${aggregate.dir}/lib"
- include="*.jar"/>
- </define:tag>
-
- <define:tag name="default">
- <j:if test="${scripts == null || scripts == 'true'}">
- <aggregate:scripts/>
- </j:if>
-
- <j:if test="${config == null || config == 'true'}">
- <aggregate:config/>
- </j:if>
-
- <j:if test="${deploy == null || deploy == 'true'}">
- <aggregate:deploy/>
- </j:if>
-
- <j:if test="${libraries == null || libraries == 'true'}">
- <aggregate:libraries/>
- </j:if>
- </define:tag>
-
- </define:taglib>
-
- <goal name="modules:aggregate"
- description="Aggregates module target output.">
-
- <ant:echo>Aggregating modules...</ant:echo>
-
- <!-- Setup the target aggregation directory -->
- <j:set var="aggregate.dir" value="${basedir}/target/${release.id}"/>
- <ant:mkdir dir="${aggregate.dir}"/>
-
- <j:forEach var="module" items="${reactorProjects}">
- <ant:echo>Processing ${module.id}...</ant:echo>
-
- <!-- Get the modules root directory -->
- <j:set var="module.root" value="${module.file.parent}"/>
-
- <!-- Invoke the aggregation hook -->
- <j:set var="hook_name" value="modules:aggregate:${module.id}"/>
- <!-- If there is no goal defined then use the default -->
- <j:set var="werkzProject"
value="${org.apache.commons.jelly.werkz.Project}"/>
- <j:if test="${werkzProject.getGoal(hook_name) == null}">
- <j:set var="hook_name" value="modules:aggregate:default"/>
- </j:if>
- <attainGoal name="${hook_name}"/>
-
- <!-- Process dependencies -->
- <j:forEach var="artifact" items="${module.artifacts}">
- <j:set var="dependency" value="${artifact.dependency}"/>
- <j:if test="${dependency.getProperty('runtime') == 'true'}">
- <ant:echo>Processing dependency: ${dependency.id}</ant:echo>
-
- <j:choose>
- <j:when test="${dependency.getProperty('destinations') ==
null}">
- <j:set var="destinations" value="lib"/>
- </j:when>
- <j:otherwise>
- <j:set var="destinations"
value="${dependency.getProperty('destinations')}"/>
- </j:otherwise>
- </j:choose>
-
- <u:tokenize var="destinationSet" delim=","
trim="true">${destinations}</u:tokenize>
-
- <j:forEach var="destination" items="${destinationSet}"
trim="true">
- <j:set var="targetDir"
value="${aggregate.dir}/${destination.trim()}"/>
- <ant:mkdir dir="${targetDir}"/>
- <ant:copy todir="${targetDir}" file="${artifact.path}"/>
- </j:forEach>
- </j:if>
- </j:forEach>
- </j:forEach>
+ <goal name="eclipse">
+ <attainGoal name="modules:eclipse"/>
+ </goal>
- <!-- Cleanse some stuff -->
- <u:available file="${aggregate.dir}/bin" xmlns="jelly:ant">
- <!-- Fix permissions -->
- <chmod perm="ugo+x">
- <fileset dir="${aggregate.dir}/bin">
- <include name="*"/>
- <exclude name="*.bat"/>
- <exclude name="*.cmd"/>
- </fileset>
- </chmod>
- <chmod perm="ugo-x">
- <fileset dir="${aggregate.dir}/bin">
- <include name="*.bat"/>
- <include name="*.cmd"/>
- </fileset>
- </chmod>
-
- <!-- Fix CRLF -->
- <fixcrlf srcdir="${aggregate.dir}/bin" eol="lf" eof="remove">
- <include name="*"/>
- <exclude name="*.jar"/>
- <exclude name="*.bat"/>
- <exclude name="*.cmd"/>
- </fixcrlf>
- <fixcrlf srcdir="${aggregate.dir}/bin" eol="crlf">
- <include name="*.bat"/>
- <include name="*.cmd"/>
- <exclude name="*.jar"/>
- </fixcrlf>
- </u:available>
+ <goal name="blah">
+ <modules:reactor goals="hello"/>
</goal>
+ <goal name="plugins">
+ <ant:echo>This step is no longer necessary. Simply use 'maven' to build
the server.</ant:echo>
+ </goal>
- <!-- =============================== -->
- <!-- Module Output Aggregation Hooks -->
- <!-- =============================== -->
- <goal name="modules:aggregate:default">
- <aggregate:default/>
- </goal>
- <goal name="modules:aggregate:openejb:openejb-itests">
- <aggregate:default libraries="false"/>
- <aggregate:copy
- source="${module.root}/target"
- target="${aggregate.dir}/lib"
- include="*.jar"
- exclude="openejb-itests-beans.jar"/>
-
- <aggregate:copy
- source="${module.root}/target"
- target="${aggregate.dir}/beans"
- include="openejb-itests-beans.jar"/>
- </goal>
-
- <goal name="modules:aggregate:openejb:openejb-webadmin">
- <aggregate:default libraries="false"/>
- <aggregate:copy
- source="${module.root}/target"
- target="${aggregate.dir}/beans"
- include="*.jar"
- exclude="openejb-webadmin-${pom.currentVersion}.jar"/>
- </goal>
-
<!-- =============================== -->
<!-- Documentation & Site Generation -->
<!-- =============================== -->
@@ -423,7 +275,6 @@
<attainGoal name="maven-pmd-plugin:deregister"/>
<attainGoal name="maven-simian-plugin:deregister"/>
<attainGoal name="maven-jdepend-plugin:deregister"/>
- <attainGoal name="maven-statcvs-plugin:deregister"/>
<attainGoal name="maven-jxr-plugin:deregister"/>
<attainGoal name="maven-javadoc-plugin:deregister"/>
<attainGoal name="maven-junit-report-plugin:deregister"/>
@@ -434,4 +285,63 @@
<!--<attainGoal name="maven-file-activity-plugin:deregister"/>-->
<!--<attainGoal name="maven-developer-activity-plugin:deregister"/>-->
</postGoal>
+
+ <preGoal name="site">
+ <attainGoal name="modules:aggregate:site"/>
+ </preGoal>
+
+ <postGoal name="site">
+ <j:set var="aggregate.dir" value="${basedir}/${distDir}/docs"/>
+ <!-- Copy project docs -->
+ <ant:echo>Copying project docs to ${aggregate.dir}...</ant:echo>
+ <ant:copy todir="${aggregate.dir}">
+ <ant:fileset dir="${basedir}/target/docs"/>
+ </ant:copy>
+ </postGoal>
+
+ <goal name="modules:aggregate:site" prereqs="modules:site"
+ description="Copy the generated websites of all the modules into the root
project">
+
+ <ant:echo>Aggregating module site documentation...</ant:echo>
+
+ <!-- Setup the target aggregation directory -->
+ <j:set var="aggregate.dir" value="${basedir}/${distDir}/docs"/>
+ <ant:mkdir dir="${aggregate.dir}"/>
+
+ <j:forEach var="module" items="${reactorProjects}">
+ <ant:echo>Processing ${module.id}...</ant:echo>
+
+ <!-- Get the modules root directory -->
+ <j:set var="module.root" value="${module.file.parent}"/>
+
+ <!-- Setup the target dir under docs -->
+ <j:set var="moduleDirName">${module.file.parentFile.name}</j:set>
+ <j:set
var="moduleTypeDirName">${module.file.parentFile.parentFile.name}</j:set>
+ <j:set
var="outputDir">${aggregate.dir}/${moduleTypeDirName}/${moduleDirName}</j:set>
+
+ <!-- Copy module docs -->
+ <ant:echo>Copying docs to ${outputDir}...</ant:echo>
+ <ant:mkdir dir="${outputDir}"/>
+ <ant:copy todir="${outputDir}">
+ <ant:fileset dir="${module.root}/target/docs"/>
+ </ant:copy>
+ </j:forEach>
+ </goal>
+
+ <goal name="site:tocvs"
+ description="Creates the entire website and copies it to the local CVS
repository so that it can be checked in to update the site">
+
+ <j:jelly xmlns="jelly:ant">
+
+ <j:if test="${empty(geronimo.cvs.docdir)}">
+ <j:set var="geronimo.cvs.docdir"
value="../incubator-site/build/site/projects/geronimo"/>
+ </j:if>
+
+ <mkdir dir="${geronimo.cvs.docdir}"/>
+ <copy todir="${geronimo.cvs.docdir}">
+ <fileset dir="${basedir}/${distDir}/docs"/>
+ </copy>
+
+ </j:jelly>
+ </goal>
</project>
1.3 +11 -42 openejb/project.xml
Index: project.xml
===================================================================
RCS file: /home/projects/openejb/scm/openejb/project.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- project.xml 26 Apr 2004 04:18:14 -0000 1.2
+++ project.xml 7 Sep 2004 00:05:45 -0000 1.3
@@ -4,46 +4,15 @@
<project>
- <pomVersion>3</pomVersion>
- <extend>${basedir}/etc/project.xml</extend>
+ <pomVersion>3</pomVersion>
+ <extend>${basedir}/etc/project.xml</extend>
- <!-- ===================== -->
- <!-- Module Identification -->
- <!-- ===================== -->
-
- <name>OpenEJB</name>
- <id>openejb</id>
-
- <organization>
- <name>OpenEJB Project</name>
- <url></url>
- <logo></logo>
- </organization>
- <inceptionYear>1999</inceptionYear>
-
- <url></url>
- <issueTrackingUrl></issueTrackingUrl>
-
- <mailingLists>
- <mailingList>
- <name></name>
- <subscribe></subscribe>
- <unsubscribe></unsubscribe>
- <archive></archive>
- </mailingList>
- </mailingLists>
-
-
- <licenses>
- <license>
- <name>The Apache Software License, Version 1.1</name>
- <url>http://www.apache.org/licenses/LICENSE</url>
- <distribution>repo</distribution>
- </license>
- </licenses>
-
- <build>
- <sourceDirectory></sourceDirectory>
- <unitTestSourceDirectory></unitTestSourceDirectory>
- </build>
+ <!-- ===================== -->
+ <!-- Module Identification -->
+ <!-- ===================== -->
+
+ <build>
+ <sourceDirectory></sourceDirectory>
+ <unitTestSourceDirectory></unitTestSourceDirectory>
+ </build>
</project>