User: user57  
  Date: 01/09/10 22:29:11

  Modified:    .        build.xml
  Log:
   o updating build system, see mail to jboss-dev for more details
  
  Revision  Changes    Path
  1.8       +377 -263  jbossmx/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbossmx/build.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- build.xml 2001/09/04 05:08:07     1.7
  +++ build.xml 2001/09/11 05:29:11     1.8
  @@ -10,7 +10,7 @@
   <!--                                                                        -->
   <!-- ====================================================================== -->
   
  -<!-- $Id: build.xml,v 1.7 2001/09/04 05:08:07 user57 Exp $ -->
  +<!-- $Id: build.xml,v 1.8 2001/09/11 05:29:11 user57 Exp $ -->
   
   <project default="main" name="JBoss/Cluster">
   
  @@ -19,237 +19,297 @@
     <!-- ================================================================== -->
   
     <!-- Load Buildmagic extention tasks. -->
  -  <taskdef name="taskdef" classname="planet57.tools.buildmagic.task.Taskdef"/>
     <taskdef resource="planet57/tools/buildmagic/task/autoload.properties"/>
  +  <taskdef name="property" classname="planet57.tools.buildmagic.task.Property"/>
   
  -  <!-- Setup the basic project roots. -->
  -  <path id="project.root"><pathelement location=".."/></path>
  -  <property name="project.root" refid="project.root"/>
  -  <property name="control.root" value="${project.root}/build"/>
  +  <!-- Initialize the build system. -->
  +  <target name="init" depends="_init-prepare" unless="init.disable">
  +    <!-- Perform any setup required if we are a child of another build -->
  +    <call target="_init-child"/>
  +
  +    <!-- Setup the basic project roots. -->
  +    <path id="project.root"><pathelement location=".."/></path>
  +    <property name="project.root" refid="project.root"/> 
  +    <property name="project.build" value="${project.root}/build"/>
     
  -  <!-- Include user and project property overrides. -->
  -  <property file="${user.home}/.buildmagic.properties"/>
  -  <property file="${user.home}/.ant.properties"/>
  -  <property file="${control.root}/local.properties"/>
  -
  -  <!-- Setup the basic environment for a project build module. -->
  -  <property name="project.output" value="${control.root}/output"/>
  -  <property name="project.release" value="${project.output}"/>
  -  <property name="tools.root" value="${project.root}/tools"/>
  -  <property name="thirdparty.root" value="${project.root}/thirdparty"/>
  -
  -  <!-- Setup the basic environment for a source module. -->
  -  <property name="module.root" value="${basedir}"/>
  -  <property name="module.source" value="${module.root}/src"/>
  -  <property name="module.output" value="${module.root}/output"/>
  -  <property name="module.build" value="${module.output}"/>
  -  <property name="module.release" value="${module.output}"/>
  -  <property file="${module.root}/local.properties"/>
  +    <!-- Include user and project property overrides. -->
  +    <property file="${user.home}/.buildmagic.properties"/>
  +    <property file="${user.home}/.ant.properties"/>
  +
  +    <!-- Setup the project environment. -->
  +    <property file="${project.build}/local.properties"/>
  +    <property name="project.tools" value="${project.root}/tools"/>
  +    <property name="project.thirdparty" value="${project.root}/thirdparty"/>
  +
  +    <!-- Setup the module environment. -->
  +    <property name="module.root" value="${basedir}"/>
  +    <call target="_init-local-properties"/>
  +    <property file="${module.root}/local.properties"/>
  +    <property name="module.source" value="${module.root}/src"/>
  +    <property name="module.output" value="${module.root}/output"/>
  +    <property name="module.tools" value="${module.root}/tools"/>
  +    <property name="module.thirdparty" value="${module.root}/thirdparty"/>
   
  -  <!-- Initialize the build system. -->
  -  <target name="init" unless="initialized-already" depends="init-buildlog">
  +    <!-- Setup the build.log -->
  +    <call target="_init-buildlog"/>
  +
  +    <!-- Load common properties -->
  +    <property resource="planet57/tools/buildmagic/common.properties"/>
  +
  +    <!-- Setup the build timestamp & build identifer properties -->
       <tstamp>
         <format property="build.number" pattern="yyyyMMddHHmm"/>
       </tstamp>
  -    <property name="build.id" value="DEV"/>
  +    <property name="build.id" value="${build.number}"/>
   
  -    <property resource="planet57/tools/buildmagic/common.properties"/>
  -    <property resource="planet57/tools/buildmagic/task.properties"/>
  +    <!-- Invoke the configure task -->
  +    <call target="_configure"/>
   
  -    <moduleinfo/>
  +    <!-- Late bind properties & install filters -->
       <resolver force="${buildmagic.resolveproperties.force}"/>
       <propertyfilter all="${buildmagic.propertyfilter.all}"/>
  -    <property name="initialized-already" value="true"/>
  -  </target>
   
  -  <target name="init-buildlog" unless="buildlog-disabled">
  -    <record name="${basedir}/build.log" append="no" loglevel="info"/>
  -  </target>
  +    <!-- Show some information -->
  +    <call target="_init-show-environment"/>
   
  +    <!-- Finish up -->
  +    <property name="init.disable" value="true"/>
  +  </target>
   
  -  <!-- ================================================================== -->
  -  <!-- Module Configuration                                               -->
  -  <!-- ================================================================== -->
  +  <!-- Perform any preperation before init. -->
  +  <target name="_init-prepare">
  +    <available file="${module.root}/etc/local.properties-example"
  +            property="init.have-local-properties"/>
  +  </target>
   
  -  <!-- Module name(s) & version -->
  -  <property name="module.name" value="cluster"/>
  -  <property name="module.Name" value="JBoss Cluster"/>
  -  <property name="module.version" value="0.1"/>
  +  <!-- Perform any setup required if we are a child of another build -->
  +  <target name="_init-child" if="init.have-parent">
  +    <!-- Disable the build.log, our parent will catch it -->
  +    <property name="init-buildlog.disable" value="true"/>
  +  </target>
   
  +  <!-- Install the local.properties example if it is there -->
  +  <target name="_init-local-properties" if="init.have-local-properties">
  +    <!-- Setup the local.properties file as needed -->
  +    <copy file="${module.root}/etc/local.properties-example"
  +          tofile="${module.root}/local.properties" filtering="yes"/>
  +    <property file="${module.root}/local.properties"/>
  +  </target>
   
  -  <!-- ================================================================== -->
  -  <!-- Tool Setup                                                         -->
  -  <!-- ================================================================== -->
  +  <!-- Initialize the build.log -->
  +  <target name="_init-buildlog" unless="init-buildlog.disable">
  +    <record name="${basedir}/build.log" append="no" loglevel="info"/>
  +    <property name="init-buildlog.disable" value="true"/>
  +  </target>
   
  -  <!-- No non-standard tools are required for this module. -->
  +  <!-- Show the running environment if -Dinit.verbose=true -->
  +  <target name="_init-show-environment" if="init.verbose">
  +    <echo><![CDATA[
  +project.root:    ${project.root}
  +module.root:     ${module.root}
  +user.home:       ${user.home}
  +build.compiler:  ${build.compiler}
  +java.home:       ${java.home}
  +java.class.path: ${java.class.path}
  +java.version:    ${java.version}
  +java.vendor:     ${java.vendor}
  +java.vm.version: ${java.vm.version}
  +java.vm.name:    ${java.vm.name}
  +java.vm.info:    ${java.vm.info}
  +os.name:         ${os.name}
  +os.arch:         ${os.arch}
  +os.version:      ${os.version}
  +]]></echo>
  +  </target>
   
   
     <!-- ================================================================== -->
  -  <!-- Library Setup                                                      -->
  +  <!-- Configuration                                                      -->
     <!-- ================================================================== -->
  -
  -  <!-- Java Management Extensions (JMX) -->
  -  <property name="sun.jmx.root" value="${thirdparty.root}/sun/jmx"/>
  -  <property name="sun.jmx.lib" value="${sun.jmx.root}/lib"/>
  -  <path id="sun.jmx.classpath">
  -    <pathelement path="${sun.jmx.lib}/jmxri.jar"/>
  -  </path>
  -
  -  <!-- Java API for XML Processing (JAXP) -->
  -  <property name="sun.jaxp.root" value="${thirdparty.root}/sun/jaxp"/>
  -  <property name="sun.jaxp.lib" value="${sun.jaxp.root}/lib"/>
  -  <path id="sun.jaxp.classpath">
  -    <fileset dir="${sun.jaxp.lib}">
  -      <include name="**/*.jar"/>
  -    </fileset>
  -  </path>
  -
  -  <!-- Java Authentication and Authorization Service (JAAS) -->
  -  <property name="sun.jaas.root" value="${thirdparty.root}/sun/jaas"/>
  -  <property name="sun.jaas.lib" value="${sun.jaas.root}/lib"/>
  -  <path id="sun.jaas.classpath">
  -    <pathelement path="${sun.jaas.lib}/jaas.jar"/>
  -  </path>
  -
  -  <!-- Java Secure Socket Extension (JSSE) -->
  -  <property name="sun.jsse.root" value="${thirdparty.root}/sun/jsse"/>
  -  <property name="sun.jsse.lib" value="${sun.jsse.root}/lib"/>
  -  <path id="sun.jsse.classpath">
  -    <fileset dir="${sun.jsse.lib}">
  -      <include name="**/*.jar"/>
  -    </fileset>
  -  </path>
  -
  -  <!-- Log4j -->
  -  <property name="apache.log4j.root" value="${thirdparty.root}/apache/log4j"/>
  -  <property name="apache.log4j.lib" value="${apache.log4j.root}/lib"/>
  -  <path id="apache.log4j.classpath">
  -    <pathelement path="${apache.log4j.lib}/log4j.jar"/>
  -  </path>
  -
  -  <!-- JUnit -->
  -  <property name="junit.junit.root" value="${thirdparty.root}/junit/junit"/>
  -  <property name="junit.junit.lib" value="${junit.junit.root}/lib"/>
  -  <path id="junit.junit.classpath">
  -    <pathelement path="${junit.junit.lib}/junit.jar"/>
  -  </path>
   
  -  <!-- JavaGroups -->
  -  <property name="javagroups.javagroups.root" 
