source: josm/trunk/build.xml@ 16169

Last change on this file since 16169 was 16169, checked in by simon04, 4 years ago

see #16860 - Resolve ProGuard using Apache Ivy

  • Property svn:eol-style set to native
File size: 64.9 KB
RevLine 
[4166]1<?xml version="1.0" encoding="utf-8"?>
2<!-- ** build.xml - main ant file for JOSM
3**
4** To build run
5** ant clean
6** ant dist
[7133]7** This will create 'josm-custom.jar' in directory 'dist'. See also
[7183]8** https://josm.openstreetmap.de/wiki/DevelopersGuide/CreateBuild
[4166]9**
10-->
[15977]11<project name="josm" default="dist"
12 xmlns:as="antlib:org.codehaus.mojo.animal_sniffer"
13 xmlns:if="ant:if"
14 xmlns:ivy="antlib:org.apache.ivy.ant"
15 xmlns:jacoco="antlib:org.jacoco.ant"
16 xmlns:unless="ant:unless"
17>
18 <target name="init-ivy">
19 <dirname property="base.dir" file="${ant.file.josm}"/>
20 <property name="lib.dir" location="${base.dir}/lib"/>
21 <property name="tools.dir" location="${base.dir}/tools"/>
[16168]22 <property name="tools.ivy" location="${tools.dir}/ivy.xml"/>
[15977]23 <taskdef resource="org/apache/ivy/ant/antlib.xml" uri="antlib:org.apache.ivy.ant" classpath="${tools.dir}/ivy/ivy.jar"/>
24 </target>
25 <target name="init-properties" depends="resolve">
[13641]26 <property environment="env"/>
[9765]27 <!-- Load properties in a target and not at top level, so this build file can be
28 imported from an IDE ant file (Netbeans) without messing up IDE properties.
29 When imported from another file, ${basedir} will point to the parent directory
30 of the importing ant file. Use ${base.dir} instead, which is always the parent
31 directory of this file. -->
32 <property name="test.dir" location="${base.dir}/test"/>
33 <property name="src.dir" location="${base.dir}/src"/>
[13819]34 <condition property="noJavaFX">
35 <or>
[13642]36 <isset property="env.JOSM_NOJAVAFX"/>
[13819]37 <not>
38 <available classname="javafx.scene.media.Media"/>
39 </not>
40 </or>
[13641]41 </condition>
[9765]42 <property name="build.dir" location="${base.dir}/build"/>
43 <property name="dist.dir" location="${base.dir}/dist"/>
[16140]44 <property name="resources.dir" location="${base.dir}/resources"/>
[14136]45 <property name="modules.dir" location="${dist.dir}/modules"/>
[13209]46 <property name="tools.dir" location="${base.dir}/tools"/>
47 <property name="pmd.dir" location="${tools.dir}/pmd"/>
48 <property name="checkstyle.dir" location="${tools.dir}/checkstyle"/>
49 <property name="spotbugs.dir" location="${tools.dir}/spotbugs"/>
50 <property name="javacc.home" location="${tools.dir}"/>
[9765]51 <property name="mapcss.dir" location="${src.dir}/org/openstreetmap/josm/gui/mappaint/mapcss"/>
52 <property name="proj-build.dir" location="${base.dir}/build2"/>
[15033]53 <property name="script-build.dir" location="${base.dir}/build2"/>
[12582]54 <property name="checkstyle-build.dir" location="${base.dir}/build2"/>
[16140]55 <property name="epsg.output" location="${resources.dir}/data/projection/custom-epsg"/>
[14222]56 <property name="error_prone_core.jar" location="${tools.dir}/error_prone_core.jar"/>
57 <property name="error_prone_javac.jar" location="${tools.dir}/error_prone_javac.jar"/>
[15963]58 <property name="auto-value-annotations.jar" location="${tools.dir}/auto-value-annotations.jar"/>
[15974]59 <property name="dataflow.jar" location="${tools.dir}/dataflow-shaded.jar"/>
[14785]60 <property name="javacutil.jar" location="${tools.dir}/javacutil.jar"/>
[14782]61 <property name="failureaccess.jar" location="${tools.dir}/failureaccess.jar"/>
[16165]62 <property name="commons-lang3.jar" location="${tools.dir}/commons-lang3-3.8.1.jar"/>
[14222]63 <property name="jformatstring.jar" location="${spotbugs.dir}/jFormatString-3.0.0.jar"/>
[12628]64 <property name="dist.jar" location="${dist.dir}/josm-custom.jar"/>
65 <property name="dist-optimized.jar" location="${dist.dir}/josm-custom-optimized.jar"/>
[16141]66 <property name="dist-sources.jar" location="${dist.dir}/josm-custom-sources.jar"/>
[12628]67 <property name="java.lang.version" value="1.8" />
[14052]68 <property name="test.headless" value="true" />
[13103]69 <property name="jacoco.includes" value="org.openstreetmap.josm.*" />
[13097]70 <property name="jacoco.inclbootstrapclasses" value="false" />
71 <property name="jacoco.inclnolocationclasses" value="false" />
[14309]72 <property name="junit.printsummary" value="on" />
[15032]73 <property name="default-junit-includes" value="**/*Test.class"/>
74 <property name="default-junitIT-includes" value="**/*TestIT.class"/>
[9765]75 <!-- build parameter: compression level (ant -Dclevel=N)
76 N ranges from 0 (no compression) to 9 (maximum compression)
77 default: 9 -->
78 <condition property="clevel" value="${clevel}" else="9">
79 <isset property="clevel"/>
80 </condition>
[14172]81 <!-- For Java specific stuff by version -->
82 <condition property="isJava9"><matches string="${ant.java.version}" pattern="(1.)?(9|1[0-9])" /></condition>
83 <condition property="isJava10"><matches string="${ant.java.version}" pattern="1[0-9]" /></condition>
84 <condition property="isJava11"><matches string="${ant.java.version}" pattern="1[1-9]" /></condition>
85 <condition property="isJava12"><matches string="${ant.java.version}" pattern="1[2-9]" /></condition>
86 <condition property="isJava13"><matches string="${ant.java.version}" pattern="1[3-9]" /></condition>
[16156]87 <condition property="isJava16"><matches string="${ant.java.version}" pattern="1[6-9]" /></condition>
88 <!-- Disable jacoco on Java 16+, see https://github.com/jacoco/jacoco/pull/992 -->
[13523]89 <condition property="coverageByDefault">
90 <not>
[16156]91 <isset property="isJava16"/>
[13523]92 </not>
93 </condition>
[14244]94 <condition property="java.library.dir" value="jmods" else="lib">
95 <isset property="isJava9"/>
96 </condition>
[9766]97 <path id="test.classpath">
98 <fileset dir="${test.dir}/lib">
99 <include name="**/*.jar"/>
100 </fileset>
[16001]101 <pathelement path="${build.dir}"/>
[16140]102 <pathelement path="${resources.dir}"/>
[14783]103 <pathelement path="${failureaccess.jar}"/>
[15033]104 <pathelement path="${commons-lang3.jar}"/>
[13209]105 <pathelement path="${spotbugs.dir}/spotbugs-annotations.jar"/>
[9766]106 </path>
[14222]107 <path id="processor.path">
108 <pathelement location="${error_prone_core.jar}"/>
[14785]109 <pathelement location="${dataflow.jar}"/>
110 <pathelement location="${javacutil.jar}"/>
[14782]111 <pathelement location="${failureaccess.jar}"/>
[14222]112 <pathelement location="${jformatstring.jar}"/>
[15963]113 <pathelement location="${auto-value-annotations.jar}"/>
[14222]114 </path>
[9765]115 </target>
[4252]116
[4166]117 <!--
[6133]118 ** Used by Eclipse ant builder for updating
119 ** the REVISION file used by JOSM
120 -->
[4166]121 <target name="create-revision-eclipse">
122 <property name="revision.dir" value="bin"/>
123 <antcall target="create-revision"/>
[12931]124 <mkdir dir="bin/META-INF/services"/>
125 <echo encoding="UTF-8" file="bin/META-INF/services/java.text.spi.DecimalFormatSymbolsProvider">org.openstreetmap.josm.tools.JosmDecimalFormatSymbolsProvider</echo>
[4166]126 </target>
127 <!--
[6540]128 ** Initializes the REVISION.XML file from SVN information
[6133]129 -->
[9765]130 <target name="init-svn-revision-xml" depends="init-properties">
131 <exec append="false" output="${base.dir}/REVISION.XML" executable="svn" dir="${base.dir}" failifexecutionfails="false" resultproperty="svn.info.result">
[4166]132 <env key="LANG" value="C"/>
133 <arg value="info"/>
134 <arg value="--xml"/>
135 <arg value="."/>
136 </exec>
[6585]137 <condition property="svn.info.success">
138 <equals arg1="${svn.info.result}" arg2="0" />
139 </condition>
[6540]140 </target>
141 <!--
142 ** Initializes the REVISION.XML file from git information
143 -->
[9765]144 <target name="init-git-revision-xml" unless="svn.info.success" depends="init-properties">
145 <exec append="false" output="${base.dir}/REVISION.XML" executable="git" dir="${base.dir}" failifexecutionfails="false">
[6540]146 <arg value="log"/>
147 <arg value="-1"/>
148 <arg value="--grep=git-svn-id"/>
[6545]149 <!--
150 %B: raw body (unwrapped subject and body)
151 %n: new line
152 %ai: author date, ISO 8601 format
153 -->
154 <arg value="--pretty=format:%B%n%ai"/>
[6540]155 <arg value="HEAD"/>
156 </exec>
[9765]157 <replaceregexp file="${base.dir}/REVISION.XML" flags="s"
[6545]158 match=".*git-svn-id: [^@]*@([0-9]+).*(\d{4}-\d{2}-\d{2}.\d{2}\:\d{2}\:\d{2}\s*[+-]\d{2}:?\d{2})\s*$"
159 replace="&lt;info&gt;&lt;entry&gt;&lt;commit revision=&quot;\1&quot;&gt;&lt;date&gt;\2&lt;/date&gt;&lt;/commit&gt;&lt;/entry&gt;&lt;/info&gt;"/>
[6540]160 </target>
161 <!--
162 ** Creates the REVISION file to be included in the distribution
163 -->
[9765]164 <target name="create-revision" depends="init-properties,init-svn-revision-xml,init-git-revision-xml">
[6540]165 <property name="revision.dir" value="${build.dir}"/>
[9765]166 <xmlproperty file="${base.dir}/REVISION.XML" prefix="version" keepRoot="false" collapseAttributes="true"/>
167 <delete file="${base.dir}/REVISION.XML"/>
[4166]168 <tstamp>
169 <format property="build.tstamp" pattern="yyyy-MM-dd HH:mm:ss"/>
170 </tstamp>
171 <property name="version.entry.commit.revision" value="UNKNOWN"/>
[6540]172 <property name="version.entry.commit.date" value="UNKNOWN"/>
[4166]173 <mkdir dir="${revision.dir}"/>
[5362]174 <!-- add Build-Name: ... when making special builds, e.g. DEBIAN -->
[4166]175 <echo file="${revision.dir}/REVISION">
176# automatically generated by JOSM build.xml - do not edit
177Revision: ${version.entry.commit.revision}
178Is-Local-Build: true
179Build-Date: ${build.tstamp}
180</echo>
181 </target>
[6540]182 <!--
183 ** Check internal XML files against their XSD
184 -->
[9765]185 <target name="check-schemas" unless="check-schemas.notRequired" depends="init-properties">
[16140]186 <schemavalidate file="${resources.dir}/data/defaultpresets.xml" >
187 <schema namespace="http://josm.openstreetmap.de/tagging-preset-1.0" file="${resources.dir}/data/tagging-preset.xsd" />
[6208]188 </schemavalidate>
189 </target>
[6540]190 <!--
191 ** Main target that builds JOSM and checks XML against schemas
192 -->
[16036]193 <target name="dist" depends="compile,extract-libraries,epsg,copy-resources,create-revision,check-schemas">
[4166]194 <echo>Revision ${version.entry.commit.revision}</echo>
[12648]195 <copy file="CONTRIBUTION" todir="${build.dir}"/>
196 <copy file="README" todir="${build.dir}"/>
197 <copy file="LICENSE" todir="${build.dir}"/>
[4166]198 <!-- create josm-custom.jar -->
[12628]199 <delete file="${dist.jar}"/>
200 <jar destfile="${dist.jar}" basedir="${build.dir}" level="${clevel}">
[4166]201 <!-- add attribute excludes="**/*BZip2*,**/*Bzip2*" to create a non-bzip2 supporting jar -->
202 <manifest>
[11926]203 <attribute name="Main-class" value="org.openstreetmap.josm.gui.MainApplication"/>
[4166]204 <attribute name="Main-Version" value="${version.entry.commit.revision} SVN"/>
205 <attribute name="Main-Date" value="${version.entry.commit.date}"/>
[6341]206 <attribute name="Permissions" value="all-permissions"/>
207 <attribute name="Codebase" value="josm.openstreetmap.de"/>
208 <attribute name="Application-Name" value="JOSM - Java OpenStreetMap Editor"/>
[12205]209 <!-- Java 9 stuff. Entries are safely ignored by Java 8 -->
[15469]210 <attribute name="Add-Exports" value="java.desktop/com.apple.eawt java.desktop/com.sun.imageio.spi java.desktop/com.sun.imageio.plugins.jpeg javafx.graphics/com.sun.javafx.application jdk.deploy/com.sun.deploy.config" />
[12932]211 <attribute name="Add-Opens" value="java.base/java.lang java.base/java.nio java.base/jdk.internal.loader java.base/jdk.internal.ref java.desktop/javax.imageio.spi java.desktop/javax.swing.text.html java.prefs/java.util.prefs" />
[4166]212 </manifest>
[12931]213 <service type="java.text.spi.DecimalFormatSymbolsProvider" provider="org.openstreetmap.josm.tools.JosmDecimalFormatSymbolsProvider" />
[7133]214 <zipfileset dir="${src.dir}/org/openstreetmap/gui/jmapviewer/images" prefix="org/openstreetmap/gui/jmapviewer/images"/>
[4166]215 </jar>
216 </target>
[7001]217 <!-- Mac OS X target -->
[9765]218 <target name="mac" depends="init-properties">
[6217]219 <!-- Using https://bitbucket.org/infinitekind/appbundler to create mac application bundle -->
[14793]220 <taskdef name="bundleapp" classname="com.oracle.appbundler.AppBundlerTask" classpath="${tools.dir}/appbundler.jar"/>
[6217]221 <!-- create MacOS X application bundle -->
[6945]222 <bundleapp outputdirectory="${bundle.outdir}" name="JOSM" displayname="JOSM" executablename="JOSM" identifier="org.openstreetmap.josm"
[6216]223 mainclassname="org.openstreetmap.josm.gui.MainApplication"
[6217]224 copyright="JOSM, and all its integral parts, are released under the GNU General Public License v2 or later"
[6216]225 applicationCategory="public.app-category.utilities"
226 shortversion="${version.entry.commit.revision} SVN"
227 version="${version.entry.commit.revision} SVN"
[16007]228 icon="native/macosx/JOSM.app/Contents/Resources/JOSM.icns"
[6217]229 highResolutionCapable="true">
[6216]230
231 <arch name="x86_64"/>
232 <arch name="i386"/>
233
[6945]234 <classpath file="${bundle.jar}"/>
[6216]235
[13722]236 <option value="-Xmx2048m"/>
[6216]237
238 <option value="-Xdock:icon=Contents/Resources/JOSM.icns"/>
239 <option value="-Xdock:name=JOSM"/>
240
241 <!-- OSX specific options, optional -->
242 <option value="-Dapple.laf.useScreenMenuBar=true"/>
243 <option value="-Dcom.apple.macos.use-file-dialog-packages=true"/>
244 <option value="-Dcom.apple.macos.useScreenMenuBar=true"/>
245 <option value="-Dcom.apple.mrj.application.apple.menu.about.name=JOSM"/>
246 <option value="-Dcom.apple.smallTabs=true"/>
247 </bundleapp>
[9765]248
[6217]249 <!-- appbundler lacks the possibility of defining our own keys or using a template, so update the .plist manually -->
[13209]250 <taskdef name="xmltask" classname="com.oopsconsultancy.xmltask.ant.XmlTask" classpath="${tools.dir}/xmltask.jar"/>
[9765]251
[6945]252 <xmltask source="${bundle.outdir}/JOSM.app/Contents/Info.plist" dest="${bundle.outdir}/JOSM.app/Contents/Info.plist" indent="false">
[7367]253 <!-- remove empty CFBundleDocumentTypes definition -->
254 <remove path="/plist/dict/key[text()='CFBundleDocumentTypes']|/plist/dict/key[text()='CFBundleDocumentTypes']/following-sibling::array[1]"/>
[7287]255 <!-- insert our own keys -->
[16007]256 <insert position="before" path="/plist/dict/key[1]" file="native/macosx/JOSM.app/Contents/Info.plist_template.xml" />
[6217]257 </xmltask>
[9765]258
[6216]259 <!-- create ZIP file with MacOS X application bundle -->
[7001]260 <zip destfile="${bundle.outdir}/josm-custom-macosx.zip" update="true">
[6945]261 <zipfileset dir="." includes="CONTRIBUTION README LICENSE"/>
262 <zipfileset dir="${bundle.outdir}" includes="JOSM.app/**/*" filemode="755" />
[6216]263 </zip>
[6217]264 </target>
[7001]265 <target name="distmac" depends="dist">
266 <antcall target="mac">
[9765]267 <param name="bundle.outdir" value="${dist.dir}"/>
[12628]268 <param name="bundle.jar" value="${dist.jar}"/>
[6945]269 </antcall>
270 </target>
[7839]271 <!-- Windows target -->
272 <target name="distwin" depends="dist">
[16007]273 <exec dir="native/windows" executable="./josm-setup-unix.sh">
[7839]274 <arg value="${version.entry.commit.revision}"/>
[12628]275 <arg value="${dist.jar}"/>
[7839]276 </exec>
277 </target>
[5392]278 <target name="javacc" depends="init" unless="javacc.notRequired">
[16168]279 <ivy:cachepath file="${tools.ivy}" pathid="javacc.classpath" conf="javacc"/>
[4252]280 <mkdir dir="${mapcss.dir}/parsergen"/>
[11676]281 <java classname="javacc" fork="true" failonerror="true">
[16168]282 <classpath refid="javacc.classpath"/>
[7043]283 <arg value="-DEBUG_PARSER=false"/>
284 <arg value="-DEBUG_TOKEN_MANAGER=false"/>
[12628]285 <arg value="-JDK_VERSION=${java.lang.version}"/>
[6446]286 <arg value="-GRAMMAR_ENCODING=UTF-8"/>
[4257]287 <arg value="-OUTPUT_DIRECTORY=${mapcss.dir}/parsergen"/>
288 <arg value="${mapcss.dir}/MapCSSParser.jj"/>
[11676]289 </java>
[4252]290 </target>
[16036]291 <target name="compile-cots" depends="init" description="Compiles third-party dependencies not retrieved with Ivy">
[7068]292 <!-- COTS -->
[16025]293 <javac srcdir="${src.dir}" includes="com/google/**,com/kitfox/**,oauth/**,org/apache/commons/**" nowarn="on" encoding="iso-8859-1"
[12648]294 destdir="${build.dir}" target="${java.lang.version}" source="${java.lang.version}" debug="on" includeAntRuntime="false" createMissingPackageInfoClass="false">
[7019]295 <!-- get rid of "internal proprietary API" warning -->
[7068]296 <compilerarg value="-XDignore.symbol.file"/>
[10833]297 <exclude name="org/apache/commons/jcs/JCS.java"/>
[10866]298 <exclude name="org/apache/commons/jcs/access/GroupCacheAccess.java"/>
[10833]299 <exclude name="org/apache/commons/jcs/access/PartitionedCacheAccess.java"/>
[10866]300 <exclude name="org/apache/commons/jcs/access/behavior/IGroupCacheAccess.java"/>
301 <exclude name="org/apache/commons/jcs/access/exception/InvalidGroupException.java"/>
[10833]302 <exclude name="org/apache/commons/jcs/admin/servlet/**"/>
[10866]303 <exclude name="org/apache/commons/jcs/auxiliary/AbstractAuxiliaryCacheMonitor.java"/>
[8173]304 <exclude name="org/apache/commons/jcs/auxiliary/disk/jdbc/**"/>
[10866]305 <exclude name="org/apache/commons/jcs/auxiliary/lateral/**"/>
[8173]306 <exclude name="org/apache/commons/jcs/auxiliary/remote/**"/>
[10866]307 <exclude name="org/apache/commons/jcs/engine/CacheAdaptor.java"/>
308 <exclude name="org/apache/commons/jcs/engine/CacheGroup.java"/>
309 <exclude name="org/apache/commons/jcs/engine/CacheWatchRepairable.java"/>
[10833]310 <exclude name="org/apache/commons/jcs/engine/Zombie*.java"/>
[10866]311 <exclude name="org/apache/commons/jcs/engine/logging/CacheEventLoggerDebugLogger.java"/>
[10833]312 <exclude name="org/apache/commons/jcs/utils/access/**"/>
313 <exclude name="org/apache/commons/jcs/utils/discovery/**"/>
314 <exclude name="org/apache/commons/jcs/utils/net/**"/>
315 <exclude name="org/apache/commons/jcs/utils/props/**"/>
[8173]316 <exclude name="org/apache/commons/jcs/utils/servlet/**"/>
[16050]317 <classpath>
318 <path refid="runtime.path"/>
319 </classpath>
[7019]320 </javac>
[12648]321 </target>
[16036]322 <target name="compile-jmapviewer" depends="init" description="Compiles JMapViewer">
[8526]323 <!-- JMapViewer -->
[14222]324 <javac sourcepath="" srcdir="${src.dir}" fork="yes"
[16022]325 excludes="com/**,oauth/**,org/apache/commons/**,org/openstreetmap/gui/jmapviewer/Demo.java,org/openstreetmap/gui/jmapviewer/JMapViewerTree.java,org/openstreetmap/gui/jmapviewer/checkBoxTree/**,org/openstreetmap/josm/**"
[12648]326 destdir="${build.dir}" target="${java.lang.version}" source="${java.lang.version}" debug="on" includeantruntime="false" createMissingPackageInfoClass="false" encoding="UTF-8">
[14222]327 <compilerarg value="-J-Xbootclasspath/p:${error_prone_javac.jar}" unless:set="isJava9"/>
328 <compilerarg line="-XDcompilePolicy=simple"/>
329 <compilerarg value="-processorpath"/>
330 <compilerarg pathref="processor.path"/>
[7021]331 <compilerarg value="-Xlint:cast"/>
[4166]332 <compilerarg value="-Xlint:deprecation"/>
[7022]333 <compilerarg value="-Xlint:dep-ann"/>
334 <compilerarg value="-Xlint:divzero"/>
335 <compilerarg value="-Xlint:empty"/>
336 <compilerarg value="-Xlint:finally"/>
337 <compilerarg value="-Xlint:overrides"/>
338 <!--<compilerarg value="-Xlint:rawtypes"/>-->
339 <compilerarg value="-Xlint:static"/>
340 <compilerarg value="-Xlint:try"/>
[4166]341 <compilerarg value="-Xlint:unchecked"/>
[7367]342 <!-- Undocumented argument to ignore "Sun internal proprietary API" warning, see http://stackoverflow.com/a/13862308/2257172 -->
[7351]343 <compilerarg value="-XDignore.symbol.file"/>
[15963]344 <compilerarg value="-Xplugin:ErrorProne -Xep:CatchAndPrintStackTrace:OFF -Xep:ReferenceEquality:OFF -Xep:StringSplitter:OFF -Xep:BadImport:OFF"/>
[10659]345 <compilerarg line="-Xmaxwarns 1000"/>
[4166]346 </javac>
[12648]347 </target>
[16036]348 <target name="compile" depends="init,javacc,compile-cots,compile-jmapviewer" unless="compile.notRequired" description="Compiles JOSM">
[8526]349 <!-- JOSM -->
[14222]350 <javac sourcepath="" srcdir="${src.dir}" fork="yes"
[16022]351 excludes="com/**,oauth/**,org/apache/commons/**,org/openstreetmap/gui/jmapviewer/**"
[12648]352 destdir="${build.dir}" target="${java.lang.version}" source="${java.lang.version}" debug="on" includeantruntime="false" createMissingPackageInfoClass="false" encoding="UTF-8">
[14222]353 <compilerarg value="-J-Xbootclasspath/p:${error_prone_javac.jar}" unless:set="isJava9"/>
354 <compilerarg line="-XDcompilePolicy=simple"/>
355 <compilerarg value="-processorpath"/>
356 <compilerarg pathref="processor.path"/>
[8526]357 <compilerarg value="-Xlint:cast"/>
358 <compilerarg value="-Xlint:deprecation"/>
359 <compilerarg value="-Xlint:dep-ann"/>
360 <compilerarg value="-Xlint:divzero"/>
361 <compilerarg value="-Xlint:empty"/>
362 <compilerarg value="-Xlint:finally"/>
363 <compilerarg value="-Xlint:overrides"/>
364 <!--<compilerarg value="-Xlint:rawtypes"/>-->
365 <compilerarg value="-Xlint:static"/>
366 <compilerarg value="-Xlint:try"/>
367 <compilerarg value="-Xlint:unchecked"/>
368 <!-- Undocumented argument to ignore "Sun internal proprietary API" warning, see http://stackoverflow.com/a/13862308/2257172 -->
369 <compilerarg value="-XDignore.symbol.file"/>
[16168]370 <compilerarg value="-Xplugin:ErrorProne -XepExcludedPaths:.*/parsergen/.* -Xep:ReferenceEquality:OFF -Xep:ImmutableEnumChecker:OFF -Xep:FutureReturnValueIgnored:OFF -Xep:FloatingPointLiteralPrecision:OFF -Xep:ShortCircuitBoolean:OFF -Xep:StringSplitter:OFF -Xep:JdkObsolete:OFF -Xep:UnnecessaryParentheses:OFF -Xep:EqualsGetClass:OFF -Xep:ThreadPriorityCheck:OFF -Xep:UndefinedEquals:OFF -Xep:MixedMutabilityReturnType:OFF -Xep:OverrideThrowableToString:OFF -Xep:JavaTimeDefaultTimeZone:OFF -Xep:UnusedVariable:OFF -Xep:EqualsUsingHashCode:OFF -Xep:BadImport:OFF -Xep:UnnecessaryLambda:OFF -Xep:AnnotateFormatMethod:OFF -Xep:MutablePublicArray:OFF"/>
[10659]371 <compilerarg line="-Xmaxwarns 1000"/>
[15977]372 <classpath>
373 <path refid="runtime.path"/>
374 </classpath>
[8526]375 </javac>
[16036]376 </target>
377 <target name="copy-resources" description="Copy resource files to build directory">
[6756]378 <copy todir="build" failonerror="no" includeemptydirs="no">
[16140]379 <fileset dir="${resources.dir}"/>
[6756]380 </copy>
[4166]381 </target>
[9765]382 <target name="init" depends="init-properties">
[5392]383 <uptodate property="javacc.notRequired" targetfile="${mapcss.dir}/parsergen/MapCSSParser.java" >
384 <srcfiles dir="${mapcss.dir}" includes="MapCSSParser.jj"/>
385 </uptodate>
[9765]386 <mkdir dir="${build.dir}"/>
387 <mkdir dir="${dist.dir}"/>
[4166]388 </target>
[9765]389 <target name="javadoc" depends="init-properties">
390 <javadoc destdir="javadoc"
[7133]391 sourcepath="${src.dir}"
[15992]392 classpathref="compile.path"
[9765]393 encoding="UTF-8"
[5263]394 packagenames="org.openstreetmap.josm.*,org.openstreetmap.gui.jmapviewer.*"
[9250]395 excludepackagenames="org.openstreetmap.josm.gui.mappaint.mapcss.parsergen.*"
[5263]396 windowtitle="JOSM"
397 use="true"
[5481]398 private="true"
[5263]399 linksource="true"
400 author="false">
[15106]401 <link href="https://docs.oracle.com/javase/8/docs/api" unless:set="isJava11" />
402 <link href="https://docs.oracle.com/en/java/javase/11/docs/api" if:set="isJava11" />
[5263]403 <doctitle><![CDATA[<h2>JOSM - Javadoc</h2>]]></doctitle>
[6955]404 <bottom><![CDATA[<a href="https://josm.openstreetmap.de/">JOSM</a>]]></bottom>
[15243]405 <!-- Disable HTML checking until we switch to Java13+, see https://bugs.openjdk.java.net/browse/JDK-8223552 -->
406 <arg value="-Xdoclint:-html" if:set="isJava13" />
[13494]407 <arg value="-html5" if:set="isJava9" />
[13820]408 <arg value="--add-exports" if:set="isJava9" unless:set="noJavaFX" />
409 <arg value="javafx.graphics/com.sun.javafx.application=ALL-UNNAMED" if:set="isJava9" unless:set="noJavaFX" />
[5263]410 </javadoc>
411 </target>
[9765]412 <target name="clean" depends="init-properties">
413 <delete dir="${build.dir}"/>
414 <delete dir="${proj-build.dir}"/>
[15033]415 <delete dir="${script-build.dir}"/>
[12582]416 <delete dir="${checkstyle-build.dir}"/>
[9765]417 <delete dir="${dist.dir}"/>
[4252]418 <delete dir="${mapcss.dir}/parsergen"/>
[8535]419 <delete file="${src.dir}/org/w3/_2001/xmlschema/Adapter1.java"/>
420 <delete dir="${src.dir}/org/openstreetmap/josm/data/imagery/types"/>
[9133]421 <delete file="${epsg.output}"/>
[13209]422 <delete file="${pmd.dir}/cache"/>
[4166]423 </target>
[7068]424 <macrodef name="init-test-preferences">
425 <attribute name="testfamily"/>
426 <sequential>
427 <copy file="${test.dir}/config/preferences.template.xml" tofile="${test.dir}/config/@{testfamily}-josm.home/preferences.xml"/>
428 <replace file="${test.dir}/config/@{testfamily}-josm.home/preferences.xml" encoding="UTF-8" token="@OSM_USERNAME@" value="${osm.username}"/>
429 <replace file="${test.dir}/config/@{testfamily}-josm.home/preferences.xml" encoding="UTF-8" token="@OSM_PASSWORD@" value="${osm.password}"/>
430 </sequential>
431 </macrodef>
[9765]432 <target name="test-init" depends="init-properties">
[6121]433 <mkdir dir="${test.dir}/build"/>
[7068]434 <mkdir dir="${test.dir}/build/unit"/>
435 <mkdir dir="${test.dir}/build/functional"/>
436 <mkdir dir="${test.dir}/build/performance"/>
[4166]437 <mkdir dir="${test.dir}/report"/>
[7068]438 <init-test-preferences testfamily="unit"/>
439 <init-test-preferences testfamily="functional"/>
440 <init-test-preferences testfamily="performance"/>
[13209]441 <taskdef uri="antlib:org.jacoco.ant" resource="org/jacoco/ant/antlib.xml" classpath="${tools.dir}/jacocoant.jar" />
[4166]442 </target>
[9765]443 <target name="test-clean" depends="init-properties">
[6121]444 <delete dir="${test.dir}/build"/>
[4166]445 <delete dir="${test.dir}/report"/>
[6133]446 <delete file="${test.dir}/jacoco.exec" />
[9501]447 <delete file="${test.dir}/jacocoIT.exec" />
[10850]448 <delete file="${test.dir}/config/unit-josm.home" failonerror="false"/>
449 <delete file="${test.dir}/config/functional-josm.home" failonerror="false"/>
450 <delete file="${test.dir}/config/performance-josm.home" failonerror="false"/>
[4166]451 </target>
[14065]452 <macrodef name="call-javac">
[7068]453 <attribute name="testfamily"/>
454 <element name="cp-elements"/>
455 <sequential>
[14065]456 <javac srcdir="${test.dir}/@{testfamily}" destdir="${test.dir}/build/@{testfamily}"
457 target="${java.lang.version}" source="${java.lang.version}" debug="on"
458 includeantruntime="false" createMissingPackageInfoClass="false" encoding="UTF-8">
459 <compilerarg value="-Xlint:all"/>
460 <compilerarg value="-Xlint:-serial"/>
[7068]461 <classpath>
462 <cp-elements/>
463 </classpath>
[14065]464 </javac>
[7068]465 </sequential>
466 </macrodef>
[16036]467 <target name="test-compile" depends="test-init,compile,extract-libraries,epsg,copy-resources" description="Compiles all tests">
[14065]468 <call-javac testfamily="unit">
[7068]469 <cp-elements>
470 <path refid="test.classpath"/>
471 </cp-elements>
[14065]472 </call-javac>
473 <call-javac testfamily="functional">
[7068]474 <cp-elements>
475 <path refid="test.classpath"/>
476 <pathelement path="${test.dir}/build/unit"/>
477 </cp-elements>
[14065]478 </call-javac>
479 <call-javac testfamily="performance">
[7068]480 <cp-elements>
481 <path refid="test.classpath"/>
482 <pathelement path="${test.dir}/build/unit"/>
483 </cp-elements>
[14065]484 </call-javac>
[4166]485 </target>
[7068]486 <macrodef name="call-junit">
487 <attribute name="testfamily"/>
[9501]488 <attribute name="testITsuffix" default=""/>
[13523]489 <attribute name="coverage" default="${coverageByDefault}"/>
[15032]490 <attribute name="includes" default="${default-junit@{testITsuffix}-includes}"/>
491 <attribute name="excludes" default="${default-junit@{testITsuffix}-excludes}"/>
[7068]492 <sequential>
[9501]493 <echo message="Running @{testfamily}@{testITsuffix} tests with JUnit"/>
[13103]494 <jacoco:coverage destfile="${test.dir}/jacoco@{testITsuffix}.exec" enabled="@{coverage}" includes="${jacoco.includes}"
495 inclbootstrapclasses="${jacoco.inclbootstrapclasses}" inclnolocationclasses="${jacoco.inclnolocationclasses}">
[14309]496 <junit printsummary="${junit.printsummary}" fork="true" forkmode="once" failureproperty="test.@{testfamily}@{testITsuffix}.failed">
[7367]497 <jvmarg value="-Dfile.encoding=UTF-8"/>
[14604]498 <jvmarg value="-javaagent:${test.dir}/lib/jmockit.jar"/>
[13505]499 <jvmarg value="--add-modules" if:set="isJava9" unless:set="isJava11" />
500 <jvmarg value="java.activation,java.se.ee" if:set="isJava9" unless:set="isJava11" />
[13820]501 <jvmarg value="--add-exports" if:set="isJava9" unless:set="noJavaFX" />
502 <jvmarg value="javafx.graphics/com.sun.javafx.application=ALL-UNNAMED" if:set="isJava9" unless:set="noJavaFX" />
503 <jvmarg value="--add-exports" if:set="isJava9" unless:set="isJava11" />
504 <jvmarg value="jdk.deploy/com.sun.deploy.config=ALL-UNNAMED" if:set="isJava9" unless:set="isJava11" />
[12228]505 <jvmarg value="--add-opens" if:set="isJava9" />
[12230]506 <jvmarg value="java.base/java.io=ALL-UNNAMED" if:set="isJava9" />
507 <jvmarg value="--add-opens" if:set="isJava9" />
[12228]508 <jvmarg value="java.base/java.lang=ALL-UNNAMED" if:set="isJava9" />
[12230]509 <jvmarg value="--add-opens" if:set="isJava9" />
[12932]510 <jvmarg value="java.base/java.nio=ALL-UNNAMED" if:set="isJava9" />
511 <jvmarg value="--add-opens" if:set="isJava9" />
[12230]512 <jvmarg value="java.base/java.text=ALL-UNNAMED" if:set="isJava9" />
513 <jvmarg value="--add-opens" if:set="isJava9" />
514 <jvmarg value="java.base/java.util=ALL-UNNAMED" if:set="isJava9" />
515 <jvmarg value="--add-opens" if:set="isJava9" />
[14233]516 <jvmarg value="java.base/jdk.internal.loader=ALL-UNNAMED" if:set="isJava9" />
517 <jvmarg value="--add-opens" if:set="isJava9" />
[12230]518 <jvmarg value="java.desktop/java.awt=ALL-UNNAMED" if:set="isJava9" />
[7068]519 <sysproperty key="josm.home" value="${test.dir}/config/@{testfamily}-josm.home"/>
520 <sysproperty key="josm.test.data" value="${test.dir}/data"/>
[14052]521 <sysproperty key="java.awt.headless" value="${test.headless}"/>
[10529]522 <sysproperty key="glass.platform" value="Monocle"/>
523 <sysproperty key="monocle.platform" value="Headless"/>
524 <sysproperty key="prism.order" value="sw"/>
[7068]525 <sysproperty key="suppressPermanentFailure" value="${suppressPermanentFailure}"/>
526 <classpath>
527 <path refid="test.classpath"/>
528 <pathelement path="${test.dir}/build/unit"/>
529 <pathelement path="${test.dir}/build/@{testfamily}"/>
530 <pathelement path="${test.dir}/config"/>
531 </classpath>
532 <formatter type="plain"/>
533 <formatter type="xml"/>
534 <batchtest fork="yes" todir="${test.dir}/report">
[15032]535 <fileset dir="${test.dir}/build/@{testfamily}" includes="@{includes}" excludes="@{excludes}"/>
[7068]536 </batchtest>
537 </junit>
538 </jacoco:coverage>
539 </sequential>
540 </macrodef>
[9501]541 <target name="test" depends="test-compile" unless="test.notRequired"
[12534]542 description="Run unit and functional tests. OSM API (TEST) account shall be set with -Dosm.username and -Dosm.password">
[7068]543 <call-junit testfamily="unit"/>
544 <call-junit testfamily="functional"/>
[4166]545 </target>
[14141]546 <target name="test-hardfail" depends="test" description="Run 'test' target but abort if tests failed">
547 <fail message="'test' failed">
548 <condition>
549 <or>
550 <isset property="test.unit.failed"/>
551 <isset property="test.functional.failed"/>
552 </or>
553 </condition>
554 </fail>
555 </target>
556 <target name="test-unit" depends="test-compile" unless="test-unit.notRequired"
557 description="Run unit tests. OSM API (TEST) account shall be set with -Dosm.username and -Dosm.password">
558 <call-junit testfamily="unit"/>
559 </target>
560 <target name="test-unit-hardfail" depends="test-unit" description="Run 'test-unit' target but abort if tests failed">
561 <fail message="'test-unit' failed" if="test.unit.failed"/>
562 </target>
[16051]563 <target name="test-it" depends="test-compile,create-revision" unless="test-it.notRequired"
[9501]564 description="Run integration tests. OSM API (TEST) account shall be set with -Dosm.username and -Dosm.password">
565 <call-junit testfamily="unit" testITsuffix="IT"/>
566 <call-junit testfamily="functional" testITsuffix="IT"/>
567 </target>
[14141]568 <target name="test-it-hardfail" depends="test-it" description="Run 'test-it' target but abort if tests failed">
569 <fail message="'test-it' failed">
570 <condition>
571 <or>
572 <isset property="test.unitIT.failed"/>
573 <isset property="test.functionalIT.failed"/>
574 </or>
575 </condition>
576 </fail>
577 </target>
[12534]578 <target name="test-perf" depends="test-compile" unless="test-perf.notRequired"
579 description="Run performance tests. OSM API (TEST) account shall be set with -Dosm.username and -Dosm.password">
580 <call-junit testfamily="performance" coverage="false"/>
581 </target>
[14141]582 <target name="test-perf-hardfail" depends="test-perf" description="Run 'test-perf' target but abort if tests failed">
583 <fail message="'test-perf' failed" if="test.performance.failed"/>
584 </target>
[15703]585 <target name="test-html" depends="test, test-it, test-perf" description="Generate HTML, CSV and XML test reports">
[4166]586 <!-- May require additional ant dependencies like ant-trax package -->
587 <junitreport todir="${test.dir}/report">
588 <fileset dir="${test.dir}/report">
589 <include name="TEST-*.xml"/>
590 </fileset>
591 <report todir="${test.dir}/report/html"/>
592 </junitreport>
[6133]593 <jacoco:report>
594 <executiondata>
[11963]595 <fileset dir="${test.dir}" includes="*.exec"/>
[6133]596 </executiondata>
597 <structure name="JOSM Test Coverage">
598 <classfiles>
599 <fileset dir="${build.dir}" includes="org/openstreetmap/"/>
600 </classfiles>
601 <sourcefiles encoding="UTF-8">
602 <fileset dir="${src.dir}" includes="org/openstreetmap/"/>
603 </sourcefiles>
604 </structure>
[6134]605 <html destdir="${test.dir}/report/jacoco"/>
[15703]606 <xml destfile="${test.dir}/report/jacoco.xml"/>
607 <csv destfile="${test.dir}/report/jacoco.csv"/>
[6133]608 </jacoco:report>
[4166]609 </target>
[14258]610 <target name="dist-optimized" depends="dist" unless="isJava11">
[16169]611 <ivy:cachepath file="${tools.ivy}" pathid="proguard.classpath" conf="proguard"/>
612 <taskdef resource="proguard/ant/task.properties" classpathref="proguard.classpath"/>
[4166]613 <proguard>
[12628]614 -injars ${dist.jar}
615 -outjars ${dist-optimized.jar}
[4166]616
[14244]617 -libraryjars ${java.home}/${java.library.dir}
[4166]618
[7367]619 -dontoptimize
620 -dontobfuscate
[16116]621 -dontwarn org.jetbrains.annotations.**
[4166]622
[7367]623 # These options probably are not necessary (and make processing a bit slower)
624 -dontskipnonpubliclibraryclasses
625 -dontskipnonpubliclibraryclassmembers
[4166]626
[7367]627 -keepclasseswithmembers public class org.openstreetmap.josm.gui.MainApplication {
628 public static void main(java.lang.String[]);
629 }
[4166]630
[7367]631 -keep class * extends org.openstreetmap.josm.io.FileImporter
632 -keep class * extends org.openstreetmap.josm.io.FileExporter
633 -keep class org.openstreetmap.josm.actions.search.SearchCompiler$Never
[10949]634 -keep class org.openstreetmap.josm.gui.mappaint.mapcss.ConditionFactory$PseudoClasses {
[8532]635 static boolean *(org.openstreetmap.josm.gui.mappaint.Environment);
636 }
[8172]637 -keep class org.apache.commons.logging.impl.*
[4166]638
[7367]639 -keepclassmembers enum * {
640 public static **[] values();
641 public static ** valueOf(java.lang.String);
642 }
[4166]643
[12873]644 # Keep unused public classes and methods (needed for plugins)
645 -keep public class * {
[7367]646 public protected *;
647 }
[4838]648
[12873]649 # Keep serialization code
[10949]650 -keepclassmembers class * implements java.io.Serializable {
[12873]651 static final long serialVersionUID;
652 private static final java.io.ObjectStreamField[] serialPersistentFields;
[10949]653 private void writeObject(java.io.ObjectOutputStream);
654 private void readObject(java.io.ObjectInputStream);
[12873]655 java.lang.Object writeReplace();
656 java.lang.Object readResolve();
[10949]657 }
658
[7367]659 # Disable annoying [proguard] Note: the configuration keeps the entry point '...', but not the descriptor class '...'.
660 # This note should not be a problem as we don't use obfuscation
661 -dontnote
[6133]662 </proguard>
[4166]663 </target>
[14244]664 <target name="dist-optimized-report" depends="dist-optimized">
[10845]665 <!-- generate difference report between optimized jar and normal one -->
666 <exec executable="perl" dir="${basedir}">
[13209]667 <arg value="${tools.dir}/japicc/japi-compliance-checker.pl"/>
[10845]668 <arg value="--lib=JOSM"/>
669 <arg value="--keep-internal"/>
670 <arg value="--v1=${version.entry.commit.revision}"/>
671 <arg value="--v2=${version.entry.commit.revision}-optimized"/>
672 <arg value="--report-path=${dist.dir}/compat_report.html"/>
[12628]673 <arg value="${dist.jar}"/>
674 <arg value="${dist-optimized.jar}"/>
[10845]675 </exec>
676 </target>
[14258]677 <target name="check-plugins" depends="dist-optimized" description="Check of plugins binary compatibility" unless="isJava11">
[4166]678 <local name="dir"/>
679 <local name="plugins"/>
680 <property name="dir" value="plugin-check"/>
681 <typedef uri="antlib:org.codehaus.mojo.animal_sniffer">
[13209]682 <classpath path="${tools.dir}/animal-sniffer-ant-tasks.jar"/>
[4166]683 </typedef>
[13574]684 <delete dir="${dir}" failonerror="false"/>
[4166]685 <mkdir dir="${dir}"/>
686 <!-- List of deprecated plugins -->
[7133]687 <loadfile property="deprecated-plugins" srcFile="${src.dir}/org/openstreetmap/josm/plugins/PluginHandler.java">
[4166]688 <filterchain>
689 <linecontains>
690 <contains value="new DeprecatedPlugin("/>
691 </linecontains>
692 <tokenfilter>
693 <replaceregex pattern=".*new DeprecatedPlugin\(&quot;(.+?)&quot;.*" replace="\1|" flags="gi"/>
694 </tokenfilter>
695 <striplinebreaks/>
696 <tokenfilter>
697 <replaceregex pattern="\|$" replace="" flags="gi"/>
698 </tokenfilter>
699 </filterchain>
700 </loadfile>
[5498]701 <!-- Download list of plugins -->
[4166]702 <loadresource property="plugins">
[6955]703 <url url="https://josm.openstreetmap.de/plugin"/>
[4166]704 <filterchain>
705 <linecontainsregexp negate="true">
706 <regexp pattern="^\t.*"/>
707 </linecontainsregexp>
708 <linecontainsregexp negate="true">
709 <regexp pattern="${deprecated-plugins}"/>
710 </linecontainsregexp>
[14244]711 <linecontainsregexp negate="true" unless:set="isJava10">
[14383]712 <!-- Skip javafx on Java 8/9, built for Java 10+ only -->
713 <regexp pattern="javafx.*"/>
[14244]714 </linecontainsregexp>
[15234]715 <linecontainsregexp negate="true" unless:set="isJava11">
716 <!-- Skip http2 on Java 8/9/10, built for Java 11+ only -->
717 <regexp pattern="http2.*"/>
718 </linecontainsregexp>
[4166]719 <tokenfilter>
720 <replaceregex pattern="^.*;" replace="" flags="gi"/>
721 </tokenfilter>
722 </filterchain>
[6133]723 </loadresource>
724 <!-- Delete files that are not in plugin list (like old plugins) -->
725 <loadresource property="file-list">
726 <propertyresource name="plugins"/>
727 <filterchain>
728 <tokenfilter>
729 <replaceregex pattern="^.*/(.*)$" replace="\1\|" flags=""/>
730 </tokenfilter>
731 <striplinebreaks/>
732 <tokenfilter>
733 <replaceregex pattern="\|$" replace="" flags="gi"/>
[9765]734 </tokenfilter>
[6133]735 </filterchain>
736 </loadresource>
737 <delete>
738 <restrict>
739 <fileset dir="${dir}"/>
740 <not>
741 <name regex="${file-list}"/>
742 </not>
743 </restrict>
744 </delete>
745 <!-- Download plugins -->
[12874]746 <copy todir="${dir}" flatten="true" verbose="true" failonerror="false">
[4166]747 <resourcelist>
748 <string value="${plugins}"/>
749 </resourcelist>
750 </copy>
751 <!-- Check plugins -->
[5498]752 <as:build-signatures destfile="${dir}/api.sig">
753 <path>
[12628]754 <fileset file="${dist-optimized.jar}"/>
[14244]755 <fileset file="${java.home}/lib/rt.jar" unless:set="isJava9"/>
756 <fileset file="${java.home}/lib/jce.jar" unless:set="isJava9"/>
757 <fileset file="${java.home}/lib/ext/jfxrt.jar" unless:set="isJava9"/>
758 <fileset dir="${java.home}/jmods" if:set="isJava9"/>
[14997]759 <fileset dir="/usr/share/openjfx/lib" unless:set="isJava9"/>
[5498]760 </path>
[6133]761 </as:build-signatures>
[12873]762 <as:check-signature signature="${dir}/api.sig" failonerror="false">
[13711]763 <ignore classname="afu.*"/>
[13921]764 <ignore classname="android.*"/>
[12873]765 <ignore classname="au.*"/>
[7367]766 <ignore classname="com.*"/>
[12873]767 <ignore classname="de.*"/>
768 <ignore classname="edu.*"/>
769 <ignore classname="groovy.*"/>
[13962]770 <ignore classname="io.*"/>
[12873]771 <ignore classname="it.*"/>
[14167]772 <ignore classname="java.lang.invoke.MethodHandle"/>
[15639]773 <ignore classname="java.nio.ByteBuffer"/>
774 <ignore classname="java.nio.FloatBuffer"/>
[15387]775 <ignore classname="java.util.list.kotlin.*"/>
[7367]776 <ignore classname="javax.*"/>
[14245]777 <ignore classname="jdk.swing.interop.*"/>
[7367]778 <ignore classname="jogamp.*"/>
779 <ignore classname="junit.*"/>
[12873]780 <ignore classname="kdu_jni.*"/>
[15387]781 <ignore classname="kotlin.*"/>
[12873]782 <ignore classname="net.*"/>
783 <ignore classname="netscape.*"/>
784 <ignore classname="nu.*"/>
785 <ignore classname="oracle.*"/>
[7367]786 <ignore classname="org.apache.*"/>
[12873]787 <ignore classname="org.bouncycastle.*"/>
[13711]788 <ignore classname="org.checkerframework.*"/>
[7367]789 <ignore classname="org.codehaus.*"/>
[13921]790 <ignore classname="org.conscrypt.*"/>
[7367]791 <ignore classname="org.dom4j.*"/>
[12873]792 <ignore classname="org.eclipse.*"/>
793 <ignore classname="org.ejml.*"/>
[14164]794 <ignore classname="org.fusesource.*"/>
[12873]795 <ignore classname="org.gdal.*"/>
[15377]796 <ignore classname="org.geotools.data.h2.*"/>
797 <ignore classname="org.geotools.gce.imagemosaic.*"/>
[12873]798 <ignore classname="org.hibernate.*"/>
[7367]799 <ignore classname="org.hsqldb.*"/>
800 <ignore classname="org.ibex.*"/>
[7934]801 <ignore classname="org.iso_relax.*"/>
[7367]802 <ignore classname="org.jaitools.*"/>
803 <ignore classname="org.jaxen.*"/>
[12873]804 <ignore classname="org.jboss.*"/>
[14164]805 <ignore classname="org.jctools.*"/>
[13575]806 <ignore classname="org.jdom.*"/>
[7367]807 <ignore classname="org.jdom2.*"/>
[12873]808 <ignore classname="org.jfree.*"/>
[4166]809 <ignore classname="org.jgraph.*"/>
[12873]810 <ignore classname="org.joda.*"/>
[14164]811 <ignore classname="org.json.*"/>
[12873]812 <ignore classname="org.junit.*"/>
813 <ignore classname="org.jvnet.*"/>
[7367]814 <ignore classname="org.kxml2.*"/>
[15639]815 <ignore classname="org.locationtech.*"/>
[15462]816 <ignore classname="org.mozilla.*"/>
[8090]817 <ignore classname="org.objectweb.*"/>
[15387]818 <ignore classname="org.opentest4j.*"/>
[12873]819 <ignore classname="org.osgi.*"/>
820 <ignore classname="org.postgresql.*"/>
[7367]821 <ignore classname="org.python.*"/>
[12875]822 <ignore classname="org.seasar.*"/>
[7367]823 <ignore classname="org.slf4j.*"/>
[12873]824 <ignore classname="org.springframework.*"/>
825 <ignore classname="org.testng.*"/>
[13113]826 <ignore classname="org.w3c.*"/>
[12873]827 <ignore classname="org.zeromq.*"/>
[15540]828 <ignore classname="waffle.*"/>
[8173]829 <!-- plugins used by another ones -->
[7494]830 <ignore classname="org.openstreetmap.josm.plugins.geotools.*"/>
[14244]831 <ignore classname="org.openstreetmap.josm.plugins.jaxb.*"/>
[7934]832 <ignore classname="org.openstreetmap.josm.plugins.jna.*"/>
[7494]833 <ignore classname="org.openstreetmap.josm.plugins.jts.*"/>
834 <ignore classname="org.openstreetmap.josm.plugins.log4j.*"/>
[14244]835 <ignore classname="org.openstreetmap.josm.plugins.openjfx.*"/>
[7494]836 <ignore classname="org.openstreetmap.josm.plugins.utilsplugin2.*"/>
[12875]837 <ignore classname="sun.*"/>
[4166]838 <path path="${dir}"/>
839 </as:check-signature>
840 </target>
[4838]841
[16036]842 <target name="script-compile" depends="test-compile" description="Compiles all scripts">
[15033]843 <javac sourcepath="" srcdir="${base.dir}/scripts" failonerror="true" includes="*.java"
844 destdir="${script-build.dir}" target="${java.lang.version}" source="${java.lang.version}" debug="on"
845 includeantruntime="false" createMissingPackageInfoClass="false" encoding="UTF-8">
846 <classpath>
847 <pathelement path="${build.dir}"/>
848 <pathelement path="${test.dir}/build/unit"/>
849 <pathelement path="${commons-lang3.jar}"/>
850 </classpath>
[14636]851 </javac>
852 </target>
853
[8687]854 <macrodef name="_taginfo">
855 <attribute name="type"/>
856 <attribute name="output"/>
857 <sequential>
858 <echo message="Generating Taginfo for type @{type} to @{output}"/>
[14636]859 <java classname="TagInfoExtract" failonerror="true" fork="false">
860 <sysproperty key="java.awt.headless" value="true"/>
861 <classpath>
[16126]862 <pathelement path="${build.dir}"/>
[15033]863 <pathelement path="${script-build.dir}"/>
864 <pathelement path="${commons-lang3.jar}"/>
[14636]865 </classpath>
866 <arg value="--type"/>
[8687]867 <arg value="@{type}"/>
868 <arg value="--noexit"/>
869 <arg value="--imgurlprefix"/>
[14636]870 <arg value="http://josm.openstreetmap.de/download/taginfo/taginfo-img"/>
871 <arg value="--output"/>
[8687]872 <arg value="@{output}"/>
[14636]873 </java>
[8687]874 </sequential>
875 </macrodef>
876
[15033]877 <target name="taginfo" depends="script-compile">
[9250]878 <_taginfo type="mappaint" output="taginfo_style.json"/>
879 <_taginfo type="presets" output="taginfo_presets.json"/>
880 <_taginfo type="external_presets" output="taginfo_external_presets.json"/>
[8687]881 </target>
882
[15033]883 <target name="imageryindex" depends="init-properties,script-compile">
[9505]884 <echo message="Checking editor imagery difference"/>
[15033]885 <java classname="SyncEditorLayerIndex" failonerror="true" fork="false">
886 <classpath>
[16126]887 <pathelement path="${build.dir}"/>
[15033]888 <pathelement path="${script-build.dir}"/>
889 <pathelement path="${commons-lang3.jar}"/>
890 </classpath>
891 <arg value="--noeli"/>
892 <arg value="-p"/>
893 <arg value="imagery_eliout.imagery.xml"/>
894 <arg value="-q"/>
895 <arg value="imagery_josmout.imagery.xml"/>
896 </java>
[9505]897 </target>
898
899 <target name="imageryindexdownload">
900 <exec append="false" executable="wget" failifexecutionfails="true">
901 <arg value="https://josm.openstreetmap.de/maps"/>
902 <arg value="-O"/>
[11965]903 <arg value="imagery_josm.imagery.xml"/>
[9505]904 <arg value="--unlink"/>
905 </exec>
906 <exec append="false" executable="wget" failifexecutionfails="true">
[11238]907 <arg value="https://josm.openstreetmap.de/wiki/ImageryCompareIgnores?format=txt"/>
908 <arg value="-O"/>
[11965]909 <arg value="imagery_josm.ignores.txt"/>
[11238]910 <arg value="--unlink"/>
911 </exec>
912 <exec append="false" executable="wget" failifexecutionfails="true">
[11857]913 <arg value="https://raw.githubusercontent.com/osmlab/editor-layer-index/gh-pages/imagery.geojson"/>
[9505]914 <arg value="-O"/>
[11965]915 <arg value="imagery_eli.geojson"/>
[9505]916 <arg value="--unlink"/>
917 </exec>
918 <antcall target="imageryindex"/>
919 </target>
920
[12582]921 <target name="checkstyle-compile" depends="init-properties">
922 <mkdir dir="${checkstyle-build.dir}"/>
[13209]923 <javac sourcepath="" srcdir="${checkstyle.dir}/src" failonerror="true"
[12628]924 destdir="${checkstyle-build.dir}" target="${java.lang.version}" source="${java.lang.version}" debug="on"
[12582]925 includeantruntime="false" createMissingPackageInfoClass="false"
[13209]926 encoding="UTF-8" classpath="${checkstyle.dir}/checkstyle-all.jar">
[12582]927 </javac>
928 </target>
[13303]929 <target name="checkstyle-changed" depends="checkstyle-compile">
930 <exec append="false" osfamily="unix" executable="bash" failifexecutionfails="true">
931 <arg value="-c"/>
[15816]932 <arg value="(git ls-files src test --modified 2>/dev/null || svn status -q --ignore-externals src test) | grep -o '\(src\|test\)/.*' | xargs java -cp '${checkstyle.dir}/checkstyle-all.jar:${checkstyle-build.dir}' com.puppycrawl.tools.checkstyle.Main -c ${checkstyle.dir}/josm_checks.xml | sed -e 's:\([^ ]*\) [^:]*/\([^:/]*.java\:[^:]*\):(\2)\1:'"/>
[13303]933 </exec>
934 <exec append="false" osfamily="windows" executable="powershell" failifexecutionfails="true">
935 <arg value="/c"/>
936 <arg value="svn status -q --ignore-externals src test | ForEach-Object {java -cp '${checkstyle.dir}/checkstyle-all.jar;${checkstyle-build.dir}' com.puppycrawl.tools.checkstyle.Main -c ${checkstyle.dir}/josm_checks.xml $_.split(' ')[7]}"/>
937 </exec>
938 </target>
[12582]939 <target name="checkstyle" depends="checkstyle-compile">
[9765]940 <taskdef resource="com/puppycrawl/tools/checkstyle/ant/checkstyle-ant-task.properties"
[13209]941 classpath="${checkstyle.dir}/checkstyle-all.jar:${checkstyle-build.dir}"/>
942 <checkstyle config="${checkstyle.dir}/josm_checks.xml">
[9765]943 <fileset dir="${base.dir}/src/org/openstreetmap/josm" includes="**/*.java"
[9250]944 excludes="gui/mappaint/mapcss/parsergen/*.java"/>
[9765]945 <fileset dir="${base.dir}/test" includes="**/*.java"/>
[14637]946 <fileset dir="${base.dir}/scripts" includes="**/*.java"/>
[11681]947 <formatter type="plain"/>
[8508]948 <formatter type="xml" toFile="checkstyle-josm.xml"/>
949 </checkstyle>
950 </target>
951
[16020]952 <target name="spotbugs" depends="dist">
[16168]953 <ivy:cachepath file="${tools.ivy}" pathid="spotbugs.classpath" conf="spotbugs"/>
[16169]954 <taskdef name="spotbugs" classname="edu.umd.cs.findbugs.anttask.FindBugsTask" classpathref="spotbugs.classpath"/>
[12801]955 <spotbugs output="xml"
956 outputFile="spotbugs-josm.xml"
[16166]957 classpath="${toString:spotbugs.classpath}"
[6133]958 pluginList=""
[13209]959 excludeFilter="${spotbugs.dir}/josm-filter.xml"
[16020]960 onlyAnalyze="org.openstreetmap.josm.-"
[6133]961 effort="max"
[10223]962 reportLevel="low"
[6133]963 >
[16020]964 <class location="${dist.jar}" />
[12801]965 </spotbugs>
[4838]966 </target>
[11713]967
968 <target name="pmd" depends="init-properties">
[16168]969 <ivy:cachepath file="${tools.ivy}" pathid="pmd.classpath" conf="pmd"/>
[16169]970 <taskdef name="pmd" classname="net.sourceforge.pmd.ant.PMDTask" classpathref="pmd.classpath"/>
[13209]971 <pmd shortFilenames="true" cacheLocation="${pmd.dir}/cache" encoding="UTF-8">
[12628]972 <sourceLanguage name="java" version="${java.lang.version}" />
[13209]973 <ruleset>${pmd.dir}/josm-ruleset.xml</ruleset>
[11713]974 <formatter type="text" toConsole="true" />
975 <formatter type="xml" toFile="pmd-josm.xml">
976 <param name="encoding" value="UTF-8" />
977 </formatter>
978 <fileset dir="${src.dir}">
979 <include name="org/openstreetmap/josm/**/*.java"/>
980 <exclude name="org/openstreetmap/josm/gui/mappaint/mapcss/parsergen/*.java" />
981 </fileset>
[14638]982 <fileset dir="${base.dir}/scripts" includes="**/*.java"/>
[11713]983 </pmd>
984 </target>
985
[5323]986 <target name="run" depends="dist">
[12628]987 <java jar="${dist.jar}" fork="true">
[5323]988 <arg value="--set=expert=true"/>
[15797]989 <arg value="--set=iso.dates=true"/>
[5323]990 <jvmarg value="-Djosm.home=/tmp/.josm/"/>
991 </java>
992 </target>
[9765]993 <!--
994 ** Compile build script for generating projection list.
995 -->
[10850]996 <target name="epsg-compile" depends="init-properties">
[9765]997 <property name="proj-classpath" location="${build.dir}"/>
998 <mkdir dir="${proj-build.dir}"/>
[13794]999 <javac sourcepath="" srcdir="${base.dir}/scripts" failonerror="true" includes="BuildProjectionDefinitions.java"
[12628]1000 destdir="${proj-build.dir}" target="${java.lang.version}" source="${java.lang.version}" debug="on"
[9765]1001 includeantruntime="false" createMissingPackageInfoClass="false"
1002 encoding="UTF-8" classpath="${proj-classpath}">
[9133]1003 </javac>
1004 </target>
[9765]1005 <!--
1006 ** generate projection list.
1007 -->
[9133]1008 <target name="epsg" depends="epsg-compile">
[13236]1009 <touch file="${epsg.output}" mkdirs="true"/>
[10259]1010 <java classname="BuildProjectionDefinitions" failonerror="true" fork="true">
[9735]1011 <sysproperty key="java.awt.headless" value="true"/>
[9133]1012 <classpath>
[16140]1013 <pathelement path="${resources.dir}"/>
[9765]1014 <pathelement path="${proj-classpath}"/>
1015 <pathelement path="${proj-build.dir}"/>
[9133]1016 </classpath>
[9765]1017 <arg value="${base.dir}"/>
[9133]1018 </java>
1019 </target>
[14136]1020 <!--
[14568]1021 ** update projection test files after an update of projection definitions
1022 -->
1023 <target name="update-proj-files" depends="test-compile">
1024 <java classname="org.openstreetmap.josm.data.projection.ProjectionRefTest" failonerror="true" fork="true">
1025 <classpath>
1026 <path refid="test.classpath"/>
1027 <pathelement path="${test.dir}/build/unit"/>
1028 </classpath>
1029 </java>
1030 <java classname="org.openstreetmap.josm.data.projection.ProjectionRegressionTest" failonerror="true" fork="true">
1031 <classpath>
1032 <path refid="test.classpath"/>
1033 <pathelement path="${test.dir}/build/unit"/>
1034 </classpath>
1035 </java>
1036 </target>
1037 <!--
[14136]1038 ** generate jdeps dependency graph
1039 -->
1040 <target name="jdeps" depends="compile">
1041 <delete dir="${modules.dir}"/>
1042 <mkdir dir="${modules.dir}"/>
1043 <!-- JOSM only -->
1044 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/josm-actions.jar" includes="org/openstreetmap/josm/actions/**/*.class"/>
1045 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/josm-cli.jar" includes="org/openstreetmap/josm/cli/**/*.class"/>
1046 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/josm-command.jar" includes="org/openstreetmap/josm/command/**/*.class"/>
1047 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/josm-data.jar" includes="org/openstreetmap/josm/data/**/*.class"/>
1048 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/josm-gui.jar" includes="org/openstreetmap/josm/gui/**/*.class"/>
1049 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/josm-io.jar" includes="org/openstreetmap/josm/io/**/*.class"/>
1050 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/josm-plugins.jar" includes="org/openstreetmap/josm/plugins/**/*.class"/>
1051 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/josm-spi.jar" includes="org/openstreetmap/josm/spi/**/*.class"/>
1052 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/josm-tools.jar" includes="org/openstreetmap/josm/tools/**/*.class"/>
1053 <exec executable="jdeps" dir="${modules.dir}">
[16050]1054 <arg line="-f 'java.*|org.xml.*|org.w3c.*|sun.*|com.*|oauth.*|org.apache.*|org.glassfish.*|org.openstreetmap.gui.*'"/>
[14136]1055 <arg line="-dotoutput dots *.jar"/>
1056 </exec>
1057 <exec executable="dot" dir="${modules.dir}/dots">
1058 <arg line="-O -Tpng summary.dot"/>
1059 </exec>
1060 <move file="${modules.dir}/dots/summary.dot.png" tofile="${modules.dir}/josm-without-dependencies.png"/>
1061 <!-- Direct dependencies -->
[16050]1062 <copy todir="${modules.dir}" flatten="true">
1063 <fileset refid="runtime.fileset" />
1064 </copy>
[14136]1065 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/svgSalamander.jar" includes="com/kitfox/**/*.class"/>
1066 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/oauth-signpost.jar" includes="oauth/**/*.class"/>
1067 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/commons-jcs.jar" includes="org/apache/commons/jcs/**/*.class"/>
1068 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/jmapviewer.jar" includes="org/openstreetmap/gui/**/*.class"/>
1069 <exec executable="jdeps" dir="${modules.dir}">
1070 <arg line="-f 'java.*|org.xml.*|org.w3c.*|sun.*|com.sun.*|com.google.*|org.tukaani.*|org.apache.commons.logging.*'"/>
1071 <arg line="-dotoutput dots *.jar"/>
1072 </exec>
1073 <exec executable="dot" dir="${modules.dir}/dots">
1074 <arg line="-O -Tpng summary.dot"/>
1075 </exec>
1076 <move file="${modules.dir}/dots/summary.dot.png" tofile="${modules.dir}/josm-with-direct-dependencies.png"/>
1077 <!-- All dependencies -->
1078 <jar basedir="${build.dir}" level="${clevel}" destfile="${modules.dir}/google-gdata.jar" includes="com/google/**/*.class"/>
1079 <exec executable="jdeps" dir="${modules.dir}">
1080 <arg line="-dotoutput dots *.jar"/>
1081 </exec>
1082 <exec executable="dot" dir="${modules.dir}/dots">
1083 <arg line="-O -Tpng summary.dot"/>
1084 </exec>
1085 <move file="${modules.dir}/dots/summary.dot.png" tofile="${modules.dir}/josm-with-all-dependencies.png"/>
1086 </target>
[16050]1087 <target name="resolve" depends="init-ivy" unless="resolve.notRequired" description="Resolve Ivy dependencies">
[16125]1088 <ivy:settings file="${base.dir}/ivysettings.xml"/>
1089 <ivy:resolve file="${base.dir}/ivy.xml" keep="true"/>
[15977]1090 <ivy:report todir="${tools.dir}/ivy-report" graph="false"/>
1091 <ivy:cachepath pathid="compile.path" conf="compile"/>
1092 <ivy:cachepath pathid="runtime.path" conf="runtime"/>
1093 <ivy:cachefileset setid="runtime.fileset" conf="runtime"/>
1094 <ivy:cachepath pathid="test.path" conf="test"/>
1095 <ivy:retrieve pattern="${tools.dir}/ivy/[artifact]-[type].[ext]" conf="ivy"/>
1096 </target>
[16002]1097 <target name="extract-libraries" depends="resolve" description="extract libraries to build dir">
1098 <unzip dest="${build.dir}">
1099 <fileset refid="runtime.fileset"/>
1100 <patternset>
1101 <exclude name="META-INF/**"/>
1102 <exclude name="*"/>
[16027]1103 <exclude name="com/drew/imaging/FileTypeDetector*"/>
1104 <exclude name="com/drew/imaging/ImageMetadataReader*"/>
[16025]1105 <exclude name="com/drew/imaging/avi/**"/>
1106 <exclude name="com/drew/imaging/bmp/**"/>
1107 <exclude name="com/drew/imaging/eps/**"/>
1108 <exclude name="com/drew/imaging/gif/**"/>
1109 <exclude name="com/drew/imaging/heif/**"/>
1110 <exclude name="com/drew/imaging/ico/**"/>
1111 <exclude name="com/drew/imaging/mp3/**"/>
1112 <exclude name="com/drew/imaging/mp4/**"/>
1113 <exclude name="com/drew/imaging/pcx/**"/>
1114 <exclude name="com/drew/imaging/png/**"/>
1115 <exclude name="com/drew/imaging/psd/**"/>
1116 <exclude name="com/drew/imaging/quicktime/**"/>
1117 <exclude name="com/drew/imaging/raf/**"/>
1118 <exclude name="com/drew/imaging/riff/**"/>
1119 <exclude name="com/drew/imaging/wav/**"/>
1120 <exclude name="com/drew/imaging/webp/**"/>
1121 <exclude name="com/drew/metadata/avi/**"/>
1122 <exclude name="com/drew/metadata/bmp/**"/>
1123 <exclude name="com/drew/metadata/eps/**"/>
1124 <exclude name="com/drew/metadata/gif/**"/>
1125 <exclude name="com/drew/metadata/heif/**"/>
1126 <exclude name="com/drew/metadata/ico/**"/>
1127 <exclude name="com/drew/metadata/mov/**"/>
1128 <exclude name="com/drew/metadata/mp3/**"/>
1129 <exclude name="com/drew/metadata/mp4/**"/>
1130 <exclude name="com/drew/metadata/pcx/**"/>
1131 <exclude name="com/drew/metadata/png/**"/>
1132 <exclude name="com/drew/metadata/wav/**"/>
1133 <exclude name="com/drew/metadata/webp/**"/>
1134 <exclude name="com/drew/tools/**"/>
[16026]1135 <exclude name="org/apache/commons/compress/PasswordRequiredException*"/>
[16023]1136 <exclude name="org/apache/commons/compress/archivers/**"/>
1137 <exclude name="org/apache/commons/compress/changes/**"/>
[16026]1138 <exclude name="org/apache/commons/compress/compressors/bzip2/BZip2Utils*"/>
[16023]1139 <exclude name="org/apache/commons/compress/compressors/brotli/**"/>
[16026]1140 <exclude name="org/apache/commons/compress/compressors/CompressorStreamFactory*"/>
1141 <exclude name="org/apache/commons/compress/compressors/CompressorStreamProvider*"/>
1142 <exclude name="org/apache/commons/compress/compressors/CompressorException*"/>
1143 <exclude name="org/apache/commons/compress/compressors/FileNameUtil*"/>
[16023]1144 <exclude name="org/apache/commons/compress/compressors/deflate/**"/>
1145 <exclude name="org/apache/commons/compress/compressors/gzip/**"/>
1146 <exclude name="org/apache/commons/compress/compressors/lz4/**"/>
1147 <exclude name="org/apache/commons/compress/compressors/lzma/**"/>
1148 <exclude name="org/apache/commons/compress/compressors/lz77support/**"/>
1149 <exclude name="org/apache/commons/compress/compressors/pack200/**"/>
1150 <exclude name="org/apache/commons/compress/compressors/snappy/**"/>
[16026]1151 <exclude name="org/apache/commons/compress/compressors/xz/XZUtils*"/>
[16023]1152 <exclude name="org/apache/commons/compress/compressors/z/**"/>
1153 <exclude name="org/apache/commons/compress/compressors/zstandard/**"/>
1154 <exclude name="org/apache/commons/compress/parallel/**"/>
[16026]1155 <exclude name="org/apache/commons/compress/utils/ArchiveUtils*"/>
1156 <exclude name="org/apache/commons/logging/impl/AvalonLogger*"/>
1157 <exclude name="org/apache/commons/logging/impl/Jdk13LumberjackLogger*"/>
1158 <exclude name="org/apache/commons/logging/impl/Log4JLogger*"/>
1159 <exclude name="org/apache/commons/logging/impl/LogKitLogger*"/>
1160 <exclude name="org/apache/commons/logging/impl/ServletContextCleaner*"/>
[16002]1161 </patternset>
1162 </unzip>
1163 </target>
[16150]1164 <target name="sources" description="Generates jar file of JOSM source files and its dependencies" depends="init,epsg,resolve">
[16141]1165 <ivy:cachefileset setid="sources.fileset" conf="sources"/>
1166 <jar destfile="${dist-sources.jar}" level="${clevel}">
1167 <zipgroupfileset refid="sources.fileset"/>
1168 <fileset dir="${src.dir}"/>
1169 <fileset dir="${resources.dir}"/>
1170 <fileset file="CONTRIBUTION"/>
1171 <fileset file="README"/>
1172 <fileset file="LICENSE"/>
1173 </jar>
1174 </target>
[15977]1175 <target name="bootstrap-workspace" description="Copy libraries from ivy cache to workspace folders for IDE" depends="resolve">
1176 <delete dir="${lib.dir}"/>
1177 <ivy:retrieve pattern="${lib.dir}/compile/[artifact]-[type].[ext]" conf="compile"/>
1178 <ivy:retrieve pattern="${lib.dir}/runtime/[artifact]-[type].[ext]" conf="runtime"/>
[16141]1179 <ivy:retrieve pattern="${lib.dir}/sources/[artifact]-[type].[ext]" conf="sources"/>
[16168]1180 <ivy:retrieve pattern="${lib.dir}/tools/[artifact]-[type].[ext]" conf="javacc" file="${tools.ivy}"/>
[15977]1181 </target>
[4166]1182</project>
Note: See TracBrowser for help on using the repository browser.