Login | Register
My pages Projects Community openCollabNet

Discussions > cvs > CVS update: /jms4spread

jms4spread
Discussion topic

Back to topic list

CVS update: /jms4spread

Reply

Author dlr
Full name Daniel Rall
Date 2002-07-21 16:31:46 PDT
Message User: dlr
Date: 02/07/21 16:31:46

Added
 /jms4spread
  build.xml

Log
 Initial build file for JMS for Spread.

File Changes:

Directory: /jms4spread/
=======================

File [added]: build.xml
Url: http://jms4spread.ti​gris.org/source/brow​se/jms4spread/build.​xml?rev=1.1&cont​ent-type=text/x-cvsw​eb-markup
Added lines: 191
----------------
<?xml version="1.0"?>

<project name="jms4spread" default="jar">

  <!-- Static properties -->
  <property name="version" value="0.1"/>
  <property name="dist.name" value="jms4spread-$​{version}"/>
  <property name="packages" value="org.tigris.jm​s4spread"/>

  <!-- User-defined properties -->
  <property file="${user.home}/​build.properties"/​>
  <property file="build.properties"/>

  <!-- Default properties -->
  <property file="default.properties"/>

  <path id="build.classpath">
    <pathelement location="${jms.jar}"/>
    <pathelement location="${jndir.jar}"/>
  </path>


  <!-- ====================​====================​====================​====== -->
  <!-- Initialzation and building -->
  <!-- ====================​====================​====================​====== -->

  <target name="init">
    <filter token="JMS4SPREAD_VERSION" value="${version}"/>
  </target>

  <target name="prepare" depends="init"
          description="Prepares the build directory">
    <mkdir dir="${tmp.dir}"/>
  </target>

  <target name="compile" depends="prepare,display-env"
          description="Compile Java source code">
    <mkdir dir="${tmp.classes}"/>

    <javac srcdir="${src.java.dir}"
           destdir="${tmp.classes}"
       classpath="${classpath}"
           debug="${build.debug}"
           deprecation="${buil​d.deprecation}"
           optimize="${build.o​ptimize}">
           <classpath refid="build.classpath" />
    </javac>

    <copy todir="${tmp.classes}">
      <fileset dir="${src.java.dir}">
    <include name="**/*.properties" />
      </fileset>
    </copy>
  </target>

  <target name="jar" depends="compile,prepare">
    <jar jarfile="${tmp.dir}​/jms4spread.jar" basedir="${tmp.classes}" />
  </target>

  <target name="javadocs" depends="prepare"
          description="Create API documentation">
    <mkdir dir="${tmp.javadocs}"/>
    <javadoc packagenames="${packages}"
             sourcepath="${src.java.dir}"
             destdir="${tmp.javadocs}"
             author="true"
             version="true"
             windowtitle="JMS for Spread API"
             doctitle="JMS for Spread"
             bottom="Copyright &#169; 2002 Daniel Rall. All Rights Reserved."
    />
  </target>

  <target name="display-env">
    <echo>
      Library repository (lib.repo): ${lib.repo}

      Library paths:
       jms.jar: ${jms.jar}
       jndi.jar: ${jndi.jar}
    </echo>
  </target>
 
  <!-- ====================​====================​====================​====== -->
  <!-- Testing -->
  <!-- ====================​====================​====================​====== -->

  <target name="compile-tests"
    depends="compile"
    description="Compiles testing source code">
    
    <mkdir dir="${tmp.test}"/>

    <javac srcdir="${src.test.dir}"
      destdir="${tmp.test}"
      includes="**/*Test.java"
      excludes="**/package.html"
      debug="${debug}"
      deprecation="${deprecation}"
      optimize="${optimize}">
      <classpath refid="build.classpath"/>
      <classpath>
        <pathelement path="${tmp.classes}"/>
        <pathelement location="${junit.jar}"/>
      </classpath>
    </javac>
    
  </target>

  <target name="test"
    depends="compile-tests"
    description="Runs unit tests">

    <echo>No tests exist yet</echo>
    <!--
    <echo message="Running all JUnit tests"/>

    <junit printSummary="yes">
      <formatter type="plain"/>
      <classpath refid="build.classpath"/>
      <classpath>
        <pathelement path="${tmp.classes}"/>
        <pathelement location="${junit.jar}"/>
        <pathelement path="${tmp.test}"/>
      </classpath>
      <batchtest todir="${tmp.test}">
        <fileset dir="${tmp.test}">
          <include name="**/*Test.class"/>
        </fileset>
      </batchtest>
    </junit>
    -->
  </target>


  <!-- ====================​====================​====================​======= -->
  <!-- Creating the distribution -->
  <!-- ====================​====================​====================​======= -->
  <target name="dist" depends="jar,javadocs"
          description="Creates binary distributions">
     <!-- Scripts -->

     <!-- Documentation -->
     <copy todir="${dist.dir}/​docs/api">
    <fileset dir="${tmp.javadocs}" />
     </copy>
  </target>

  <target name="package-dist" depends="dist"
          description="Packages source and binary distribution">
    <!-- When users expand a source archive, we want a top level dir -->
    <copy todir="${tmp.dir}/s​rc/${dist.name}"​>
      <fileset dir="." includes="**"
               excludes="build.prop​erties,${tmp.dir}/"​/>
    </copy>

    <!-- Package using ZIP -->
    <zip zipfile="${tmp.dir}​/${dist.name}.zip"
         basedir="${tmp.dir}" includes="${dist.name}/**"/>
    <zip zipfile="${tmp.dir}​/${dist.name}-src.z​ip"
         basedir="${tmp.dir}/src" includes="${dist.name}/" />

    <!-- Package using TAR/GZIP -->
    <tar tarfile="${tmp.dir}​/${dist.name}.tar" basedir="${tmp.dir}"
         includes="${dist.name}/" />
    <gzip zipfile="${tmp.dir}​/${dist.name}.tar.g​z"
          src="${tmp.dir}/${​dist.name}.tar"/>​
    <delete file="${tmp.dir}/$​{dist.name}.tar"/​>
    <tar tarfile="${tmp.dir}​/${dist.name}-src.t​ar"
         basedir="${tmp.dir}/src" includes="${dist.name}/" />
    <gzip zipfile="${tmp.dir}​/${dist.name}-src.t​ar.gz"
          src="${tmp.dir}/${​dist.name}-src.tar"/​>
    <delete file="${tmp.dir}/$​{dist.name}-src.tar"​/>

    <delete dir="${tmp.dir}/src"/>
  </target>


  <!-- ====================​====================​====================​======= -->
  <!-- Clean up -->
  <!-- ====================​====================​====================​======= -->

  <target name="clean" description="Removes build directory">
    <delete dir="${tmp.dir}"/>
  </target>

  <target name="dist-clean" depends="clean"
          description="Removes distribution and build directories">
    <delete dir="${dist.dir}"/>
  </target>
</project>




--------------------​--------------------​--------------------​---------
To unsubscribe, e-mail: cvs-unsubscribe@jms4​spread.tigris.org
For additional commands, e-mail: cvs-help at jms4spread dot tigris dot org

« Previous message in topic | 1 of 1 | Next message in topic »

Messages

Show all messages in topic

CVS update: /jms4spread dlr Daniel Rall 2002-07-21 16:31:46 PDT
Messages per page: