Changeset 6b25610 for axis/build.xml


Ignore:
Timestamp:
Mar 31, 2011 3:02:12 PM (13 years ago)
Author:
Ted Faber <faber@…>
Branches:
axis_example, compt_changes, info-ops, master
Children:
6a03b9f
Parents:
aee2ac2
Message:

Clean up build.xml

File:
1 edited

Legend:

Unmodified
Added
Removed
  • axis/build.xml

    raee2ac2 r6b25610  
    1919  <property name="src.dir" value="${basedir}"/>
    2020  <property name="lib.dir" value="${basedir}${file.separator}jar"/>
    21   <property name="syslib.dir" value="/usr/local/share/java/classes"/>
    2221  <property name="doc.dir" value="${basedir}${file.separator}doc"/>
    2322  <property name="devdoc.dir" value="${basedir}${file.separator}dev-doc"/>
     
    2524  <property name="classes.dir" value="${build.dir}/classes"/>
    2625  <property name="jar.dir" value="${build.dir}${file.separator}jar"/>
    27   <property name="axis.task.home"
    28     value="/usr/local/tomcat5.5/webapps/axis/WEB-INF/lib"/>
    2926  <property name="keystore.file" value="${basedir}${file.separator}keystore"/>
    30   <property name="wsdl.dir" value="/zod/fedd-repo/wsdl/"/>
     27  <property name="wsdl.dir" value="../wsdl"/>
     28  <property name="cert.pem" value="./emulab.pem"/>
    3129
    3230  <path id="compile.classpath">
     
    4644  </target>
    4745
    48   <target name="compile" depends="wsdl-parse" description="Compile the source">
    49     <mkdir dir="${classes.dir}" />
    50     <javac srcdir="${src.dir}" destdir="${classes.dir}"
    51       classpathref="compile.classpath" includeAntRuntime="no"/>
    52   </target>
    53 
     46  <!-- Check to see if the keystore file exists, if so the keystore.available
     47       property is created. -->
    5448  <target name="keystore.check">
    5549    <available property="keystore.present"
     
    5852
    5953
     54  <!-- Convert ${cert.pem} to a java keystore.  Makes use of the ImportKey
     55       program available from http://www.agentbob.info/agentbob/79-AB.html .
     56       That web page describes this process in detail. -->
    6057  <target name="keys" depends="keystore.check" unless="keystore.present" >
     58    <!-- splitkey.pl splits a combo certificate file (both key and cert) into a
     59         key.pem and cert.pem file for ImportKey -->
    6160    <exec executable="/usr/bin/perl">
    6261      <arg value="./splitkey.pl"/>
    63       <arg file="./emulab.pem"/>
     62      <arg file="${cert.pem}"/>
    6463    </exec>
    6564    <exec executable="openssl">
     
    9291      <arg value="fedd"/>
    9392    </java>
     93    <move file="${user.home}${file.separator}keystore.ImportKey"
     94      tofile="${keystore.file}"/>
    9495    <delete>
    9596      <fileset dir="${basedir}" includes="**/cert.*"/>
    9697      <fileset dir="${basedir}" includes="**/key.*"/>
    9798    </delete>
    98     <move file="${user.home}${file.separator}keystore.ImportKey"
    99       tofile="${keystore.file}"/>
    10099  </target>
    101100
     101  <!-- Documentation targets -->
     102  <target name="doc" description="Generate API documentation">
     103    <mkdir dir="${doc.dir}"/>
     104    <javadoc sourcepath="${src.dir}" destdir="${doc.dir}"
     105      classpathref="compile.classpath" access="public"
     106      noqualifier="java.lang:java.io:java.util:java.security:java.security.cert"/>
     107  </target>
     108
     109  <target name="dev-doc"
     110    description="Generate detailed/developer API documentation">
     111    <mkdir dir="${devdoc.dir}"/>
     112    <javadoc sourcepath="${src.dir}" destdir="${devdoc.dir}"
     113      classpathref="compile.classpath" access="private"
     114      noqualifier="java.lang:java.io:java.util:java.security:java.security.cert"/>
     115  </target>
     116
     117  <!-- Check to see if the wsdl-generated directories exist: if so
     118       the wsdl.available property is set -->
     119  <target name="wsdl.check">
     120    <available file="${basedir}${file.separator}edu" type="dir"
     121      property="wsdl.available"/>
     122  </target>
     123
     124  <!-- Generate wsdl-generated source files if they do not exist.  The
     125       axis-wsdl2java tasks are from axis.  -->
     126  <target name="wsdl-parse" depends="wsdl.check" unless="wsdl.available" >
     127    <axis-wsdl2java url="${wsdl.dir}${file.separator}fedd.wsdl"
     128      output="${basedir}" />
     129    <axis-wsdl2java url="${wsdl.dir}${file.separator}fedd_internal.wsdl"
     130      output="${basedir}" />
     131  </target>
     132
     133  <!-- compile the sources into the build directory.  Depends on the
     134       wsdl-generated files being created. -->
     135  <target name="compile" depends="wsdl-parse" description="Compile the source">
     136    <mkdir dir="${classes.dir}" />
     137    <javac srcdir="${src.dir}" destdir="${classes.dir}"
     138      classpathref="compile.classpath" includeAntRuntime="no"/>
     139  </target>
     140
     141  <!-- Test programs -->
    102142  <target name="multistatus" depends="compile,keys"
    103143    description="run visualizer">
     
    108148      </classpath>
    109149    </java>
    110     <echo message="${user.name}"/>
    111150  </target>
    112151
     
    122161  </target>
    123162
    124   <target name="doc" description="Generate API documentation">
    125     <mkdir dir="${doc.dir}"/>
    126     <javadoc sourcepath="${src.dir}" destdir="${doc.dir}"
    127       classpathref="compile.classpath" access="public"
    128       noqualifier="java.lang:java.io:java.util:java.security:java.security.cert"/>
     163
     164  <target name="terminate" depends="compile,keys"
     165    description="run visualizer">
     166    <java classname="Terminate" fork="true" >
     167      <classpath>
     168        <path refid="compile.classpath"/>
     169        <pathelement path="${classes.dir}"/>
     170      </classpath>
     171      <arg value="${user.name}-test"/>
     172    </java>
    129173  </target>
    130174
    131   <target name="dev-doc" description="Generate API documentation">
    132     <mkdir dir="${devdoc.dir}"/>
    133     <javadoc sourcepath="${src.dir}" destdir="${devdoc.dir}"
    134       classpathref="compile.classpath" access="private"
    135       noqualifier="java.lang:java.io:java.util:java.security:java.security.cert"/>
    136   </target>
    137 
    138   <target name="wsdl.check">
    139     <available file="${basedir}${file.separator}edu" type="dir"
    140       property="wsdl.available"/>
    141   </target>
    142 
    143   <target name="wsdl-parse" depends="wsdl.check" unless="wsdl.available" >
    144     <axis-wsdl2java url="${wsdl.dir}${file.separator}fedd.wsdl" output="${basedir}" />
    145     <axis-wsdl2java url="${wsdl.dir}${file.separator}fedd_internal.wsdl"
    146       output="${basedir}" />
    147   </target>
    148175</project>
Note: See TracChangeset for help on using the changeset viewer.