source: osm/applications/editors/josm/plugins/lakewalker/build.xml@ 6484

Last change on this file since 6484 was 6127, checked in by jrreid, 17 years ago

Add preference to select the default tag applied to the ways, and correct a bug that resulted in the ways not being closed. Also update build.xml to call javac to compile automatically.

File size: 2.5 KB
RevLine 
[5153]1<project name="Lakewalker" default="dist" basedir=".">
[4061]2
[5693]3 <!-- josm "user home" directory depends on the platform used (windows has a different place than unix/linux) -->
4 <property environment="env"/>
5 <condition property="josm.home.dir" value="${env.APPDATA}/JOSM" else="${user.home}/.josm">
6 <and>
7 <os family="windows"/>
8 </and>
9 </condition>
10
[5153]11 <!-- compilation properties -->
12 <property name="josm.build.dir" value="../../core"/>
[5693]13 <property name="josm.plugins.dir" value="${josm.home.dir}/plugins"/>
[5153]14 <property name="josm" location="../../core/dist/josm-custom.jar" />
15 <property name="plugin.build.dir" value="build"/>
[6100]16 <property name="plugin.dist.dir" value="../../dist"/>
[5153]17 <property name="plugin.name" value="${ant.project.name}"/>
[6100]18 <property name="plugin.jar" value="../../dist/${plugin.name}.jar"/>
[5153]19
[4061]20 <property name="josm" location="../../core/dist/josm-custom.jar" />
21
[5197]22 <property name="ant.build.javac.target" value="1.5"/>
23
[5153]24 <target name="init">
25 <mkdir dir="${plugin.build.dir}"/>
26 </target>
27
28 <target name="compile" depends="init">
[4061]29 <mkdir dir="build"></mkdir>
[6127]30 <javac srcdir="src" classpath="${josm}" destdir="build" debug="true">
31 <include name="**/*.java" />
32 </javac>
[5147]33 <mkdir dir="build/images"></mkdir>
[4061]34 <copy todir="build">
[5153]35 <fileset dir="${plugin.build.dir}" casesensitive="yes">
[5147]36 <filename name="**/*.class"/>
37 </fileset>
[4061]38 </copy>
[5147]39 <copy todir="build/images">
40 <fileset dir="images" casesensitive="yes">
41 <filename name="**/*.png"/>
42 </fileset>
43 </copy>
[4061]44 </target>
45
[5153]46 <target name="dist" depends="compile">
47 <jar destfile="${plugin.jar}" basedir="build">
[4061]48 <manifest>
49 <attribute name="Plugin-Class" value="org.openstreetmap.josm.plugins.lakewalker.LakewalkerPlugin" />
50 <attribute name="Plugin-Description" value="Interface to Lakewalker module" />
51 <attribute name="Plugin-Version" value="0.1"/>
52 <attribute name="Author" value="Brent Easton &lt;b.easton@uws.edu.au>"/>
53 </manifest>
54 </jar>
55 </target>
56
57 <target name="clean">
[5153]58 <delete dir="${plugin.build.dir}" />
59 <delete file="${plugin.jar}" />
[4061]60 </target>
61
[5153]62 <target name="install" depends="dist">
[5693]63 <copy file="${plugin.jar}" todir="${josm.plugins.dir}"/>
[5696]64 <copy todir="${josm.plugins.dir}/Lakewalker">
[5147]65 <fileset dir="Lakewalker">
66 <filename name = "*.py"/>
67 </fileset>
68 </copy>
[4061]69 </target>
70
71</project>
Note: See TracBrowser for help on using the repository browser.