rmihello/build.xml
author Markus Bröker <mbroeker@volpe.spectre.org>
Wed, 18 Aug 2010 16:17:00 +0200
changeset 142 d6bce20b455e
parent 92 0bc2646daa82
permissions -rw-r--r--
asm/decimal.c: provide a default wordsize

<?xml version="1.0"?>
<project name="Hello" basedir="." default="jar">
	<property name="project" value="Hello" />
	<property name="package.name" value="example.hello" />
	<property name="package.dir" value="example/hello" />
	<property name="jar.file" value="bin/hello.jar" />
	<property name="classpath.dir" value="/usr/local/lib/classes" />
	<property name="www.dir" value="/var/www/localhost/htdocs/classes" />

	<property name="distributable.exts"
		value="**/*.class,**/*.gif,**/*.html,**/*.jar,**/*.jnlp,**/*.jpg,**/*.png" />
	<path id="classpath">
		<pathelement location="." />
	</path>

	<!-- Targets -->
	<target name="clean">
		<echo
			message="deleting all class- and jar-files  in ${package.dir} tree" />
		<delete>
			<fileset dir="${package.dir}" includes="**/*.class" />
			<fileset dir="." includes="**/*.*~" defaultexcludes="no" />
		</delete>

		<delete file="${jar.file}" />
	</target>

	<target name="compile">
		<echo message="compiling ${package.dir} tree." />
		<javac source="1.5" target="1.5" srcdir="${package.dir}"
			sourcepath="${basedir}" debug="on">
			<classpath refid="classpath" />
		</javac>
	</target>

	<target name="jar" depends="compile">
		<property environment="env" />
		<jar destfile="${jar.file}" basedir="${basedir}"
			includes="example/"
			manifest="${project}.manifest" />
	</target>

	<target name="post" depends="jar">
		<signjar jar="${jar.file}" alias="spectre" storepass="${env.jsp}" />
		<copy file="${jar.file}" todir="${www.dir}"/>
	</target>

	<target name="client" depends="compile">
		<java classname="${package.name}.Client"
			failonerror="true" fork="yes">
			<classpath refid="classpath" />
		</java>
	</target>

	<target name="server" depends="compile">
		<java classname="${package.name}.Server"
			failonerror="true" fork="yes">
			<classpath refid="classpath" />
		</java>
	</target>
</project>