Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: b84b4825e7
Fetching contributors…

Cannot retrieve contributors at this time

file 62 lines (54 sloc) 1.953 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62
<?xml version="1.0"?>
<project name="incanter" default="jar">

  <description>
    Compile Incanter into a Java JAR.
  </description>

  <property name="src" location="src" />
  <property name="build" location="build" />
  <property name="lib" location="lib" />
  <property name="clojure.jar" location="${lib}/clojure.jar" />
  <property name="clojure-contrib.jar" location="${lib}/clojure-contrib.jar" />
  <property name="colt.jar" location="${lib}/parallelcolt-0.7.2.jar" />
  <property name="jarfile" location="incanter.jar" />
  <property name="LICENSE" location="epl-v10.html" />

  <target name="init">
    <mkdir dir="${build}" />
  </target>
  
  <target name="compile-java" depends="init"
          description="Compile Java sources.">
    <javac srcdir="${src}" destdir="${build}" includeJavaRuntime="yes"
           debug="true" target="1.5">
      <classpath>
        <path location="${src}"/>
        <path location="${clojure.jar}"/>
        <path location="${colt.jar}"/>
      </classpath>
    </javac>
  </target>

  <target name="compile-clojure" depends="compile-java"
          description="Compile Clojure sources.">
    <java classname="clojure.lang.Compile" failonerror="true">
      <classpath>
        <path location="${src}"/>
        <path location="${clojure.jar}"/>
        <path location="${clojure-contrib.jar}"/>
        <path location="${colt.jar}"/>
      </classpath>
      <sysproperty key="clojure.compile.path" value="${build}"/>
    </java>
  </target>

  <target name="jar" depends="compile-clojure">
    <jar jarfile="${jarfile}" >
      <fileset dir="${build}" includes="**/*.class"/>
      <fileset dir="${src}" includes="**/*.clj"/>
      <fileset dir="${src}" includes="**/*.java"/>
      <manifest>
        <attribute name="Class-Path" value="."/>
      </manifest>
    </jar>
  </target>
  
  <target name="clean">
    <delete file="${jarfile}"/>
    <delete dir="${build}" />
  </target>
  
</project>
Something went wrong with that request. Please try again.