| 5 | | <property name="build" value="classes" /> |
| 6 | | <property name="run" value="org.rapla.gui.Start" /> |
| 7 | | <property name="db_driver" value="lib/mm.mysql-2.0.2-bin.jar"/> |
| 8 | | <property name="xml_parser_lib1" value="lib/crimson.jar"/> |
| 9 | | <property name="xml_parser_lib2" value="lib/jaxp.jar"/> |
| 10 | | <property name="rapla.home" /> |
| 11 | | <property name="config_path" value="rapla.properties" /> |
| | 5 | <property name="build" value="build" /> |
| | 6 | <property name="dist" value="dist" /> |
| | 7 | <path id="classpath"> |
| | 8 | <fileset dir="./lib"> |
| | 9 | <include name="*.jar"/> |
| | 10 | </fileset> |
| | 11 | </path> |
| | 12 | |
| 43 | | <jar jarfile="lib/Rapla.jar" basedir="${build}" /> |
| 44 | | </target> |
| 45 | | |
| 46 | | <target name="run" depends="build"> |
| 47 | | <antcall target="run_with_config"/> |
| 48 | | <!-- antcall target="run_without_config" /--> |
| 49 | | </target> |
| 50 | | |
| 51 | | <target name="run_with_config" if="config_path"> |
| 52 | | <echo message="Using Class : ${run}"/> |
| 53 | | <echo message="With Config: ${config_path}"/> |
| 54 | | <java classname="${run}" fork="yes"> |
| 55 | | <!--jvmarg value="-Dorg.xml.sax.driver=org.apache.crimson.parsers.Parser2"/--> |
| 56 | | <!--jvmarg value="-Dorg.xml.sax.driver=org.apache.xerces.parsers.SAXParser"/--> |
| 57 | | <classpath> |
| 58 | | <pathelement path="classes" /> |
| 59 | | <pathelement path="${db_driver}" /> |
| 60 | | <pathelement path="${xml_parser_lib1}" /> |
| 61 | | <pathelement path="${xml_parser_lib2}" /> |
| 62 | | </classpath> |
| 63 | | <arg value="${config_path}"/> |
| 64 | | </java> |
| 65 | | </target> |
| 66 | | |
| 67 | | <target name="run_without_config" unless="config_path"> |
| 68 | | <echo message="Using Class : ${run}"/> |
| 69 | | <echo message="Without Config"/> |
| 70 | | <java classname="${run}" fork="yes"> |
| 71 | | <classpath> |
| 72 | | <pathelement path="classes" /> |
| 73 | | <pathelement path="${db_driver}" /> |
| 74 | | <pathelement path="${xml_parser_lib1}" /> |
| 75 | | <pathelement path="${xml_parser_lib2}" /> |
| 76 | | </classpath> |
| 77 | | </java> |
| | 37 | <jar jarfile="${build}/rapla.jar" basedir="${build}/classes" /> |
| | 41 | <mkdir dir="${dist}" /> |
| | 42 | <mkdir dir="${dist}/lib" /> |
| | 43 | <copy todir="${dist}/lib" > |
| | 44 | <fileset dir="lib" > |
| | 45 | <include name="crimson.jar" /> |
| | 46 | <include name="jaxp.jar" /> |
| | 47 | <include name="mm.mysql-2.0.2-bin.jar" /> |
| | 48 | </fileset> |
| | 49 | <fileset dir="build" > |
| | 50 | <include name="rapla.jar" /> |
| | 51 | </fileset> |
| | 52 | </copy> |
| | 53 | <mkdir dir="${dist}/html" /> |
| | 54 | <copy todir="${dist}" > |
| | 55 | <fileset dir="html" > |
| | 56 | <include name="**" /> |
| | 57 | </fileset> |
| | 58 | </copy> |
| | 59 | <copy todir="${dist}" > |
| | 60 | <fileset dir="." > |
| | 61 | <include name="README" /> |
| | 62 | <include name="INSTALL" /> |
| | 63 | <include name="dummydb.sql" /> |
| | 64 | <include name="rapladb.sql" /> |
| | 65 | <include name="rapla.properties" /> |
| | 66 | <include name="data.xml" /> |
| | 67 | <include name="start.sh" /> |
| | 68 | <include name="start.bat" /> |
| | 69 | </fileset> |
| | 70 | </copy> |
| | 71 | <chmod perm="ugo+rx"> |
| | 72 | <fileset dir="${dist}"> |
| | 73 | <include name="start.*"/> |
| | 74 | </fileset> |
| | 75 | </chmod> |