File:  [mozdev] / bookie / server / build.xml
Revision 1.3: download - view: text, annotated - select for diffs - revision graph
Tue Apr 13 07:03:27 2004 UTC (14 years, 11 months ago) by will
Branches: MAIN
CVS tags: HEAD
Update to Jisp 3.0.0.
Note that databases generated with this version of Jisp are not compatible with older versions of Jisp.
Source code has also been generally been reorganized by Eclipse.

<project name="bookie" default="dist" basedir=".">

  <property file="${user.name}.properties"/>
  <property file="build.properties" />    

  <!--
 ========================================================================
   Set the properties related to the build area
 ========================================================================
  -->

  <path id="project.class.path">
    <fileset id="jar.files" dir="${lib.dir}">
      <include name="**.jar"/>
    </fileset>
  </path>
  <target name="all" depends="clean, dist"/>
    
  <!--
  ========================================================================
   Initialize the build. Must be called by all targets
  ========================================================================
  -->
  <target name="init">
    <tstamp/>
  </target>

  <!--
  ========================================================================
     Compiles the source directory
  ========================================================================
  -->
  
  <!--
    Compile the java classes to the build directory.
  -->
  <target name="compile">
    <mkdir dir="${classes.dir}"/>
    <javac srcdir="${src.dir}"
        destdir="${classes.dir}"
        debug="${debug}"
        deprecation="${deprecation}"
        classpathref="project.class.path"></javac>
  </target>

  <!--
    Jar some files
  -->
  <target name="dist" depends="compile">
    <mkdir dir="${dist.dir}"/>
   
    <!-- make a manifest file. -->
    <manifest file="${manifest.file}">
      <attribute name="Built-By" value="${user.name}"/>
      <attribute name="Main-Class" value="${main.class}"/>
    </manifest>

    <!-- Make one huge ass jar file containing everything we need. -->
    <zip destfile="${server.jar}" compress="true">
      <fileset dir="${classes.dir}">
        <include name="**/*.class"/>
        <include name="**/*.properties"/>
        <include name="**/*.xml"/>
      </fileset>
      
      <fileset dir="${conf.dir}">
        <include name="**/*.properties"/>
        <include name="**/*.xml"/>
      </fileset>
      
      <fileset dir="${resources.dir}">
        <include name="**/*.properties"/>
        <include name="**/*.xml"/>
      </fileset>

      <zipfileset src="${xmlparser.jar}">
        <exclude name="META-INF/MANIFEST.MF"/>
      </zipfileset>
      
      <zipfileset src="${xmlrpc.jar}">
        <exclude name="META-INF/MANIFEST.MF"/>
      </zipfileset>

      <zipfileset src="${log4j.jar}">
        <exclude name="META-INF/MANIFEST.MF"/>
      </zipfileset>

      <zipfileset src="${servlet.jar}">
        <exclude name="META-INF/MANIFEST.MF"/>
      </zipfileset>
      
      <zipfileset src="${jisp.jar}">
        <exclude name="META-INF/MANIFEST.MF"/>
      </zipfileset>      

      <zipfileset dir="${build.dir}" includes="**/MANIFEST.MF" fullpath="META-INF/MANIFEST.MF"/>
    </zip>

    <zip zipfile="${server.zip}">
      <fileset dir="${dist.dir}"/>
    </zip>
  </target>  

  <!--
   ========================================================================
     Generate the javadoc
   ========================================================================
  -->
  <target name="javadoc">
    <mkdir dir="${javadoc.dir}"/>
    <javadoc
        sourcepath="${src.dir}"
        packagenames="com.tersesystems.bookie.*"
        destdir="${javadoc.dir}"
        author="true"
        public="true"
        version="true"
        use="true">
      <classpath refid="project.class.path"/>
    </javadoc>
  </target>

  <target name="clean" depends="init">
    <delete dir="${build.dir}"/>
    <delete dir="${dist.dir}"/>
  </target>

</project>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>