value="${thirdparty.root}/javagroups/javagroups"/>
  -  <property name="javagroups.javagroups.lib" 
value="${javagroups.javagroups.root}/lib"/>
  -  <path id="javagroups.javagroups.classpath">
  -    <pathelement path="${javagroups.javagroups.lib}/JavaGroups.jar"/>
  -  </path>
  -
  -  <!-- The combined library classpath -->
  -  <path id="library.classpath">
  -    <path refid="sun.jmx.classpath"/>
  -    <path refid="sun.jaxp.classpath"/>
  -    <path refid="sun.jaas.classpath"/>
  -    <path refid="sun.jsse.classpath"/>
  -    <path refid="apache.log4j.classpath"/>
  -    <path refid="junit.junit.classpath"/>
  -    <path refid="javagroups.javagroups.classpath"/>
  -  </path>
  +  <!--
  +     | Configure the build system.
  +     |
  +     | Configuration elements should be placed in the appropriate 
  +     | _configure-* targets.
  +   -->
  +
  +  <target name="_configure" unless="configure.disable">
  +    <!-- Module name(s) & version -->
  +    <property name="module.name" value="cluster"/>
  +    <property name="module.Name" value="JBoss Cluster"/>
  +    <property name="module.version" value="unspecified"/>
  +
  +    <!-- Invoke the rest of the configuration targets -->
  +    <call target="_configure-tools"/>
  +    <call target="_configure-libraries"/>
  +    <call target="_configure-modules"/>
  +    <call target="_configure-tasks"/>
  +  </target>
  +
  +  <!-- Configure the thirdparty tools required to build this module. -->
  +  <target name="_configure-tools" unless="configure-tools.disable">
  +    <!-- No non-standard tools are required for this module. -->
  +  </target>
  +
  +  <!-- Configure the thirdparty libraries required by this module. -->
  +  <target name="_configure-libraries" unless="configure-libraries.disable">
  +    <!-- Java Management Extensions (JMX) -->
  +    <property name="sun.jmx.root" value="${project.thirdparty}/sun/jmx"/>
  +    <property name="sun.jmx.lib" value="${sun.jmx.root}/lib"/>
  +    <path id="sun.jmx.classpath">
  +      <pathelement path="${sun.jmx.lib}/jmxri.jar"/>
  +    </path>
  +
  +    <!-- Java API for XML Processing (JAXP) -->
  +    <property name="sun.jaxp.root" value="${project.thirdparty}/sun/jaxp"/>
  +    <property name="sun.jaxp.lib" value="${sun.jaxp.root}/lib"/>
  +    <path id="sun.jaxp.classpath">
  +      <fileset dir="${sun.jaxp.lib}">
  +        <include name="**/*.jar"/>
  +      </fileset>
  +    </path>
   
  +    <!-- Java Authentication and Authorization Service (JAAS) -->
  +    <property name="sun.jaas.root" value="${project.thirdparty}/sun/jaas"/>
  +    <property name="sun.jaas.lib" value="${sun.jaas.root}/lib"/>
  +    <path id="sun.jaas.classpath">
  +      <pathelement path="${sun.jaas.lib}/jaas.jar"/>
  +    </path>
  +
  +    <!-- Java Secure Socket Extension (JSSE) -->
  +    <property name="sun.jsse.root" value="${project.thirdparty}/sun/jsse"/>
  +    <property name="sun.jsse.lib" value="${sun.jsse.root}/lib"/>
  +    <path id="sun.jsse.classpath">
  +      <fileset dir="${sun.jsse.lib}">
  +        <include name="**/*.jar"/>
  +      </fileset>
  +    </path>
   
  -  <!-- ================================================================== -->
  -  <!-- Dependent Module Setup                                             -->
  -  <!-- ================================================================== -->
  - 
  -  <!-- 
  -     |  Dependent module paths should not use fileset expansion as that 
  -     |  will throw an exception if the directory does not exist.  Use
  -     |  a require task from the init-hook target to notify users when
  -     |  a library from a dependent module does not exist.
  -    -->
  +    <!-- Log4j -->
  +    <property name="apache.log4j.root" value="${project.thirdparty}/apache/log4j"/>
  +    <property name="apache.log4j.lib" value="${apache.log4j.root}/lib"/>
  +    <path id="apache.log4j.classpath">
  +      <pathelement path="${apache.log4j.lib}/log4j.jar"/>
  +    </path>
  +
  +    <!-- JUnit -->
  +    <property name="junit.junit.root" value="${project.thirdparty}/junit/junit"/>
  +    <property name="junit.junit.lib" value="${junit.junit.root}/lib"/>
  +    <path id="junit.junit.classpath">
  +      <pathelement path="${junit.junit.lib}/junit.jar"/>
  +    </path>
  +
  +    <!-- JavaGroups -->
  +    <property name="javagroups.javagroups.root" 
