source: josm/trunk/netbeans/nbbuild.xml@ 7193

Last change on this file since 7193 was 7182, checked in by akks, 10 years ago

see #10072: color large GPS points like the track segments
use draw.rawgps.large.alpha parameter for transparency
updated Netbeans project (JAXB)

File size: 6.3 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!-- You may freely edit this file. See commented blocks below for -->
3<!-- some examples of how to customize the build. -->
4<!-- (If you delete it and reopen the project it will be recreated.) -->
5<!-- By default, only the Clean and Build commands use this build script. -->
6<!-- Commands such as Run, Debug, and Test only use this build script if -->
7<!-- the Compile on Save feature is turned off for the project. -->
8<!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
9<!-- in the project's Project Properties dialog box.-->
10<project name="josm" default="default" basedir=".">
11 <description>Builds, tests, and runs the project josm.</description>
12
13 <property name="javacc.home" location="../tools"/>
14 <property name="mapcss.dir" location="../src/org/openstreetmap/josm/gui/mappaint/mapcss"/>
15 <property name="imagerytypes.dir" location="${src.dir}/org/openstreetmap/josm/data/imagery/types"/>
16
17 <import file="nbproject/build-impl.xml"/>
18 <!--
19
20 There exist several targets which are by default empty and which can be
21 used for execution of your tasks. These targets are usually executed
22 before and after some main targets. They are:
23
24 -pre-init: called before initialization of project properties
25 -post-init: called after initialization of project properties
26 -pre-compile: called before javac compilation
27 -post-compile: called after javac compilation
28 -pre-compile-single: called before javac compilation of single file
29 -post-compile-single: called after javac compilation of single file
30 -pre-compile-test: called before javac compilation of JUnit tests
31 -post-compile-test: called after javac compilation of JUnit tests
32 -pre-compile-test-single: called before javac compilation of single JUnit test
33 -post-compile-test-single: called after javac compilation of single JUunit test
34 -pre-jar: called before JAR building
35 -post-jar: called after JAR building
36 -post-clean: called after cleaning build products
37
38 (Targets beginning with '-' are not intended to be called on their own.)
39
40 Example of inserting an obfuscator after compilation could look like this:
41
42 <target name="-post-compile">
43 <obfuscate>
44 <fileset dir="${build.classes.dir}"/>
45 </obfuscate>
46 </target>
47
48 For list of available properties check the imported
49 nbproject/build-impl.xml file.
50
51
52 Another way to customize the build is by overriding existing main targets.
53 The targets of interest are:
54
55 -init-macrodef-javac: defines macro for javac compilation
56 -init-macrodef-junit: defines macro for junit execution
57 -init-macrodef-debug: defines macro for class debugging
58 -init-macrodef-java: defines macro for class execution
59 -do-jar-with-manifest: JAR building (if you are using a manifest)
60 -do-jar-without-manifest: JAR building (if you are not using a manifest)
61 run: execution of project
62 -javadoc-build: Javadoc generation
63 test-report: JUnit report generation
64
65 An example of overriding the target for project execution could look like this:
66
67 <target name="run" depends="josm-impl.jar">
68 <exec dir="bin" executable="launcher.exe">
69 <arg file="${dist.jar}"/>
70 </exec>
71 </target>
72
73 Notice that the overridden target depends on the jar target and not only on
74 the compile target as the regular run target does. Again, for a list of available
75 properties which you can use, check the target you are overriding in the
76 nbproject/build-impl.xml file.
77
78 -->
79
80 <target name="-post-compile">
81 <!-- create the REVISION file to be included in the distribution -->
82 <exec append="false" output="REVISION.XML" executable="svn" dir=".." failifexecutionfails="false">
83 <env key="LANG" value="C"/>
84 <arg value="info"/>
85 <arg value="--xml"/>
86 <arg value="."/>
87 </exec>
88 <xmlproperty file="REVISION.XML" prefix="version" keepRoot="false" collapseAttributes="true"/>
89 <delete file="REVISION.XML" />
90 <tstamp>
91 <format property="build.tstamp" pattern="yyyy-MM-dd HH:mm:ss"/>
92 </tstamp>
93
94 <property name="version.entry.commit.revision" value="UNKNOWN"/>
95 <echo file="${build.classes.dir}/REVISION">
96# automatically generated by JOSM build.xml - do not edit
97Revision: ${version.entry.commit.revision}
98Is-Local-Build: true
99Build-Date: ${build.tstamp}
100</echo>
101 </target>
102
103 <target name="check-javacc">
104 <uptodate property="javacc.notRequired" targetfile="${mapcss.dir}/parsergen/MapCSSParser.java" >
105 <srcfiles dir="${mapcss.dir}" includes="MapCSSParser.jj"/>
106 </uptodate>
107 </target>
108 <target name="javacc" depends="check-javacc" unless="javacc.notRequired">
109 <mkdir dir="${mapcss.dir}/parsergen"/>
110 <exec append="false" executable="java" failifexecutionfails="true">
111 <arg value="-cp"/>
112 <arg value="${javacc.home}/javacc.jar"/>
113 <arg value="javacc"/>
114 <arg value="-DEBUG_PARSER=false"/>
115 <arg value="-DEBUG_TOKEN_MANAGER=false"/>
116 <arg value="-JDK_VERSION=1.7"/>
117 <arg value="-GRAMMAR_ENCODING=UTF-8"/>
118 <arg value="-OUTPUT_DIRECTORY=${mapcss.dir}/parsergen"/>
119 <arg value="${mapcss.dir}/MapCSSParser.jj"/>
120 </exec>
121 </target>
122 <target name="jaxb" depends="init" unless="jaxb.notRequired">
123 <taskdef name="xjc" classname="com.sun.tools.xjc.XJCTask">
124 <classpath>
125 <fileset dir="${src.dir}/../tools/jaxb" includes="*.jar"/>
126 </classpath>
127 </taskdef>
128 <xjc schema="../data_nodist/wms-cache.xsd" destdir="${src.dir}" encoding="UTF-8">
129 <depends dir="${src.dir}/org/openstreetmap/josm/data/imagery" includes="WmsCache.java"/>
130 <produces dir="${imagerytypes.dir}" includes="*.java"/>
131 </xjc>
132 </target>
133
134 <target name="-pre-compile" depends="javacc,jaxb">
135<!-- <javacc target="${mapcss.dir}/MapCSSParser.jj" javacchome="${javacc.home}" outputdirectory="${mapcss.dir}/parsergen"/>-->
136 </target>
137</project>
Note: See TracBrowser for help on using the repository browser.