Ignore:
Timestamp:
2009-03-08T12:02:49+01:00 (17 years ago)
Author:
stoecker
Message:

cleanup build scripts and manifests

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/imagewaypoint/build.xml

    r12780 r14003  
    1 <project name="imagewaypoint" default="dist" basedir=".">
    2 <!-- compilation properties -->
    3     <property name="josm.build.dir"   value="../../core"/>
    4     <property name="josm.plugins.dir" value="${josm.home.dir}/plugins"/>
    5     <property name="josm"         location="../../core/dist/josm-custom.jar" />
    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     <target name="dist" depends="compile">
    11         <copy todir="build/images">
    12             <fileset dir="images" />
     1<project name="ImageWayPoint" 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" classpath="${josm}" debug="false" destdir="${plugin.build.dir}">
     13            <compilerarg value="-Xlint:deprecation"/>
     14            <compilerarg value="-Xlint:unchecked"/>
     15        </javac>
     16    </target>
     17    <target name="dist" depends="compile,revision">
     18        <copy todir="${plugin.build.dir}/images">
     19            <fileset dir="images"/>
    1320        </copy>
     21        <jar destfile="${plugin.jar}" basedir="${plugin.build.dir}">
     22            <manifest>
     23                <attribute name="Author" value="Flint"/>
     24                <attribute name="Plugin-Class" value="org.insignificant.josm.plugins.imagewaypoint.ImageWayPointPlugin"/>
     25                <attribute name="Plugin-Date" value="${version.entry.commit.date}"/>
     26                <attribute name="Plugin-Description" value="Another plugin to match images to the waypoints in a GPX file. A match is made when the 'name', 'cmt' or 'desc' attribute of a waypoint tag matches the filename of an image."/>
     27                <attribute name="Plugin-Early" value="false"/>
     28                <attribute name="Plugin-Mainversion" value="1465"/>
     29                <attribute name="Plugin-Version" value="${version.entry.commit.revision}"/>
     30            </manifest>
     31        </jar>
     32    </target>
     33    <target name="revision">
    1434        <exec append="false" output="REVISION" executable="svn" failifexecutionfails="false">
    1535            <env key="LANG" value="C"/>
     
    2040        <xmlproperty file="REVISION" prefix="version" keepRoot="false" collapseAttributes="true"/>
    2141        <delete file="REVISION"/>
    22         <delete file="${plugin.jar}"/>
    23         <jar destfile="${plugin.jar}" basedir="build">
    24             <manifest>
    25                 <attribute name="Plugin-Class" value="org.insignificant.josm.plugins.imagewaypoint.ImageWayPointPlugin" />
    26                 <attribute name="Plugin-Description" value="An other geotag plugin for josm. Correlates pictures with GPS tracks if the image name is sorted in the GPX trkpt tag." />
    27                 <attribute name="Plugin-Early" value="false" />
    28                 <attribute name="Plugin-Version" value="${version.entry.commit.revision}"/>
    29                 <attribute name="Plugin-Date" value="${version.entry.commit.date}"/>
    30                 <attribute name="Plugin-Mainversion" value="1180" />
    31             </manifest>
    32         </jar>
    33     </target>
    34     <target name="compile" depends="init">
    35         <echo message="creating ${plugin.jar}"/>
    36         <javac srcdir="src" classpath="${josm}" debug="true" destdir="build">
    37             <compilerarg value="-Xlint:deprecation"/>
    38             <compilerarg value="-Xlint:unchecked"/>
    39             <include name="**/*.java" />
    40         </javac>
    41     </target>
    42     <target name="init">
    43         <mkdir dir="build" />
    4442    </target>
    4543    <target name="clean">
    46         <delete dir="build" />
     44        <delete dir="${plugin.build.dir}"/>
     45        <delete file="${plugin.jar}"/>
     46    </target>
     47    <target name="install" depends="dist">
     48        <property environment="env"/>
     49        <condition property="josm.plugins.dir" value="${env.APPDATA}/JOSM/plugins" else="${user.home}/.josm/plugins">
     50            <and>
     51                <os family="windows"/>
     52            </and>
     53        </condition>
     54        <copy file="${plugin.jar}" todir="${josm.plugins.dir}"/>
    4755    </target>
    4856</project>
Note: See TracChangeset for help on using the changeset viewer.