Ticket #16860: ivy-jmapviewer.patch
| File ivy-jmapviewer.patch, 13.8 KB (added by , 7 years ago) |
|---|
-
.classpath
32 32 <attribute name="test" value="true"/> 33 33 </attributes> 34 34 </classpathentry> 35 <classpathentry kind="con" path="org.apache.ivyde.eclipse.cpcontainer.IVYDE_CONTAINER/?project=JOSM&ivyXmlPath=ivy.xml&confs=*"/> 35 36 <classpathentry kind="lib" path="test/lib/jfcunit.jar"> 36 37 <attributes> 37 38 <attribute name="test" value="true"/> -
.project
43 43 <nature>org.sonar.ide.eclipse.core.sonarNature</nature> 44 44 <nature>sf.eclipse.javacc.javaccnature</nature> 45 45 <nature>net.sf.eclipsecs.core.CheckstyleNature</nature> 46 <nature>org.apache.ivyde.eclipse.ivynature</nature> 46 47 </natures> 47 48 </projectDescription> -
build.xml
8 8 ** https://josm.openstreetmap.de/wiki/DevelopersGuide/CreateBuild 9 9 ** 10 10 --> 11 <project xmlns:as="antlib:org.codehaus.mojo.animal_sniffer" name="josm" default="dist" xmlns:jacoco="antlib:org.jacoco.ant" xmlns:if="ant:if" xmlns:unless="ant:unless"> 12 <target name="init-properties"> 11 <project xmlns:as="antlib:org.codehaus.mojo.animal_sniffer" name="josm" default="dist" 12 xmlns:jacoco="antlib:org.jacoco.ant" 13 xmlns:if="ant:if" 14 xmlns:unless="ant:unless" 15 xmlns:ivy="antlib:org.apache.ivy.ant" 16 > 17 <target name="init-ivy"> 18 <dirname property="base.dir" file="${ant.file.josm}"/> 19 <property name="lib.dir" location="${base.dir}/lib"/> 20 <property name="tools.dir" location="${base.dir}/tools"/> 21 <taskdef resource="org/apache/ivy/ant/antlib.xml" uri="antlib:org.apache.ivy.ant" classpath="${tools.dir}/ivy/ivy.jar"/> 22 </target> 23 <target name="init-properties" depends="resolve"> 13 24 <property environment="env"/> 14 25 <!-- Load properties in a target and not at top level, so this build file can be 15 26 imported from an IDE ant file (Netbeans) without messing up IDE properties. … … 16 27 When imported from another file, ${basedir} will point to the parent directory 17 28 of the importing ant file. Use ${base.dir} instead, which is always the parent 18 29 directory of this file. --> 19 <dirname property="base.dir" file="${ant.file.josm}"/>20 30 <property name="test.dir" location="${base.dir}/test"/> 21 31 <property name="src.dir" location="${base.dir}/src"/> 22 32 <condition property="noJavaFX"> … … 30 40 <property name="build.dir" location="${base.dir}/build"/> 31 41 <property name="dist.dir" location="${base.dir}/dist"/> 32 42 <property name="modules.dir" location="${dist.dir}/modules"/> 33 <property name="tools.dir" location="${base.dir}/tools"/>34 43 <property name="pmd.dir" location="${tools.dir}/pmd"/> 35 44 <property name="checkstyle.dir" location="${tools.dir}/checkstyle"/> 36 45 <property name="spotbugs.dir" location="${tools.dir}/spotbugs"/> … … 178 187 <copy file="LICENSE" todir="${build.dir}"/> 179 188 <!-- create josm-custom.jar --> 180 189 <delete file="${dist.jar}"/> 190 <!-- extract libraries to build dir to create uber-jar --> 191 <unzip dest="${build.dir}"> 192 <fileset refid="runtime.fileset" /> 193 <patternset> 194 <exclude name="META-INF/**" /> 195 <exclude name="*" /> 196 </patternset> 197 </unzip> 198 181 199 <jar destfile="${dist.jar}" basedir="${build.dir}" level="${clevel}"> 182 200 <!-- add attribute excludes="**/*BZip2*,**/*Bzip2*" to create a non-bzip2 supporting jar --> 183 201 <manifest> … … 195 213 <zipfileset dir="images" prefix="images"/> 196 214 <zipfileset dir="data" prefix="data"/> 197 215 <zipfileset dir="styles" prefix="styles"/> 198 <zipfileset dir="${src.dir}/org/openstreetmap/gui/jmapviewer/images" prefix="org/openstreetmap/gui/jmapviewer/images"/>199 216 </jar> 200 217 </target> 201 218 <!-- Mac OS X target --> … … 325 342 <exclude name="org/apache/commons/logging/impl/ServletContextCleaner.java"/> 326 343 </javac> 327 344 </target> 328 <target name="compile-jmapviewer" depends="init"> 329 <!-- JMapViewer --> 330 <javac sourcepath="" srcdir="${src.dir}" fork="yes" 331 excludes="com/**,javax/**,oauth/**,org/apache/commons/**,org/glassfish/**,org/openstreetmap/gui/jmapviewer/Demo.java,org/openstreetmap/gui/jmapviewer/JMapViewerTree.java,org/openstreetmap/gui/jmapviewer/checkBoxTree/**,org/openstreetmap/josm/**,org/tukaani/**,gnu/**" 332 destdir="${build.dir}" target="${java.lang.version}" source="${java.lang.version}" debug="on" includeantruntime="false" createMissingPackageInfoClass="false" encoding="UTF-8"> 333 <compilerarg value="-J-Xbootclasspath/p:${error_prone_javac.jar}" unless:set="isJava9"/> 334 <compilerarg line="-XDcompilePolicy=simple"/> 335 <compilerarg value="-processorpath"/> 336 <compilerarg pathref="processor.path"/> 337 <compilerarg value="-Xlint:cast"/> 338 <compilerarg value="-Xlint:deprecation"/> 339 <compilerarg value="-Xlint:dep-ann"/> 340 <compilerarg value="-Xlint:divzero"/> 341 <compilerarg value="-Xlint:empty"/> 342 <compilerarg value="-Xlint:finally"/> 343 <compilerarg value="-Xlint:overrides"/> 344 <!--<compilerarg value="-Xlint:rawtypes"/>--> 345 <compilerarg value="-Xlint:static"/> 346 <compilerarg value="-Xlint:try"/> 347 <compilerarg value="-Xlint:unchecked"/> 348 <!-- Undocumented argument to ignore "Sun internal proprietary API" warning, see http://stackoverflow.com/a/13862308/2257172 --> 349 <compilerarg value="-XDignore.symbol.file"/> 350 <compilerarg value="-Xplugin:ErrorProne -Xep:CatchAndPrintStackTrace:OFF -Xep:ReferenceEquality:OFF -Xep:StringSplitter:OFF"/> 351 <compilerarg line="-Xmaxwarns 1000"/> 352 </javac> 353 </target> 354 <target name="compile" depends="init,javacc,compile-cots,compile-jmapviewer"> 345 <target name="compile" depends="init,javacc,compile-cots"> 355 346 <!-- JOSM --> 356 347 <javac sourcepath="" srcdir="${src.dir}" fork="yes" 357 348 excludes="com/**,javax/**,gnu/**,oauth/**,org/apache/commons/**,org/glassfish/**,org/openstreetmap/gui/jmapviewer/**,org/tukaani/**" … … 376 367 <compilerarg value="-Xplugin:ErrorProne -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"/> 377 368 <compilerarg line="-Xmaxwarns 1000"/> 378 369 <exclude name="org/openstreetmap/josm/io/audio/fx/*.java" if:set="noJavaFX"/> 370 <classpath> 371 <path refid="runtime.path" /> 372 </classpath> 379 373 </javac> 380 374 381 375 <copy todir="build" failonerror="no" includeemptydirs="no"> … … 393 387 <javadoc destdir="javadoc" 394 388 sourcepath="${src.dir}" 395 389 encoding="UTF-8" 396 packagenames="org.openstreetmap.josm.* ,org.openstreetmap.gui.jmapviewer.*"390 packagenames="org.openstreetmap.josm.*" 397 391 excludepackagenames="org.openstreetmap.josm.gui.mappaint.mapcss.parsergen.*" 398 392 windowtitle="JOSM" 399 393 use="true" … … 830 824 <attribute name="output"/> 831 825 <sequential> 832 826 <echo message="Generating Taginfo for type @{type} to @{output}"/> 833 <groovy src="${taginfoextract}" classpath="${dist.jar};${toString:groovy.classpath};${spotbugs.dir}/spotbugs-annotations.jar"> 827 <groovy src="${taginfoextract}"> 828 <classpath> 829 <pathelement location="${dist.jar}" /> 830 <pathelement location="${spotbugs.dir}/spotbugs-annotations.jar" /> 831 <path refid="groovy.classpath" /> 832 <path refid="compile.path" /> 833 </classpath> 834 834 <arg value="-t"/> 835 835 <arg value="@{type}"/> 836 836 <arg value="--noexit"/> … … 919 919 920 920 <target name="spotbugs" depends="dist"> 921 921 <taskdef name="spotbugs" classname="edu.umd.cs.findbugs.anttask.FindBugsTask" classpath="${spotbugs.dir}/spotbugs-ant.jar"/> 922 <path id="spotbugs -classpath">922 <path id="spotbugs.classpath"> 923 923 <fileset dir="${spotbugs.dir}"> 924 924 <include name="*.jar"/> 925 925 </fileset> 926 926 </path> 927 <property name="spotbugs-classpath" refid="spotbugs-classpath"/>928 927 <spotbugs output="xml" 929 928 outputFile="spotbugs-josm.xml" 930 classpath="${spotbugs-classpath}"931 929 pluginList="" 932 930 excludeFilter="${spotbugs.dir}/josm-filter.xml" 933 931 effort="max" 934 932 reportLevel="low" 935 933 > 934 <classpath> 935 <path refid="spotbugs.classpath" /> 936 <path refid="compile.path" /> 937 </classpath> 936 938 <sourcePath path="${base.dir}/src" /> 937 939 <class location="${dist.jar}" /> 938 940 </spotbugs> … … 1044 1046 </exec> 1045 1047 <move file="${modules.dir}/dots/summary.dot.png" tofile="${modules.dir}/josm-with-all-dependencies.png"/> 1046 1048 </target> 1049 <target name="resolve" depends="init-ivy"> 1050 <ivy:resolve keep="true"/> 1051 <ivy:report todir="${tools.dir}/ivy-report" graph="false"/> 1052 <ivy:cachepath pathid="compile.path" conf="compile"/> 1053 <ivy:cachepath pathid="runtime.path" conf="runtime"/> 1054 <ivy:cachefileset setid="runtime.fileset" conf="runtime"/> 1055 <ivy:cachepath pathid="test.path" conf="test"/> 1056 <ivy:cachepath pathid="groovy-ant.path" conf="groovy-ant-task"/> 1057 <ivy:cachepath pathid="groovy-scripts.path" conf="groovy-scripts"/> 1058 <ivy:retrieve pattern="${tools.dir}/ivy/[artifact].[ext]" conf="ivy"/> 1059 </target> 1060 <target name="bootstrap-workspace" description="Copy libraries from ivy cache to workspace folders for IDE" depends="resolve"> 1061 <delete dir="${lib.dir}"/> 1062 <ivy:retrieve pattern="${lib.dir}/compile/[artifact].[ext]" conf="compile"/> 1063 <ivy:retrieve pattern="${lib.dir}/runtime/[artifact].[ext]" conf="runtime"/> 1064 </target> 1065 1047 1066 </project> -
ivy.xml
1 <?xml version="1.0" encoding="utf-8"?> 2 3 <ivy-module version="2.0"> 4 <info organisation="org.openstreetmap" module="josm"/> 5 <configurations> 6 <conf name="groovy-scripts" description="Dependencies for Groovy scripts" /> 7 <conf name="groovy-ant-task" description="Dependencies for Groovy scripts" /> 8 <conf name="ivy" description="Apache Ivy configration for self-update" /> 9 <!-- configuration that should be used when specifying dependencies --> 10 <conf name="implementation" description="All libs JOSM uses that plugins should not use" /> 11 <conf name="api" description="All libs that JOSM uses and are available for plugins" /> 12 <conf name="runtimeOnly" description="The libs shipped with JOSM that we do not need during compilation" /> 13 <conf name="provided" description="The libs we need during compilation but not on application start" /> 14 <conf name="epsg" description="Everything epsg needs- which is currently all of JOSM." /> 15 <!-- Meta configuration used in build scripts --> 16 <conf name="runtime" description="Libraries only needed at runtime" extends="implementation,api,runtimeOnly"/> 17 <conf name="compile" description="Libraries needed only for compilation" extends="implementation,api,provided" /> 18 <conf name="test" description="Libraries only needed for testing" extends="compile,runtime" /> 19 </configurations> 20 <dependencies> 21 <!-- api --> 22 <!-- https://mvnrepository.com/artifact/org.openstreetmap.jmapviewer/jmapviewer --> 23 <dependency org="org.openstreetmap.jmapviewer" name="jmapviewer" rev="2.7" conf="api->default"/> 24 </dependencies> 25 </ivy-module> -
ivysettings.xml
1 <ivysettings> 2 <settings defaultResolver="chain"/> 3 <resolvers> 4 <chain name="chain"> 5 <ibiblio name="josm-nexus" m2compatible="true" root="https://josm.openstreetmap.de/nexus/content/repositories/public/" /> 6 </chain> 7 </resolvers> 8 </ivysettings> -
src/org/openstreetmap
