Browse files

Restore build.xml for Ant use.

  • Loading branch information...
1 parent 8fac62d commit d1e5f611bb55c300d2fbd9fbc82a91e5956c0a26 @rnewman committed with icylisper Jan 18, 2010
Showing with 56 additions and 0 deletions.
  1. +56 −0 build.xml
View
56 build.xml
@@ -0,0 +1,56 @@
+<project name="rabbit" default="jar">
+ <description>
+ Clojure Rabbitmq client
+ </description>
+
+ <property name="build.dir" location="classes"/>
+ <property name="source.dir" location="src"/>
+ <property name="jar.name" location="clojure-rabbitmq.jar"/>
+ <property file="local.properties"/>
+ <available property="hasclojure" file="${clojure.jar}"/>
+ <available property="hascontrib" file="${contrib.jar}"/>
+
+ <target name="checkforjars" depends="init">
+ <condition property="hasjars">
+ <and>
+ <isset property="hasclojure"/>
+ <isset property="hascontrib"/>
+ </and>
+ </condition>
+ </target>
+
+ <target name="clean" description="Remove generated classfiles">
+ <delete dir="${build.dir}"/>
+ </target>
+
+ <target name="init" depends="clean">
+ <tstamp/>
+ <mkdir dir="${build.dir}"/>
+ </target>
+
+ <target name="compile" depends="checkforjars" description="Compile sources" if="hasjars">
+ <java classname="clojure.lang.Compile">
+ <classpath>
+ <path location="${clojure.jar}"/>
+ <path location="${contrib.jar}"/>
+ <path location="${build.dir}"/>
+ <path location="${source.dir}"/>
+
+ <path location="lib/commons-cli-1.1.jar"/>
+ <path location="lib/commons-io-1.2.jar"/>
+ <path location="lib/rabbitmq-client.jar"/>
+ </classpath>
+ <sysproperty key="clojure.compile.path" value="${build.dir}"/>
+ <arg value="org.clojars.rabbitmq"/>
+ </java>
+ </target>
+
+ <target name="jar" description="Create jar file" depends="compile">
+ <jar jarfile="${jar.name}" index="true">
+ <path location="MIT.txt"/>
+ <fileset dir="${source.dir}" includes="**/*.clj"/>
+ <fileset dir="${build.dir}" includes="**/*.class"/>
+ </jar>
+ </target>
+
+</project>

0 comments on commit d1e5f61

Please sign in to comment.