This is the mail archive of the
kawa@sources.redhat.com
mailing list for the Kawa project.
building Kawa with Ant
- To: kawa at sources dot redhat dot com
- Subject: building Kawa with Ant
- From: Per Bothner <per at bothner dot com>
- Date: Wed, 14 Nov 2001 00:06:58 -0800
I've started hacking together a build.xml for building Kawa with Ant.
My first attempt is attached below, but I could do with some help from
people with experience with Ant. (Jim White offered to do this, but
then I started reading the Ant manual and hacking things together and
shortly I had what you see below!)
The most immediate problem is the "jar" target. It builds a .jar
file - but one without a single .class files. Anyone see what I am
doing wrong?
Of course this Ant file is missing a lot of needed features. It does
not handle
any of the optional features of the configure script, leaving out all the
xml-related code (including xquery) and all the jemacs code. Also,
it has only been tested on Linux, so there may be places that will
break on Windows - and of course WIndows support is the main
point of the exercise!
What does work is that "ant classes" builds enough of the classes that
you can run "java kawa.repl"; and "ant clean" removes all the genaerated
classes etc.
--Per
<?xml version="1.0"?>
<!-- A build file for use by Ant to build Kawa. -->
<project name="Kawa" default="all">
<property name="version" value="1.6.97"/>
<property name="debug" value="true" />
<property name="deprecation" value="false" />
<property name="optimize" value="true" />
<property name="srcdir" value="."/>
<property name="builddir" value="."/>
<target name="all" depends="classes,jar"/>
<target name="classes">
<copy todir="gnu/lists">
<fileset dir="gnu/lists"/>
<mapper type="glob" from="*.java.in" to="*.java"/>
<filterset>
<filter token="if WITHOUT COLLECTIONS" value="/*" />
<filter token="endif WITHOUT COLLECTIONS" value="*/" />
<filter token="if WITH COLLECTIONS" value="" />
<filter token="endif WITH COLLECTIONS" value="" />
<filter token="-*-Java-*-" value="Automatically generated file - DO NOT EDIT!. -*- buffer-read-only: t -*-" />
</filterset>
</copy>
<javac srcdir="${srcdir}"
destdir="${builddir}"
debug="${debug}"
deprecation="${deprecation}"
optimize="${optimize}" >
<include name="gnu/bytecode/"/>
<include name="gnu/lists/"/>
<include name="gnu/math/"/>
<include name="gnu/text/"/>
<include name="gnu/mapping/"/>
<include name="gnu/expr/"/>
<include name="gnu/kawa/functions/"/>
<include name="gnu/kawa/lispexpr/"/>
<include name="gnu/kawa/reflect/"/>
<include name="gnu/commonlisp/lang/"/>
<include name="kawa/lang/"/>
<include name="kawa/standard/"/>
<include name="kawa/*.java"/>
</javac>
<java classname="kawa.repl">
<arg line="-d . -P kawa.lib. --module-static -C"/>
<arg path="kawa/lib/std_syntax.scm"/>
<arg path="kawa/lib/reflection.scm"/>
<arg path="kawa/lib/syntax.scm"/>
<arg path="kawa/lib/lists.scm"/>
<arg path="kawa/lib/thread.scm"/>
<arg path="kawa/lib/characters.scm"/>
<arg path="kawa/lib/files.scm"/>
<arg path="kawa/lib/keywords.scm"/>
<arg path="kawa/lib/ports.scm"/>
<arg path="kawa/lib/misc.scm"/>
<arg path="kawa/lib/numbers.scm"/>
<arg path="kawa/lib/strings.scm"/>
<arg path="kawa/lib/vectors.scm"/>
<arg path="kawa/lib/uniform.scm"/>
<arg path="kawa/lib/system.scm"/>
<arg path="kawa/lib/trace.scm"/>
<arg path="kawa/lib/windows.scm"/>
</java>
</target>
<target name="jar">
<jar jarfile="kawa-${version}.jar" manifest="${srcdir}/jar-manifest">
<include name="**/*.class"/>
</jar>
</target>
<target name="clean">
<delete>
<fileset dir="gnu/lists" includes="AbstractSequence.java,Convert.java,Sequence.java,SeqPosition.java,SimpleVector.java"/>
<fileset dir="." includes="**/*.class"/>
</delete>
</target>
</project>