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
|
<project name="jBCrypt" default="dist" basedir=".">
<description>Buildfile for the jBCrypt project</description>
<property name="src" location="src"/>
<property name="test-src" location="test"/>
<property name="build" location="build"/>
<property name="test-build" location="test-build"/>
<target name="init">
<mkdir dir="${build}"/>
<mkdir dir="${test-build}"/>
</target>
<target name="clean">
<delete dir="${build}"/>
<delete dir="${test-build}"/>
</target>
<target name="build" depends="init">
<javac includeantruntime="false" target="1.6" srcdir="${src}" destdir="${build}"/>
</target>
<target name="build-tests" depends="init, build">
<javac includeantruntime="false" target="1.6" srcdir="${test-src}" destdir="${test-build}">
<classpath>
<pathelement path="${build}"/>
<pathelement path="/usr/share/java/junit4.jar"/>
</classpath>
</javac>
</target>
<target name="test" depends="build-tests">
<junit printsummary="on" showoutput="on">
<classpath>
<pathelement path="${build}"/>
<pathelement path="${test-build}"/>
<pathelement path="/usr/share/java/junit4.jar"/>
</classpath>
<test name="org.mindrot.jbcrypt.TestBCrypt"/>
</junit>
</target>
<target name="dist" depends="build">
<jar destfile="jbcrypt.jar" basedir="${build}"/>
</target>
</project>
|