source: osm/applications/editors/josm/plugins/routes/build.xml@ 17542

Last change on this file since 17542 was 17542, checked in by guggis, 15 years ago

Updating to JOSM r2082

File size: 3.3 KB
Line 
1<project name="routes" default="dist" basedir=".">
2 <property name="josm" location="../../core/dist/josm-custom.jar"/>
3 <property name="plugin.dist.dir" value="../../dist"/>
4 <property name="plugin.build.dir" value="build"/>
5 <property name="plugin.jar" value="${plugin.dist.dir}/${ant.project.name}.jar"/>
6 <property name="ant.build.javac.target" value="1.5"/>
7 <target name="init">
8 <mkdir dir="${plugin.build.dir}"/>
9 </target>
10 <target name="compile" depends="init">
11 <echo message="creating ${plugin.jar}"/>
12 <javac srcdir="src" debug="true" destdir="${plugin.build.dir}">
13 <compilerarg value="-Xlint:deprecation"/>
14 <compilerarg value="-Xlint:unchecked"/>
15 <classpath>
16 <pathelement location="${josm}"/>
17 <fileset dir="lib">
18 <include name="**/*.jar"/>
19 </fileset>
20 </classpath>
21 </javac>
22 <copy file="src/org/openstreetmap/josm/plugins/routes/xml/routes.xml" todir="${plugin.build.dir}/org/openstreetmap/josm/plugins/routes/xml"/>
23 <copy file="src/org/openstreetmap/josm/plugins/routes/xml/routes.xsd" todir="${plugin.build.dir}/org/openstreetmap/josm/plugins/routes/xml"/>
24
25 </target>
26 <target name="dist" depends="compile,revision">
27 <jar destfile="${plugin.jar}" basedir="${plugin.build.dir}">
28 <zipfileset src="lib/jsr173-1.0_api.jar" includes="**/*"/>
29 <zipfileset src="lib/jaxb-api.jar" includes="**/*"/>
30 <zipfileset src="lib/jaxb-impl.jar" includes="**/*.class"/>
31 <zipfileset src="lib/activation.jar" includes="**/*.class"/>
32 <manifest>
33 <attribute name="Author" value="Jiri Klement"/>
34 <attribute name="Plugin-Class" value="org.openstreetmap.josm.plugins.routes.RoutesPlugin"/>
35 <attribute name="Plugin-Date" value="${version.entry.commit.date}"/>
36 <attribute name="Plugin-Description" value="Renders routes (bus, hiking trails, bicycle routes, ..). Route types must be defined in routes.xml file in plugin directory"/>
37 <attribute name="Plugin-Mainversion" value="2082"/>
38 <attribute name="Plugin-Version" value="${version.entry.commit.revision}"/>
39 </manifest>
40 </jar>
41 </target>
42 <target name="revision">
43 <exec append="false" output="REVISION" executable="svn" failifexecutionfails="false">
44 <env key="LANG" value="C"/>
45 <arg value="info"/>
46 <arg value="--xml"/>
47 <arg value="."/>
48 </exec>
49 <xmlproperty file="REVISION" prefix="version" keepRoot="false" collapseAttributes="true"/>
50 <delete file="REVISION"/>
51 </target>
52 <target name="clean">
53 <delete dir="${plugin.build.dir}"/>
54 <delete file="${plugin.jar}"/>
55 </target>
56 <target name="install" depends="dist">
57 <property environment="env"/>
58 <condition property="josm.plugins.dir" value="${env.APPDATA}/JOSM/plugins" else="${user.home}/.josm/plugins">
59 <and>
60 <os family="windows"/>
61 </and>
62 </condition>
63 <copy file="${plugin.jar}" todir="${josm.plugins.dir}"/>
64 </target>
65</project>
Note: See TracBrowser for help on using the repository browser.