Changeset 7133 in josm for trunk/build.xml


Ignore:
Timestamp:
2014-05-15T17:01:12+02:00 (5 years ago)
Author:
Don-vip
Message:

remove generated Java files from SVN, integrate JAXB 2.2.7 to build them during compilation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/build.xml

    r7085 r7133  
    55**    ant clean
    66**    ant dist
    7 ** This will create 'josm-custom.jar'  in directory 'dist'. See also
     7** This will create 'josm-custom.jar' in directory 'dist'. See also
    88**   https://josm.openstreetmap.de/wiki/CreateBuild
    99**
     
    1515    <property name="javacc.home" location="tools"/>
    1616    <property name="mapcss.dir" location="${src.dir}/org/openstreetmap/josm/gui/mappaint/mapcss"/>
     17    <property name="imagerytypes.dir" location="${src.dir}/org/openstreetmap/josm/data/imagery/types"/>
    1718    <!-- build parameter: compression level (ant -Dclevel=N)
    1819             N ranges from 0 (no compression) to 9 (maximum compression)
     
    125126            <zipfileset dir="data" prefix="data"/>
    126127            <zipfileset dir="styles" prefix="styles"/>
    127             <zipfileset dir="src/org/openstreetmap/gui/jmapviewer/images" prefix="org/openstreetmap/gui/jmapviewer/images"/>
     128            <zipfileset dir="${src.dir}/org/openstreetmap/gui/jmapviewer/images" prefix="org/openstreetmap/gui/jmapviewer/images"/>
    128129            <!-- All jar files necessary to run only JOSM (no tests) -->
    129130            <!-- <zipfileset src="lib/metadata-extractor-2.3.1-nosun.jar"/>  -->
     
    198199        </exec>
    199200    </target>
    200     <target name="compile" depends="init,javacc">
     201    <target name="jaxb" depends="init" unless="jaxb.notRequired">
     202        <taskdef name="xjc" classname="com.sun.tools.xjc.XJCTask">
     203            <classpath>
     204                <fileset dir="tools/jaxb" includes="*.jar"/>
     205            </classpath>
     206        </taskdef>
     207        <xjc schema="data_nodist/wms-cache.xsd" destdir="${src.dir}" encoding="UTF-8">
     208            <depends dir="${src.dir}/org/openstreetmap/josm/data/imagery" includes="WmsCache.java"/>
     209            <produces dir="${imagerytypes.dir}" includes="*.java"/>
     210        </xjc>
     211    </target>
     212    <target name="compile" depends="init,javacc,jaxb">
    201213        <!-- COTS -->
    202         <javac srcdir="src" includes="com/**,oauth/**,org/apache/commons/codec/**,org/glassfish/**" nowarn="on"
     214        <javac srcdir="${src.dir}" includes="com/**,oauth/**,org/apache/commons/codec/**,org/glassfish/**" nowarn="on"
    203215            destdir="build" target="1.7" source="1.7" debug="on" includeantruntime="false" createMissingPackageInfoClass="false" encoding="iso-8859-1">
    204216            <!-- get rid of "internal proprietary API" warning -->
     
    206218        </javac>
    207219        <!-- JMapViewer/JOSM -->
    208         <javac srcdir="src" excludes="com/**,oauth/**,org/apache/commons/codec/**,org/glassfish/**,org/openstreetmap/gui/jmapviewer/Demo.java"
     220        <javac srcdir="${src.dir}" excludes="com/**,oauth/**,org/apache/commons/codec/**,org/glassfish/**,org/openstreetmap/gui/jmapviewer/Demo.java"
    209221            destdir="build" target="1.7" source="1.7" debug="on" includeantruntime="false" createMissingPackageInfoClass="false" encoding="UTF-8">
    210222            <compilerarg value="-Xlint:cast"/>
     
    233245    <target name="javadoc">
    234246        <javadoc destdir="javadoc"
    235                 sourcepath="src"
     247                sourcepath="${src.dir}"
    236248                encoding="UTF-8"   
    237249                packagenames="org.openstreetmap.josm.*,org.openstreetmap.gui.jmapviewer.*"
     
    250262        <delete dir="dist"/>
    251263        <delete dir="${mapcss.dir}/parsergen"/>
     264        <delete dir="${imagerytypes.dir}"/>
    252265    </target>
    253266    <path id="test.classpath">
     
    351364    </macrodef>
    352365    <target name="test" depends="test-compile"
    353         description="Run unit, functional and performance tests. OSM API (TEST) account shall be set with -Dosm.username and -Dosm.password">
     366        description="Run unit, functional and performance tests. OSM API (TEST) account shall be set with -Dosm.username and -Dosm.password">
    354367        <taskdef uri="antlib:org.jacoco.ant" resource="org/jacoco/ant/antlib.xml" classpath="tools/jacocoant.jar" />
    355368        <call-junit testfamily="unit"/>
     
    431444        <mkdir dir="${dir}"/>
    432445        <!-- List of deprecated plugins -->
    433         <loadfile property="deprecated-plugins" srcFile="src/org/openstreetmap/josm/plugins/PluginHandler.java">
     446        <loadfile property="deprecated-plugins" srcFile="${src.dir}/org/openstreetmap/josm/plugins/PluginHandler.java">
    434447            <filterchain>
    435448                <linecontains>
Note: See TracChangeset for help on using the changeset viewer.