diff java/build.xml @ 44:9d3769896d66

created java folder and simple build script
author Robert McIntyre <rlm@mit.edu>
date Tue, 06 Mar 2012 21:53:31 -0600
parents
children 09b3bc0b71b5
line wrap: on
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/java/build.xml	Tue Mar 06 21:53:31 2012 -0600
     1.3 @@ -0,0 +1,43 @@
     1.4 +<project name="gb-bindings" default="dist" basedir="."> 
     1.5 +
     1.6 +  <property name="build" value="build"/>
     1.7 +  <property name="src" value="src"/>
     1.8 +  <property name="dist" value="dist"/>
     1.9 +  <property name="headers"  value="headers"/>
    1.10 +  <property name="artifacts" value="../artifacts"/>
    1.11 +
    1.12 +  <target name="prepare">
    1.13 +    <mkdir dir="${build}"/>
    1.14 +    <mkdir dir="${headers}"/>
    1.15 +    <mkdir dir="${dist}"/> 
    1.16 +  </target>
    1.17 +
    1.18 +  <target name="compile" depends="prepare" >
    1.19 +    <javac srcdir="${src}" destdir="${build}"
    1.20 +	   includeantruntime="false"/>
    1.21 +  </target>
    1.22 +
    1.23 +  <target name="native" depends="prepare, compile" >
    1.24 +    <javah class="com.aurellem.gb.Gb"
    1.25 +	   destdir="${headers}"
    1.26 +	   classpath="${build}"/>
    1.27 +  </target>
    1.28 +
    1.29 +  <target name="dist">
    1.30 +    <jar jarfile="${dist}/gb-bindings.jar">
    1.31 +      <fileset dir="${build}"/>
    1.32 +      <fileset dir="${src}"/>
    1.33 +    </jar>
    1.34 +  </target>
    1.35 +
    1.36 +  <target name="all" depends="native, dist"/>
    1.37 +    
    1.38 +
    1.39 +  <target name="clean" > 
    1.40 +    <delete dir="${build}"/> 
    1.41 +    <delete dir="${dist}"/> 
    1.42 +    <delete dir="${headers}"/>
    1.43 +  </target> 
    1.44 +
    1.45 +</project>
    1.46 +