value="${project.thirdparty}/javagroups/javagroups"/>
  +    <property name="javagroups.javagroups.lib" 
value="${javagroups.javagroups.root}/lib"/>
  +    <path id="javagroups.javagroups.classpath">
  +      <pathelement path="${javagroups.javagroups.lib}/JavaGroups.jar"/>
  +    </path>
  +
  +    <!-- The combined library classpath -->
  +    <path id="library.classpath">
  +      <path refid="sun.jmx.classpath"/>
  +      <path refid="sun.jaxp.classpath"/>
  +      <path refid="sun.jaas.classpath"/>
  +      <path refid="sun.jsse.classpath"/>
  +      <path refid="apache.log4j.classpath"/>
  +      <path refid="junit.junit.classpath"/>
  +      <path refid="javagroups.javagroups.classpath"/>
  +    </path>
  +  </target>
  +
  +  <!-- Configure the external modules which this module depends on. -->
  +  <target name="_configure-modules" unless="configure-modules.disable">
  +    <!-- J2EE -->
  +    <property name="jboss.j2ee.root" value="${project.root}/j2ee/output"/>
  +    <property name="jboss.j2ee.lib" value="${jboss.j2ee.root}/lib"/>
  +    <path id="jboss.j2ee.classpath">
  +      <pathelement path="${jboss.j2ee.lib}/jboss-j2ee.jar"/>
  +    </path>
  +
  +    <!-- Naming -->
  +    <property name="jboss.naming.root" value="${project.root}/naming/output"/>
  +    <property name="jboss.naming.lib" value="${jboss.naming.root}/lib"/>
  +    <path id="jboss.naming.classpath">
  +      <pathelement path="${jboss.naming.lib}/jnpserver.jar"/>
  +    </path>
  +
  +    <!-- Server -->
  +    <property name="jboss.server.root" value="${project.root}/server/output"/>
  +    <property name="jboss.server.lib" value="${jboss.server.root}/lib"/>
  +    <path id="jboss.server.classpath">
  +      <pathelement path="${jboss.server.lib}/jboss.jar"/>
  +    </path>
  +
  +    <!-- The combined dependent module classpath -->
  +    <path id="dependentmodule.classpath">
  +      <path refid="jboss.j2ee.classpath"/>
  +      <path refid="jboss.naming.classpath"/>
  +      <path refid="jboss.server.classpath"/>
  +    </path>
  +  </target>
  +
  +  <!-- Configure the tasks used by this module. -->
  +  <target name="_configure-tasks" unless="configure-tasks.disable">
  +    <!-- Load common task properties -->
  +    <property resource="planet57/tools/buildmagic/task.properties"/>
   
  -  <!-- J2EE -->
  -  <property name="jboss.j2ee.root" value="${project.root}/j2ee/output"/>
  -  <property name="jboss.j2ee.lib" value="${jboss.j2ee.root}/lib"/>
  -  <path id="jboss.j2ee.classpath">
  -    <pathelement path="${jboss.j2ee.lib}/jboss-j2ee.jar"/>
  -  </path>
  -
  -  <!-- Naming -->
  -  <property name="jboss.naming.root" value="${project.root}/naming/output"/>
  -  <property name="jboss.naming.lib" value="${jboss.naming.root}/lib"/>
  -  <path id="jboss.naming.classpath">
  -    <pathelement path="${jboss.naming.lib}/jnpserver.jar"/>
  -  </path>
  -
  -  <!-- Server -->
  -  <property name="jboss.server.root" value="${project.root}/server/output"/>
  -  <property name="jboss.server.lib" value="${jboss.server.root}/lib"/>
  -  <path id="jboss.server.classpath">
  -    <pathelement path="${jboss.server.lib}/jboss.jar"/>
  -  </path>
  -
  -  <!-- The combined depedant module classpath -->
  -  <path id="dependentmodule.classpath">
  -    <path refid="jboss.j2ee.classpath"/>
  -    <path refid="jboss.naming.classpath"/>
  -    <path refid="jboss.server.classpath"/>
  -  </path>
  -
  -
  -  <!-- ================================================================== -->
  -  <!-- Task Setup                                                         -->
  -  <!-- ================================================================== -->
  -
  -  <!-- The combined thirdparty classpath -->
  -  <path id="thirdparty.classpath">
  -    <path refid="library.classpath"/>
  -    <path refid="dependentmodule.classpath"/>
  -  </path>
  -
  -  <!-- This module is based on Java 1.2 -->
  -  <property name="javac.target" value="1.2"/>
  -
  -  <!-- classpath and local.classpath must have a value using with a path -->
  -  <property name="classpath" value=""/>
  -  <property name="local.classpath" value=""/>
  -
  -  <!-- The classpath required to build classes. -->
  -  <path id="javac.classpath">
  -    <pathelement path="${classpath}"/>
  -    <pathelement path="${local.classpath}"/>
  -    <path refid="thirdparty.classpath"/>
  -  </path>
  -
  -  <!-- Packages to include when generating api documentation -->
  -  <property name="javadoc.packages" value="org.jbossmx.*"/>
  -
  -  <!-- The classpath required to build javadocs. -->
  -  <path id="javadoc.classpath">
  -    <path refid="javac.classpath"/>
  -  </path>
  -
  -  <!-- Override JUnit defaults -->
  -  <property name="junit.timeout" value="240000"/> <!-- 4 minutes -->
  -  <property name="junit.batchtest.todir" value="${build.reports}"/>
  -  <property name="junit.jvm.options" value="-Ddummy"/>
  -
  -  <!-- RMIC should generate stubs compatible with Java 1.2+ -->
  -  <property name="rmic.stubVersion" value="1.2"/>
  -
  -  <!-- Where source files live -->
  -  <property name="source.java" value="${module.source}/main"/>
  -  <property name="source.etc" value="${module.source}/etc"/>
  -  <property name="source.examples" value="${module.source}/examples"/>
  -
  -  <!-- Where build generated files will go -->
  -  <property name="build.classes" value="${module.build}/classes"/>
  -  <property name="build.jars" value="${module.build}/lib"/>
  -  <property name="build.api" value="${module.build}/api"/>
  -  <property name="build.etc" value="${module.build}/etc"/>
  -  <property name="build.examples" value="${module.build}/examples"/>
  -  <property name="build.reports" value="${module.build}/reports"/>
  -
  -  <!-- Where release generated files will go -->
  -  <property name="release.id" value="${module.name}-${module.version}-${build.id}"/>
  -  <property name="release.root" value="${module.release}/${release.id}"/>
  -  <property name="release.archive.basename" 
