Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Tree: 5f52be54c2
Fetching contributors…

Cannot retrieve contributors at this time

124 lines (96 sloc) 3.444 kB
<project name="dejour" basedir="." default="all"
xmlns:ivy="antlib:org.apache.ivy.ant">
<property environment="env"/>
<property name="dejour-version" value="d"/>
<target name="install-ivy" description="install ivy">
<path id="ivy.lib.path">
<pathelement location="ivy.jar"/>
</path>
<taskdef resource="org/apache/ivy/ant/antlib.xml"
uri="antlib:org.apache.ivy.ant"
classpathref="ivy.lib.path" />
</target>
<property name="pattern-with-rev"
value="${basedir}/downloads/[conf]/[artifact]-[revision].[ext]"/>
<target name="downloads" depends="install-ivy">
<ivy:retrieve pattern="${pattern-with-rev}"/>
</target>
<target name="init" depends="downloads"/>
<target name="clj.exe" depends="init">
<exec dir="c_src" executable="make">
<arg value="release"/>
</exec>
</target>
<macrodef name="create-dejour-release">
<attribute name="name"/>
<attribute name="rel-name"
default="dejour-@{name}${dejour-version}"/>
<sequential>
<mkdir dir="build/@{rel-name}/lib"/>
<copy todir="build/@{rel-name}">
<fileset dir="${basedir}">
<include name="bin/**/*"/>
<include name="examples/**/*"/>
</fileset>
</copy>
<copy tofile="build/@{rel-name}/syslib/jline.jar" flatten="true">
<fileset dir="${basedir}">
<include name="downloads/jline/jline*.jar"/>
</fileset>
</copy>
<copy todir="build/@{rel-name}/lib" flatten="true">
<fileset dir="${basedir}">
<include name="downloads/@{name}/**/*"/>
</fileset>
</copy>
<chmod perm="ugo+x">
<fileset dir="build/@{rel-name}"/>
</chmod>
<echo>name = @{name}</echo>
<echo>rel-name = @{rel-name}</echo>
<zip destfile="build/@{rel-name}.zip"
basedir="build/"
includes="@{rel-name}/**/*"/>
<tar destfile="build/@{rel-name}.tar">
<tarfileset dir="build" filemode="755">
<include name="@{name}/bin/**/*"/>
</tarfileset>
<tarfileset dir="build">
<include name="@{rel-name}/**/*"/>
<exclude name="@{rel-name}/bin/**/*"/>
</tarfileset>
</tar> </sequential>
</macrodef>
<target name="all" depends="init" >
<create-dejour-release name="minimal-1.2.1"/>
<create-dejour-release name="complete-1.2.1"/>
<create-dejour-release name="minimal-1.3.0"/>
<create-dejour-release name="complete-1.3.0"/>
</target>
<target name="everything" depends="clj.exe, all"/>
<macrodef name="test-dejour-release">
<attribute name="ivy-conf-name"/>
<attribute name="name" default="dejour-@{ivy-conf-name}"/>
<sequential>
<java fork="true" failonerror="true" classname="clojure.main">
<env key="PATH" value="build/@{name}/bin${path.separator}${env.PATH}"/>
<classpath>
<fileset dir="build/@{name}/lib">
<include name="*.jar"/>
</fileset>
</classpath>
<arg value="${basedir}/test/dejour-tests.clj"/>
</java>
</sequential>
</macrodef>
<target name="test">
<test-dejour-release ivy-conf-name="complete-1.2.1${dejour-version}"/>
</target>
<target name="clean">
<delete dir="build" />
<delete dir="downloads" />
<exec dir="c_src" executable="make">
<arg value="clean"/>
</exec>
</target>
</project>
Jump to Line
Something went wrong with that request. Please try again.