| <?xml version="1.0" encoding="UTF-8"?> |
| <project name="glowstone" default="build" xmlns:ivy="antlib:org.apache.ivy.ant"> |
| <property name="src" location="src" /> |
| <property name="bin" location="bin" /> |
| <property name="lib" location="lib" /> |
| <property name="doc" location="doc" /> |
| |
| <path id="binaries"> |
| <pathelement path="${bin}" /> |
| </path> |
| |
| <path id="libraries"> |
| <fileset dir="${lib}"> |
| <include name="*.jar" /> |
| </fileset> |
| </path> |
| |
| <path id="master"> |
| <path refid="binaries" /> |
| <path refid="libraries" /> |
| </path> |
| |
| <fileset id="sources" dir="${src}"> |
| <include name="**/*.java" /> |
| </fileset> |
| |
| <target name="init"> |
| <mkdir dir="${bin}" /> |
| <mkdir dir="${lib}" /> |
| </target> |
| |
| <target name="resolve" depends="init"> |
| <ivy:retrieve pattern="${lib}/[artifact]-[revision].[ext]" sync="true" /> |
| </target> |
| |
| <target name="build" depends="init"> |
| <javac srcdir="${src}" destdir="${bin}" includeantruntime="false"> |
| <classpath refid="libraries" /> |
| </javac> |
| </target> |
| |
| <target name="clean"> |
| <delete dir="${bin}" /> |
| <delete dir="${doc}" /> |
| </target> |
| |
| <target name="rebuild" depends="clean, build" /> |
| |
| <target name="run" depends="build"> |
| <java classpathref="master" fork="true" classname="net.lightstone.Server" /> |
| </target> |
| |
| <target name="doc" depends="init"> |
| <javadoc sourcepath="${src}" classpathref="master" destdir="${doc}" |
| access="private" author="true" version="true" use="true" |
| windowtitle="Glowstone Documentation"> |
| <doctitle><![CDATA[<h1>Glowstone Documentation</h1>]]></doctitle> |
| <link href="http://download.oracle.com/javase/6/docs/api/" /> |
| <link href="http://docs.jboss.org/netty/3.2/api/" /> |
| <link href="http://jruby.org/apidocs/" /> |
| </javadoc> |
| </target> |
| </project> |