value="${module.release}/${release.id}"/>
  +    <!-- Where source files live -->
  +    <property name="source.java" value="${module.source}/main"/>
  +    <property name="source.etc" value="${module.source}/etc"/>
  +    <property name="source.examples" value="${module.source}/examples"/>
  +
  +    <!-- Where build generated files will go -->
  +    <property name="build.classes" value="${module.output}/classes"/>
  +    <property name="build.lib" value="${module.output}/lib"/>
  +    <property name="build.api" value="${module.output}/api"/>
  +    <property name="build.etc" value="${module.output}/etc"/>
  +    <property name="build.examples" value="${module.output}/examples"/>
  +    <property name="build.reports" value="${module.output}/reports"/>
  +
  +    <!-- Install/Release structure -->
  +    <property name="install.id" value="${module.name}-${module.version}"/>
  +    <property name="release.id" value="${install.id}"/>
  +    <property name="install.root" value="${module.output}/${install.id}"/>
  +
  +    <!-- The combined thirdparty classpath -->
  +    <path id="thirdparty.classpath">
  +      <path refid="library.classpath"/>
  +      <path refid="dependentmodule.classpath"/>
  +    </path>
  +
  +    <!-- This module is based on Java 1.2 -->
  +    <property name="javac.target" value="1.2"/>
  +
  +    <!-- RMIC should generate stubs compatible with Java 1.2+ -->
  +    <property name="rmic.stubVersion" value="1.2"/>
  +
  +    <!-- classpath and local.classpath must have a value using with a path -->
  +    <property name="classpath" value=""/>
  +    <property name="local.classpath" value=""/>
  +
  +    <!-- The classpath required to build classes. -->
  +    <path id="javac.classpath">
  +      <pathelement path="${classpath}"/>
  +      <pathelement path="${local.classpath}"/>
  +      <path refid="thirdparty.classpath"/>
  +    </path>
  +
  +    <!-- The classpath required to build javadocs. -->
  +    <path id="javadoc.classpath">
  +      <path refid="javac.classpath"/>
  +    </path>
  +
  +    <!-- Packages to include when generating api documentation -->
  +    <!-- CHANGE ME TO org.jboss.* -->
  +    <property name="javadoc.packages" value="org.jbossmx.*"/>
  +
  +    <!-- Override JUnit defaults -->
  +    <property name="junit.timeout" value="240000"/> <!-- 4 minutes -->
  +    <property name="junit.batchtest.todir" value="${build.reports}"/>
  +    <property name="junit.jvm.options" value="-Ddummy"/>
  +  </target>
   
   
     <!-- ================================================================== -->
  @@ -317,17 +377,17 @@
   
   
     <!-- ================================================================== -->
  -  <!-- Build Jars                                                         -->
  +  <!-- Archives                                                           -->
     <!-- ================================================================== -->
   
     <!-- 
        |  Build all jar files.
       -->
     <target name="jars" depends="compile" description="Builds all jar files.">
  -    <mkdir dir="${build.jars}"/>
  +    <mkdir dir="${build.lib}"/>
   
       <!-- Build the jbossmx.jar -->
  -    <jar jarfile="${build.jars}/jbossmx.jar">
  +    <jar jarfile="${build.lib}/jbossmx.jar">
         <fileset dir="${build.classes}">
           <include name="**"/>
           <exclude name="org/jboss/ha/**"/>
  @@ -336,7 +396,7 @@
       </jar>
   
       <!-- Build the jbossha.jar -->
  -    <jar jarfile="${build.jars}/jbossha.jar">
  +    <jar jarfile="${build.lib}/jbossha.jar">
         <fileset dir="${build.classes}">
           <include name="**"/>
           <exclude name="org/jbossmx/**"/>
  @@ -344,7 +404,7 @@
       </jar>
   
       <!-- Build the jbossha-client.jar -->
  -    <jar jarfile="${build.jars}/jbossha-client.jar">
  +    <jar jarfile="${build.lib}/jbossha-client.jar">
         <fileset dir="${build.classes}">
           <include name="org/jboss/ha/HARemoteInfo.class"/>
           <include name="org/jboss/ha/*Stub.class"/>
  @@ -356,42 +416,42 @@
   
   
     <!-- ================================================================== -->
  -  <!-- Build documents                                                    -->
  +  <!-- Documents                                                          -->
     <!-- ================================================================== -->
   
     <!-- 
  -     |  Create all generated documenation.
  +     | Create all generated documenation.
        |
  -     |  This target should depend on other docs-* targets for each 
  -     |  different type of docuementation that is to be generated.
  -    -->
  -  <target name="docs" depends="docs-api, docs-examples"
  -       description="Builds all documentation."/>
  +     | This target should depend on other docs-* targets for each 
  +     | different type of docuementation that is to be generated.
  +   -->
  +
  +  <target name="docs" depends="init" description="Builds all documentation.">
  +    <call target="docs-api"/>
  +    <call target="docs-examples"/>
  +  </target>
   
     <!-- Javadocs is an exception, but provide a docs-api to conform. -->
  -  <target name="docs-api" depends="javadocs"/>
  +  <target name="docs-api" depends="docs-javadocs"/>
   
     <!-- 
  -     |  Check if we need to build javadocs 
  +     | Check if we need to build javadocs 
        |
  -     |  Javadocs will only be generated if one or more .java source files
  -     |  is newer than the generated index.html.
  -    -->
  -  <target name="javadocs-check" depends="init">
  +     | Javadocs will only be generated if one or more .java source files
  +     | is newer than the generated index.html.
  +   -->
  +
  +  <target name="docs-javadocs-check" depends="init">
       <!-- if index.html is newer than the sources we are up to date -->
  -    <uptodate property="javadoc-generated-already"
  +    <uptodate property="docs-javadocs.disable"
              targetfile="${build.api}/index.html">
         <srcfiles dir="${source.java}" includes="**/*.java"/>
       </uptodate>
  -
  -    <!-- create the directory here to prevent install/release from failing -->
  -    <mkdir dir="${build.api}"/>
     </target>        
   
     <!-- Generate Javadoc if we are out of date -->
  -  <target name="javadocs" 
  -       depends="javadocs-check" 
  -       unless="javadoc-generated-already">
  +  <target name="docs-javadocs" depends="docs-javadocs-check" 
