1 | <project name="Duplicate-Way" default="dist" basedir=".">
|
---|
2 |
|
---|
3 | <!-- compilation properties -->
|
---|
4 | <property name="josm.build.dir" value="../../core"/>
|
---|
5 | <property name="josm.home.dir" value="${user.home}/.josm"/>
|
---|
6 | <property name="josm" location="../../core/dist/josm-custom.jar" />
|
---|
7 | <property name="plugin.build.dir" value="build"/>
|
---|
8 | <property name="plugin.dist.dir" value="../../dist"/>
|
---|
9 | <property name="plugin.name" value="${ant.project.name}"/>
|
---|
10 | <property name="plugin.jar" value="../../dist/${plugin.name}.jar"/>
|
---|
11 |
|
---|
12 | <property name="ant.build.javac.target" value="1.5"/>
|
---|
13 |
|
---|
14 | <target name="init">
|
---|
15 | <mkdir dir="${plugin.build.dir}"/>
|
---|
16 | </target>
|
---|
17 |
|
---|
18 |
|
---|
19 | <target name="compile" depends="init">
|
---|
20 | <mkdir dir="build"></mkdir>
|
---|
21 | <mkdir dir="${plugin.build.dir}/images"></mkdir>
|
---|
22 | <copy todir="build">
|
---|
23 | <fileset dir="${plugin.build.dir}" casesensitive="yes">
|
---|
24 | <filename name="**/*.class"/>
|
---|
25 | </fileset>
|
---|
26 | </copy>
|
---|
27 | <copy todir="${plugin.build.dir}/images">
|
---|
28 | <fileset dir="images" casesensitive="yes">
|
---|
29 | <filename name="**/*.png"/>
|
---|
30 | </fileset>
|
---|
31 | </copy>
|
---|
32 | <!-- the code still uses no longer existing Segments, disable compile!
|
---|
33 | <javac srcdir="src" classpath="${josm}" debug="true" destdir="build">
|
---|
34 | <include name="**/*.java" />
|
---|
35 | </javac>-->
|
---|
36 | </target>
|
---|
37 |
|
---|
38 | <target name="dist" depends="compile">
|
---|
39 | <jar destfile="${plugin.jar}" basedir="build">
|
---|
40 | <manifest>
|
---|
41 | <attribute name="Plugin-Class" value="org.openstreetmap.josm.plugins.duplicateway.DuplicateWayPlugin" />
|
---|
42 | <attribute name="Plugin-Description" value="Duplicate Ways with an offset" />
|
---|
43 | <attribute name="Plugin-Version" value="0.1"/>
|
---|
44 | <attribute name="Author" value="Brent Easton <b.easton@uws.edu.au>"/>
|
---|
45 | </manifest>
|
---|
46 | </jar>
|
---|
47 | </target>
|
---|
48 |
|
---|
49 | <target name="clean">
|
---|
50 | <delete dir="${plugin.build.dir}" />
|
---|
51 | <delete file="${plugin.jar}" />
|
---|
52 | </target>
|
---|
53 |
|
---|
54 | <target name="install" depends="dist">
|
---|
55 | <copy file="${plugin.jar}" todir="${user.home}/.josm/plugins"/>
|
---|
56 | </target>
|
---|
57 |
|
---|
58 | </project>
|
---|