source: subversion/applications/editors/josm/plugins/DirectUpload/build.xml @ 12640

Last change on this file since 12640 was 12588, checked in by Dirk Stoecker, 11 years ago

updated a lot

File size: 2.4 KB
Line 
1<project name="DirectUpload" 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="plugin.build.dir"     value="build"/>
7  <property name="plugin.dist.dir"      value="../../dist"/>
8  <property name="plugin.name"          value="${ant.project.name}"/>
9  <property name="plugin.jar"           value="../../dist/${plugin.name}.jar"/>
10
11  <!-- point to your JOSM directory -->
12  <property name="josm" location="../../core/dist/josm-custom.jar" />
13
14  <property name="ant.build.javac.target" value="1.5"/>
15 
16  <target name="init">
17    <mkdir dir="${plugin.build.dir}"/>
18  </target>
19
20  <target name="compile" depends="init">
21    <echo message="creating ${plugin.jar}"/>
22    <javac srcdir="src" classpath="${josm}" destdir="build" debug="true" encoding="UTF-8">
23      <compilerarg value="-Xlint:deprecation"/>
24      <include name="**/*.java" />
25    </javac>
26  </target>
27
28
29  <target name="dist" depends="clean, compile">
30    <copy todir="build/images">
31      <fileset dir="images"/>
32    </copy>
33    <exec append="false" output="REVISION" executable="svn" failifexecutionfails="false">
34      <env key="LANG" value="C"/>
35      <arg value="info"/>
36      <arg value="--xml"/>
37      <arg value="."/>
38    </exec>
39    <xmlproperty file="REVISION" prefix="version" keepRoot="false" collapseAttributes="true"/>
40    <delete file="REVISION"/>
41    <jar destfile="${plugin.jar}" basedir="build">
42      <manifest>
43
44        <attribute name="Plugin-Class" value="org.openstreetmap.josm.plugins.DirectUpload.UploadDataGuiPlugin" />
45        <attribute name="Plugin-Description" value="Uploads GPS traces to openstreetmap.org" />
46        <attribute name="Plugin-Author" value="Subhodip Biswas :subhodipbiswas@gmail.com" />
47        <attribute name="Plugin-Version" value="${version.entry.commit.revision}"/>
48        <attribute name="Plugin-Mainversion" value="1180"/>
49        <attribute name="Plugin-Date" value="${version.entry.commit.date}"/>
50      </manifest>
51    </jar>
52  </target>
53
54  <!-- clean target -->
55  <target name="clean">
56    <delete dir="${plugin.build.dir}" />
57    <delete file="${plugin.jar}" />
58  </target>
59
60  <target name="install" depends="dist">
61    <copy file="${plugin.jar}" todir="${user.home}/.josm/plugins"/>
62  </target>
63
64  <target name="test" depends="install">
65    <java jar="${josm}" fork="true">
66    </java>
67  </target>
68       
69</project>
Note: See TracBrowser for help on using the repository browser.