unless="docs-javadocs.disable">
  +    <mkdir dir="${build.api}"/>
       <javadoc packagenames="${javadoc.packages}"
                sourcepath="${source.java}"
                destdir="${build.api}"
  @@ -405,12 +465,16 @@
                package="${javadoc.package}"
                protected="${javadoc.protected}"
                private="${javadoc.private}"
  +             encoding="${javadoc.encoding}"
                use="${javadoc.use}"
             verbose="${javadoc.verbose}"> 
  -      <!-- <group title="???" packages="*"/> -->
  +      <group title="JDBC Extension" packages="javax.sql*"/>
  +      <group title="J2EE" packages="javax*"/>
       </javadoc>
     </target>
   
  +  <target name="javadocs" depends="docs-javadocs"/>
  +
     <!-- Generate examples files -->
     <!-- Should really place these in a package, compile, then include source -->
     <target name="docs-examples" depends="init">
  @@ -424,46 +488,54 @@
   
   
     <!-- ================================================================== -->
  -  <!-- Builds a release distribution.                                     -->
  +  <!-- Install                                                            -->
     <!-- ================================================================== -->
   
  -  <target name="release" depends="all"
  -       description="Builds a release distribution.">
  -    <!-- Copy the output directory to the release directory -->
  -    <mkdir dir="${release.root}"/>
  -    <copy todir="${release.root}" filtering="no">
  -      <fileset dir="${module.build}">
  +  <target name="install" depends="all">
  +    <!-- Copy the output directory to the install directory -->
  +    <mkdir dir="${install.root}"/>
  +    <copy todir="${install.root}" filtering="no">
  +      <fileset dir="${module.output}">
            <include name="**/*"/>
  -         <exclude name="${release.id}/**"/>
  +         <exclude name="${install.id}/**"/>
         </fileset>
       </copy>
     </target>
   
  -  <target name="release-archive-prepare" depends="release">
  -    <mkdir dir="${module.release}"/>
  +
  +  <!-- ================================================================== -->
  +  <!-- Release                                                            -->
  +  <!-- ================================================================== -->
  +
  +  <!-- 
  +     | Builds a release distribution.
  +   -->
  +
  +  <target name="release" depends="install">
  +    <!-- install handles most of the work -->
     </target>
   
  -  <target name="release-zip" depends="release-archive-prepare"
  +  <target name="release-zip" depends="release"
          description="Builds a ZIP release distribution.">
  -    <zip zipfile="${release.archive.basename}.zip">
  -      <fileset dir="${module.release}">
  +    <zip zipfile="${module.output}/${release.id}.zip">
  +      <fileset dir="${module.output}">
           <include name="${release.id}/**"/>
         </fileset>
       </zip>
     </target>
   
  -  <target name="release-tar" depends="release-archive-prepare"
  +  <target name="release-tar" depends="release"
          description="Builds a TAR release distribution.">
  -    <tar tarfile="${release.archive.basename}.tar" longfile="gnu"
  -      basedir="${module.release}"
  +    <tar tarfile="${module.output}/${release.id}.tar" longfile="gnu"
  +      basedir="${module.output}"
         includes="${release.id}/**">
       </tar>
     </target>
   
     <target name="release-tgz" depends="release-tar"
          description="Builds a TAR-GZIP release distribution.">
  -    <gzip src="${release.archive.basename}.tar"
  -       zipfile="${release.archive.basename}.tgz"/>
  +    <gzip src="${module.output}/${release.id}.tar"
  +       zipfile="${module.output}/${release.id}.tgz"/>
     </target>
   
     <target name="release-all" depends="release-zip, release-tgz"
  @@ -471,11 +543,21 @@
   
   
     <!-- ================================================================== -->
  -  <!-- Run tests                                                          -->
  +  <!-- Tests                                                              -->
     <!-- ================================================================== -->
  +
  +  <!--
  +     | Run all tests.
  +   -->
  +
  +  <target name="tests" depends="init" description="Execute all tests.">
  +    <call target="tests-junit"/>
  +    <call target="tests-reports"/>
  +  </target>
   
  -  <target name="tests" depends="tests-junit"
  -       description="Execute all tests."/>
  +  <!--
  +     | Run JUnit tests.
  +   -->
   
     <target name="tests-junit" depends="jars">
       <mkdir dir="${build.reports}"/>
  @@ -487,9 +569,7 @@
           timeout="${junit.timeout}"
           jvm="${junit.jvm}">
   
  -      <!-- junit.jvm.options must have a valid value -->
         <jvmarg value="${junit.jvm.options}"/>
  -      <sysproperty key="jbosstest.deploy.dir" file="${build.jars}"/>
   
         <classpath>
           <pathelement location="${build.classes}"/>
  @@ -505,39 +585,68 @@
                 fork="${junit.batchtest.fork}">
   
           <fileset dir="${build.classes}">
  -          <include name="**/Test*.class"/>
  -          <include name="**/*Test.class"/>
  -          <include name="**/AllJUnitTests.class"/>
  +          <include name="**/*TestCase.class"/>
  +          <include name="**/*TestSuite.class"/>
           </fileset>
         </batchtest>
       </junit>
     </target>
   
  +  <target name="reports" depends="tests-reports" 
  +       description="Generates all reports."/>
   
  +  <target name="tests-reports" depends="tests-reports-html"/>
  +
  +  <target name="tests-reports-html" depends="compile">
  +    <mkdir dir="${build.reports}/html"/>
  +
  +    <junitreport todir="${build.reports}">
  +      <fileset dir="${build.reports}">
  +        <include name="TEST-*.xml"/>
  +      </fileset>
  +      <report format="frames" todir="${build.reports}/html"/>
  +    </junitreport>
  +  </target>
  +
  +
     <!-- ================================================================== -->
  -  <!-- Cleans up generated stuff                                          -->
  +  <!-- Cleaning                                                           -->
     <!-- ================================================================== -->
   
     <!-- Clean up all build output -->
     <target name="clean" depends="init"
          description="Cleans up most generated files.">
  -    <delete dir="${module.build}"/>
  -    <delete dir="${module.release}"/>
       <delete dir="${module.output}"/>
     </target>
   
     <!-- Clean up all generated files -->
     <target name="clobber" depends="clean"
          description="Cleans up all generated files.">
  +    <delete file="${module.root}/local.properties"/>
       <delete file="${module.root}/build.log"/>
     </target>
   
   
  +  <!-- ================================================================== -->
  +  <!-- Workspace                                                          -->
  +  <!-- ================================================================== -->
  +
  +  <target name="update-project" depends="init">
  +    <echo>Updating project workspace...</echo>
  +    <cvs command="update -d" dest="${project.root}"/>
  +  </target>
  +
  +  <target name="update-module" depends="init">
  +    <echo>Updating module workspace...</echo>
  +    <cvs command="update -d" dest="${module.root}"/>
  +  </target>
  +
  +
     <!-- ================================================================== -->
  -  <!-- Other Targets                                                      -->
  +  <!-- Help                                                               -->
     <!-- ================================================================== -->
   
  -  <target name="help">
  +  <target name="help" depends="init">
       <projecthelp taskname="help">
         <header><![CDATA[
     The ${module.Name} module.
  @@ -548,6 +657,11 @@
   ]]></footer>
       </projecthelp>
     </target>
  +
  +
  +  <!-- ================================================================== -->
  +  <!-- Misc.                                                              -->
  +  <!-- ================================================================== -->
   
     <target name="main" depends="most"
          description="Executes the default target (most)."/>
  
  
  

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to