34320
|
1 |
<?xml version="1.0" encoding="UTF-8"?>
|
|
2 |
<!--
|
|
3 |
*** GENERATED FROM project.xml - DO NOT EDIT ***
|
|
4 |
*** EDIT ../build.xml INSTEAD ***
|
|
5 |
|
|
6 |
For the purpose of easier reading the script
|
|
7 |
is divided into following sections:
|
|
8 |
|
|
9 |
- initialization
|
|
10 |
- compilation
|
|
11 |
- jar
|
|
12 |
- execution
|
|
13 |
- debugging
|
|
14 |
- javadoc
|
|
15 |
- junit compilation
|
|
16 |
- junit execution
|
|
17 |
- junit debugging
|
|
18 |
- applet
|
|
19 |
- cleanup
|
|
20 |
|
|
21 |
-->
|
|
22 |
<project xmlns:jaxrpc="http://www.netbeans.org/ns/scala-project/jax-rpc" xmlns:scalaProject1="http://www.netbeans.org/ns/scala-project/1" basedir=".." default="default" name="Isabelle-jEdit-impl">
|
|
23 |
<target depends="test,jar,javadoc" description="Build and test whole project." name="default"/>
|
|
24 |
<!--
|
|
25 |
======================
|
|
26 |
INITIALIZATION SECTION
|
|
27 |
======================
|
|
28 |
-->
|
|
29 |
<target name="-pre-init">
|
|
30 |
<!-- Empty placeholder for easier customization. -->
|
|
31 |
<!-- You can override this target in the ../build.xml file. -->
|
|
32 |
</target>
|
|
33 |
<target depends="-pre-init" name="-init-private">
|
|
34 |
<property file="nbproject/private/config.properties"/>
|
|
35 |
<property file="nbproject/private/configs/${config}.properties"/>
|
|
36 |
<property file="nbproject/private/private.properties"/>
|
|
37 |
<property environment="env"/>
|
|
38 |
<condition property="scala.home" value="${env.SCALA_HOME}">
|
|
39 |
<isset property="env.SCALA_HOME"/>
|
|
40 |
</condition>
|
|
41 |
<fail unless="scala.home">
|
|
42 |
You must set SCALA_HOME or environment property and append "-J-Dscala.home=scalahomepath"
|
|
43 |
property to the end of "netbeans_default_options" in NetBeansInstallationPath/etc/netbeans.conf to point to
|
|
44 |
Scala installation directory.
|
|
45 |
</fail>
|
|
46 |
<property name="scala.compiler" value="${scala.home}/lib/scala-compiler.jar"/>
|
|
47 |
<property name="scala.library" value="${scala.home}/lib/scala-library.jar"/>
|
|
48 |
<taskdef resource="scala/tools/ant/antlib.xml">
|
|
49 |
<classpath>
|
|
50 |
<pathelement location="${scala.compiler}"/>
|
|
51 |
<pathelement location="${scala.library}"/>
|
|
52 |
</classpath>
|
|
53 |
</taskdef>
|
|
54 |
</target>
|
|
55 |
<target depends="-pre-init,-init-private" name="-init-user">
|
|
56 |
<property file="${user.properties.file}"/>
|
|
57 |
<!-- The two properties below are usually overridden -->
|
|
58 |
<!-- by the active platform. Just a fallback. -->
|
|
59 |
<property name="default.javac.source" value="1.4"/>
|
|
60 |
<property name="default.javac.target" value="1.4"/>
|
|
61 |
</target>
|
|
62 |
<target depends="-pre-init,-init-private,-init-user" name="-init-project">
|
|
63 |
<property file="nbproject/configs/${config}.properties"/>
|
|
64 |
<property file="nbproject/project.properties"/>
|
|
65 |
</target>
|
|
66 |
<target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init">
|
|
67 |
<available file="${manifest.file}" property="manifest.available"/>
|
|
68 |
<condition property="manifest.available+main.class">
|
|
69 |
<and>
|
|
70 |
<isset property="manifest.available"/>
|
|
71 |
<isset property="main.class"/>
|
|
72 |
<not>
|
|
73 |
<equals arg1="${main.class}" arg2="" trim="true"/>
|
|
74 |
</not>
|
|
75 |
</and>
|
|
76 |
</condition>
|
|
77 |
<condition property="manifest.available+main.class+mkdist.available">
|
|
78 |
<and>
|
|
79 |
<istrue value="${manifest.available+main.class}"/>
|
|
80 |
<isset property="libs.CopyLibs.classpath"/>
|
|
81 |
</and>
|
|
82 |
</condition>
|
|
83 |
<condition property="have.tests">
|
|
84 |
<or/>
|
|
85 |
</condition>
|
|
86 |
<condition property="have.sources">
|
|
87 |
<or>
|
|
88 |
<available file="${src.dir}"/>
|
|
89 |
</or>
|
|
90 |
</condition>
|
|
91 |
<condition property="netbeans.home+have.tests">
|
|
92 |
<and>
|
|
93 |
<isset property="netbeans.home"/>
|
|
94 |
<isset property="have.tests"/>
|
|
95 |
</and>
|
|
96 |
</condition>
|
|
97 |
<condition property="no.javadoc.preview">
|
|
98 |
<and>
|
|
99 |
<isset property="javadoc.preview"/>
|
|
100 |
<isfalse value="${javadoc.preview}"/>
|
|
101 |
</and>
|
|
102 |
</condition>
|
|
103 |
<property name="run.jvmargs" value=""/>
|
|
104 |
<property name="javac.compilerargs" value=""/>
|
|
105 |
<property name="work.dir" value="${basedir}"/>
|
|
106 |
<condition property="no.deps">
|
|
107 |
<and>
|
|
108 |
<istrue value="${no.dependencies}"/>
|
|
109 |
</and>
|
|
110 |
</condition>
|
|
111 |
<property name="javac.debug" value="true"/>
|
|
112 |
<property name="javadoc.preview" value="true"/>
|
|
113 |
<property name="application.args" value=""/>
|
|
114 |
<property name="source.encoding" value="${file.encoding}"/>
|
|
115 |
<condition property="javadoc.encoding.used" value="${javadoc.encoding}">
|
|
116 |
<and>
|
|
117 |
<isset property="javadoc.encoding"/>
|
|
118 |
<not>
|
|
119 |
<equals arg1="${javadoc.encoding}" arg2=""/>
|
|
120 |
</not>
|
|
121 |
</and>
|
|
122 |
</condition>
|
|
123 |
<property name="javadoc.encoding.used" value="${source.encoding}"/>
|
|
124 |
<property name="includes" value="**"/>
|
|
125 |
<property name="excludes" value=""/>
|
|
126 |
<property name="do.depend" value="false"/>
|
|
127 |
<condition property="do.depend.true">
|
|
128 |
<istrue value="${do.depend}"/>
|
|
129 |
</condition>
|
|
130 |
<condition else="" property="javac.compilerargs.jaxws" value="-Djava.endorsed.dirs='${jaxws.endorsed.dir}'">
|
|
131 |
<and>
|
|
132 |
<isset property="jaxws.endorsed.dir"/>
|
|
133 |
<available file="nbproject/jaxws-build.xml"/>
|
|
134 |
</and>
|
|
135 |
</condition>
|
|
136 |
</target>
|
|
137 |
<target name="-post-init">
|
|
138 |
<!-- Empty placeholder for easier customization. -->
|
|
139 |
<!-- You can override this target in the ../build.xml file. -->
|
|
140 |
</target>
|
|
141 |
<target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check">
|
|
142 |
<fail unless="src.dir">Must set src.dir</fail>
|
|
143 |
<fail unless="build.dir">Must set build.dir</fail>
|
|
144 |
<fail unless="dist.dir">Must set dist.dir</fail>
|
|
145 |
<fail unless="build.classes.dir">Must set build.classes.dir</fail>
|
|
146 |
<fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail>
|
|
147 |
<fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail>
|
|
148 |
<fail unless="build.test.results.dir">Must set build.test.results.dir</fail>
|
|
149 |
<fail unless="build.classes.excludes">Must set build.classes.excludes</fail>
|
|
150 |
<fail unless="dist.jar">Must set dist.jar</fail>
|
|
151 |
</target>
|
|
152 |
<target name="-init-macrodef-property">
|
|
153 |
<macrodef name="property" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
154 |
<attribute name="name"/>
|
|
155 |
<attribute name="value"/>
|
|
156 |
<sequential>
|
|
157 |
<property name="@{name}" value="${@{value}}"/>
|
|
158 |
</sequential>
|
|
159 |
</macrodef>
|
|
160 |
</target>
|
|
161 |
<target name="-init-macrodef-javac">
|
|
162 |
<macrodef name="javac" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
163 |
<attribute default="${src.dir}" name="srcdir"/>
|
|
164 |
<attribute default="${build.classes.dir}" name="destdir"/>
|
|
165 |
<attribute default="${javac.classpath}" name="classpath"/>
|
|
166 |
<attribute default="${includes}" name="includes"/>
|
|
167 |
<attribute default="${excludes}" name="excludes"/>
|
|
168 |
<attribute default="${javac.debug}" name="debug"/>
|
|
169 |
<attribute default="" name="sourcepath"/>
|
|
170 |
<element name="customize" optional="true"/>
|
|
171 |
<sequential>
|
|
172 |
<javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}">
|
|
173 |
<classpath>
|
|
174 |
<path path="@{classpath}"/>
|
|
175 |
</classpath>
|
|
176 |
<compilerarg line="${javac.compilerargs} ${javac.compilerargs.jaxws}"/>
|
|
177 |
<customize/>
|
|
178 |
</javac>
|
|
179 |
</sequential>
|
|
180 |
</macrodef>
|
|
181 |
<macrodef name="depend" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
182 |
<attribute default="${src.dir}" name="srcdir"/>
|
|
183 |
<attribute default="${build.classes.dir}" name="destdir"/>
|
|
184 |
<attribute default="${javac.classpath}" name="classpath"/>
|
|
185 |
<sequential>
|
|
186 |
<depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}">
|
|
187 |
<classpath>
|
|
188 |
<path path="@{classpath}"/>
|
|
189 |
</classpath>
|
|
190 |
</depend>
|
|
191 |
</sequential>
|
|
192 |
</macrodef>
|
|
193 |
<macrodef name="force-recompile" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
194 |
<attribute default="${build.classes.dir}" name="destdir"/>
|
|
195 |
<sequential>
|
|
196 |
<fail unless="javac.includes">Must set javac.includes</fail>
|
|
197 |
<pathconvert pathsep="," property="javac.includes.binary">
|
|
198 |
<path>
|
|
199 |
<filelist dir="@{destdir}" files="${javac.includes}"/>
|
|
200 |
</path>
|
|
201 |
<globmapper from="*.java" to="*.class"/>
|
|
202 |
</pathconvert>
|
|
203 |
<delete>
|
|
204 |
<files includes="${javac.includes.binary}"/>
|
|
205 |
</delete>
|
|
206 |
</sequential>
|
|
207 |
</macrodef>
|
|
208 |
</target>
|
|
209 |
<target name="-init-macrodef-scalac">
|
|
210 |
<macrodef name="scalac" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
211 |
<attribute default="${src.dir}" name="srcdir"/>
|
|
212 |
<attribute default="${build.classes.dir}" name="destdir"/>
|
|
213 |
<attribute default="${javac.classpath}" name="classpath"/>
|
|
214 |
<attribute default="${includes}" name="includes"/>
|
|
215 |
<attribute default="${excludes}" name="excludes"/>
|
|
216 |
<attribute default="jvm-${javac.debug}" name="debug"/>
|
|
217 |
<attribute default="" name="sourcepath"/>
|
|
218 |
<element name="customize" optional="true"/>
|
|
219 |
<sequential>
|
|
220 |
<scalac destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" includes="@{includes}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="jvm-${javac.target}">
|
|
221 |
<classpath>
|
|
222 |
<path path="@{classpath}"/>
|
|
223 |
<pathelement location="${scala.library}"/>
|
|
224 |
</classpath>
|
|
225 |
<customize/>
|
|
226 |
</scalac>
|
|
227 |
</sequential>
|
|
228 |
</macrodef>
|
|
229 |
<macrodef name="depend" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
230 |
<attribute default="${src.dir}" name="srcdir"/>
|
|
231 |
<attribute default="${build.classes.dir}" name="destdir"/>
|
|
232 |
<attribute default="${javac.classpath}" name="classpath"/>
|
|
233 |
<sequential>
|
|
234 |
<depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}">
|
|
235 |
<classpath>
|
|
236 |
<path path="@{classpath}"/>
|
|
237 |
</classpath>
|
|
238 |
</depend>
|
|
239 |
</sequential>
|
|
240 |
</macrodef>
|
|
241 |
<macrodef name="force-recompile" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
242 |
<attribute default="${build.classes.dir}" name="destdir"/>
|
|
243 |
<sequential>
|
|
244 |
<fail unless="javac.includes">Must set javac.includes</fail>
|
|
245 |
<pathconvert pathsep="," property="javac.includes.binary">
|
|
246 |
<path>
|
|
247 |
<filelist dir="@{destdir}" files="${javac.includes}"/>
|
|
248 |
</path>
|
|
249 |
<globmapper from="*.scala" to="*.class"/>
|
|
250 |
</pathconvert>
|
|
251 |
<delete>
|
|
252 |
<files includes="${javac.includes.binary}"/>
|
|
253 |
</delete>
|
|
254 |
</sequential>
|
|
255 |
</macrodef>
|
|
256 |
</target>
|
|
257 |
<target name="-init-macrodef-junit">
|
|
258 |
<macrodef name="junit" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
259 |
<attribute default="${includes}" name="includes"/>
|
|
260 |
<attribute default="${excludes}" name="excludes"/>
|
|
261 |
<attribute default="**" name="testincludes"/>
|
|
262 |
<sequential>
|
|
263 |
<junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true">
|
|
264 |
<batchtest todir="${build.test.results.dir}">
|
|
265 |
<fileset dir="${build.test.classes.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
|
|
266 |
<filename name="@{testincludes}"/>
|
|
267 |
</fileset>
|
|
268 |
</batchtest>
|
|
269 |
<classpath>
|
|
270 |
<path path="${run.test.classpath}"/>
|
|
271 |
<pathelement location="${scala.library}"/>
|
|
272 |
</classpath>
|
|
273 |
<syspropertyset>
|
|
274 |
<propertyref prefix="test-sys-prop."/>
|
|
275 |
<mapper from="test-sys-prop.*" to="*" type="glob"/>
|
|
276 |
</syspropertyset>
|
|
277 |
<formatter type="brief" usefile="false"/>
|
|
278 |
<formatter type="xml"/>
|
|
279 |
<jvmarg line="${run.jvmargs}"/>
|
|
280 |
</junit>
|
|
281 |
</sequential>
|
|
282 |
</macrodef>
|
|
283 |
</target>
|
|
284 |
<target name="-init-macrodef-nbjpda">
|
|
285 |
<macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
286 |
<attribute default="${main.class}" name="name"/>
|
|
287 |
<attribute default="${debug.classpath}" name="classpath"/>
|
|
288 |
<attribute default="" name="stopclassname"/>
|
|
289 |
<sequential>
|
|
290 |
<nbjpdastart addressproperty="jpda.address" name="@{name}" stopclassname="@{stopclassname}" transport="dt_socket">
|
|
291 |
<classpath>
|
|
292 |
<path path="@{classpath}"/>
|
|
293 |
</classpath>
|
|
294 |
</nbjpdastart>
|
|
295 |
</sequential>
|
|
296 |
</macrodef>
|
|
297 |
<macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
298 |
<attribute default="${build.classes.dir}" name="dir"/>
|
|
299 |
<sequential>
|
|
300 |
<nbjpdareload>
|
|
301 |
<fileset dir="@{dir}" includes="${fix.includes}*.class"/>
|
|
302 |
</nbjpdareload>
|
|
303 |
</sequential>
|
|
304 |
</macrodef>
|
|
305 |
</target>
|
|
306 |
<target name="-init-debug-args">
|
|
307 |
<property name="version-output" value="java version "${ant.java.version}"/>
|
|
308 |
<condition property="have-jdk-older-than-1.4">
|
|
309 |
<or>
|
|
310 |
<contains string="${version-output}" substring="java version "1.0"/>
|
|
311 |
<contains string="${version-output}" substring="java version "1.1"/>
|
|
312 |
<contains string="${version-output}" substring="java version "1.2"/>
|
|
313 |
<contains string="${version-output}" substring="java version "1.3"/>
|
|
314 |
</or>
|
|
315 |
</condition>
|
|
316 |
<condition else="-Xdebug" property="debug-args-line" value="-Xdebug -Xnoagent -Djava.compiler=none">
|
|
317 |
<istrue value="${have-jdk-older-than-1.4}"/>
|
|
318 |
</condition>
|
|
319 |
</target>
|
|
320 |
<target depends="-init-debug-args" name="-init-macrodef-debug">
|
|
321 |
<macrodef name="debug" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
322 |
<attribute default="${main.class}" name="classname"/>
|
|
323 |
<attribute default="${debug.classpath}" name="classpath"/>
|
|
324 |
<element name="customize" optional="true"/>
|
|
325 |
<sequential>
|
|
326 |
<java classname="@{classname}" dir="${work.dir}" fork="true">
|
|
327 |
<jvmarg line="${debug-args-line}"/>
|
|
328 |
<jvmarg value="-Xrunjdwp:transport=dt_socket,address=${jpda.address}"/>
|
|
329 |
<jvmarg line="${run.jvmargs}"/>
|
|
330 |
<classpath>
|
|
331 |
<path path="@{classpath}"/>
|
|
332 |
<pathelement location="${scala.library}"/>
|
|
333 |
</classpath>
|
|
334 |
<syspropertyset>
|
|
335 |
<propertyref prefix="run-sys-prop."/>
|
|
336 |
<mapper from="run-sys-prop.*" to="*" type="glob"/>
|
|
337 |
</syspropertyset>
|
|
338 |
<customize/>
|
|
339 |
</java>
|
|
340 |
</sequential>
|
|
341 |
</macrodef>
|
|
342 |
</target>
|
|
343 |
<target name="-init-macrodef-java">
|
|
344 |
<macrodef name="java" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
345 |
<attribute default="${main.class}" name="classname"/>
|
|
346 |
<element name="customize" optional="true"/>
|
|
347 |
<sequential>
|
|
348 |
<java classname="@{classname}" dir="${work.dir}" fork="true">
|
|
349 |
<jvmarg line="${run.jvmargs}"/>
|
|
350 |
<classpath>
|
|
351 |
<path path="${run.classpath}"/>
|
|
352 |
<pathelement location="${scala.library}"/>
|
|
353 |
</classpath>
|
|
354 |
<syspropertyset>
|
|
355 |
<propertyref prefix="run-sys-prop."/>
|
|
356 |
<mapper from="run-sys-prop.*" to="*" type="glob"/>
|
|
357 |
</syspropertyset>
|
|
358 |
<customize/>
|
|
359 |
</java>
|
|
360 |
</sequential>
|
|
361 |
</macrodef>
|
|
362 |
</target>
|
|
363 |
<target name="-init-presetdef-jar">
|
|
364 |
<presetdef name="jar" uri="http://www.netbeans.org/ns/scala-project/1">
|
|
365 |
<jar compress="${jar.compress}" jarfile="${dist.jar}">
|
|
366 |
<scalaProject1:fileset dir="${build.classes.dir}"/>
|
|
367 |
</jar>
|
|
368 |
</presetdef>
|
|
369 |
</target>
|
|
370 |
<target depends="-pre-init,-init-private,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-scalac,-init-macrodef-junit,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar" name="init"/>
|
|
371 |
<!--
|
|
372 |
===================
|
|
373 |
COMPILATION SECTION
|
|
374 |
===================
|
|
375 |
-->
|
|
376 |
<target depends="init" name="deps-jar" unless="no.deps"/>
|
|
377 |
<target depends="init,deps-jar" name="-pre-pre-compile">
|
|
378 |
<mkdir dir="${build.classes.dir}"/>
|
|
379 |
</target>
|
|
380 |
<target name="-pre-compile">
|
|
381 |
<!-- Empty placeholder for easier customization. -->
|
|
382 |
<!-- You can override this target in the ../build.xml file. -->
|
|
383 |
</target>
|
|
384 |
<target if="do.depend.true" name="-compile-depend">
|
|
385 |
<scalaProject1:depend/>
|
|
386 |
</target>
|
|
387 |
<target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-compile-depend" if="have.sources" name="-do-compile">
|
|
388 |
<scalaProject1:scalac/>
|
|
389 |
<copy todir="${build.classes.dir}">
|
|
390 |
<fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
|
|
391 |
</copy>
|
|
392 |
</target>
|
|
393 |
<target name="-post-compile">
|
|
394 |
<!-- Empty placeholder for easier customization. -->
|
|
395 |
<!-- You can override this target in the ../build.xml file. -->
|
|
396 |
</target>
|
|
397 |
<target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/>
|
|
398 |
<target name="-pre-compile-single">
|
|
399 |
<!-- Empty placeholder for easier customization. -->
|
|
400 |
<!-- You can override this target in the ../build.xml file. -->
|
|
401 |
</target>
|
|
402 |
<target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">
|
|
403 |
<fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
|
|
404 |
<scalaProject1:force-recompile/>
|
|
405 |
<scalaProject1:scalac excludes="" includes="${javac.includes}" sourcepath="${src.dir}"/>
|
|
406 |
</target>
|
|
407 |
<target name="-post-compile-single">
|
|
408 |
<!-- Empty placeholder for easier customization. -->
|
|
409 |
<!-- You can override this target in the ../build.xml file. -->
|
|
410 |
</target>
|
|
411 |
<target depends="init,deps-jar,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/>
|
|
412 |
<!--
|
|
413 |
====================
|
|
414 |
JAR BUILDING SECTION
|
|
415 |
====================
|
|
416 |
-->
|
|
417 |
<target depends="init" name="-pre-pre-jar">
|
|
418 |
<dirname file="${dist.jar}" property="dist.jar.dir"/>
|
|
419 |
<mkdir dir="${dist.jar.dir}"/>
|
|
420 |
</target>
|
|
421 |
<target name="-pre-jar">
|
|
422 |
<!-- Empty placeholder for easier customization. -->
|
|
423 |
<!-- You can override this target in the ../build.xml file. -->
|
|
424 |
</target>
|
|
425 |
<target depends="init,compile,-pre-pre-jar,-pre-jar" name="-do-jar-without-manifest" unless="manifest.available">
|
|
426 |
<scalaProject1:jar/>
|
|
427 |
</target>
|
|
428 |
<target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available" name="-do-jar-with-manifest" unless="manifest.available+main.class">
|
|
429 |
<scalaProject1:jar manifest="${manifest.file}"/>
|
|
430 |
</target>
|
|
431 |
<target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class" name="-do-jar-with-mainclass" unless="manifest.available+main.class+mkdist.available">
|
|
432 |
<scalaProject1:jar manifest="${manifest.file}">
|
|
433 |
<scalaProject1:manifest>
|
|
434 |
<scalaProject1:attribute name="Main-Class" value="${main.class}"/>
|
|
435 |
</scalaProject1:manifest>
|
|
436 |
</scalaProject1:jar>
|
|
437 |
<echo>To run this application from the command line without Ant, try:</echo>
|
|
438 |
<property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
|
|
439 |
<property location="${dist.jar}" name="dist.jar.resolved"/>
|
|
440 |
<pathconvert property="run.classpath.with.dist.jar">
|
|
441 |
<path path="${run.classpath}"/>
|
|
442 |
<map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>
|
|
443 |
</pathconvert>
|
|
444 |
<echo>java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
|
|
445 |
</target>
|
|
446 |
<target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class+mkdist.available" name="-do-jar-with-libraries">
|
|
447 |
<property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
|
|
448 |
<pathconvert property="run.classpath.without.build.classes.dir">
|
|
449 |
<path path="${run.classpath}"/>
|
|
450 |
<map from="${build.classes.dir.resolved}" to=""/>
|
|
451 |
</pathconvert>
|
|
452 |
<pathconvert pathsep=" " property="jar.classpath">
|
|
453 |
<path path="${run.classpath.without.build.classes.dir}"/>
|
|
454 |
<chainedmapper>
|
|
455 |
<flattenmapper/>
|
|
456 |
<globmapper from="*" to="lib/*"/>
|
|
457 |
</chainedmapper>
|
|
458 |
</pathconvert>
|
|
459 |
<taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>
|
|
460 |
<copylibs compress="${jar.compress}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}">
|
|
461 |
<fileset dir="${build.classes.dir}"/>
|
|
462 |
<manifest>
|
|
463 |
<attribute name="Main-Class" value="${main.class}"/>
|
|
464 |
<attribute name="Class-Path" value="${jar.classpath}"/>
|
|
465 |
</manifest>
|
|
466 |
</copylibs>
|
|
467 |
<echo>To run this application from the command line without Ant, try:</echo>
|
|
468 |
<property location="${dist.jar}" name="dist.jar.resolved"/>
|
|
469 |
<echo>java -jar "${dist.jar.resolved}"</echo>
|
|
470 |
</target>
|
|
471 |
<target name="-post-jar">
|
|
472 |
<!-- Empty placeholder for easier customization. -->
|
|
473 |
<!-- You can override this target in the ../build.xml file. -->
|
|
474 |
</target>
|
|
475 |
<target depends="init,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-post-jar" description="Build JAR." name="jar"/>
|
|
476 |
<!--
|
|
477 |
=================
|
|
478 |
EXECUTION SECTION
|
|
479 |
=================
|
|
480 |
-->
|
|
481 |
<target depends="init,compile" description="Run a main class." name="run">
|
|
482 |
<scalaProject1:java>
|
|
483 |
<customize>
|
|
484 |
<arg line="${application.args}"/>
|
|
485 |
</customize>
|
|
486 |
</scalaProject1:java>
|
|
487 |
</target>
|
|
488 |
<target name="-do-not-recompile">
|
|
489 |
<property name="javac.includes.binary" value=""/>
|
|
490 |
</target>
|
|
491 |
<target depends="init,-do-not-recompile,compile-single" name="run-single">
|
|
492 |
<fail unless="run.class">Must select one file in the IDE or set run.class</fail>
|
|
493 |
<scalaProject1:java classname="${run.class}"/>
|
|
494 |
</target>
|
|
495 |
<!--
|
|
496 |
=================
|
|
497 |
DEBUGGING SECTION
|
|
498 |
=================
|
|
499 |
-->
|
|
500 |
<target depends="init" if="netbeans.home" name="-debug-start-debugger">
|
|
501 |
<scalaProject1:nbjpdastart name="${debug.class}"/>
|
|
502 |
</target>
|
|
503 |
<target depends="init,compile" name="-debug-start-debuggee">
|
|
504 |
<scalaProject1:debug>
|
|
505 |
<customize>
|
|
506 |
<arg line="${application.args}"/>
|
|
507 |
</customize>
|
|
508 |
</scalaProject1:debug>
|
|
509 |
</target>
|
|
510 |
<target depends="init,compile,-debug-start-debugger,-debug-start-debuggee" description="Debug project in IDE." if="netbeans.home" name="debug"/>
|
|
511 |
<target depends="init" if="netbeans.home" name="-debug-start-debugger-stepinto">
|
|
512 |
<scalaProject1:nbjpdastart stopclassname="${main.class}"/>
|
|
513 |
</target>
|
|
514 |
<target depends="init,compile,-debug-start-debugger-stepinto,-debug-start-debuggee" if="netbeans.home" name="debug-stepinto"/>
|
|
515 |
<target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single">
|
|
516 |
<fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
|
|
517 |
<scalaProject1:debug classname="${debug.class}"/>
|
|
518 |
</target>
|
|
519 |
<target depends="init,-do-not-recompile,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single"/>
|
|
520 |
<target depends="init" name="-pre-debug-fix">
|
|
521 |
<fail unless="fix.includes">Must set fix.includes</fail>
|
|
522 |
<property name="javac.includes" value="${fix.includes}.java"/>
|
|
523 |
</target>
|
|
524 |
<target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix">
|
|
525 |
<scalaProject1:nbjpdareload/>
|
|
526 |
</target>
|
|
527 |
<target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/>
|
|
528 |
<!--
|
|
529 |
===============
|
|
530 |
JAVADOC SECTION
|
|
531 |
===============
|
|
532 |
-->
|
|
533 |
<target depends="init" name="-javadoc-build">
|
|
534 |
<mkdir dir="${dist.javadoc.dir}"/>
|
|
535 |
<javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
|
|
536 |
<classpath>
|
|
537 |
<path path="${javac.classpath}"/>
|
|
538 |
</classpath>
|
|
539 |
<fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">
|
|
540 |
<filename name="**/*.java"/>
|
|
541 |
</fileset>
|
|
542 |
</javadoc>
|
|
543 |
</target>
|
|
544 |
<target depends="init,-javadoc-build" if="netbeans.home" name="-javadoc-browse" unless="no.javadoc.preview">
|
|
545 |
<nbbrowse file="${dist.javadoc.dir}/index.html"/>
|
|
546 |
</target>
|
|
547 |
<target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/>
|
|
548 |
<!--
|
|
549 |
=========================
|
|
550 |
JUNIT COMPILATION SECTION
|
|
551 |
=========================
|
|
552 |
-->
|
|
553 |
<target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">
|
|
554 |
<mkdir dir="${build.test.classes.dir}"/>
|
|
555 |
</target>
|
|
556 |
<target name="-pre-compile-test">
|
|
557 |
<!-- Empty placeholder for easier customization. -->
|
|
558 |
<!-- You can override this target in the ../build.xml file. -->
|
|
559 |
</target>
|
|
560 |
<target if="do.depend.true" name="-compile-test-depend">
|
|
561 |
<scalaProject1:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir=""/>
|
|
562 |
</target>
|
|
563 |
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test">
|
|
564 |
<scalaProject1:scalac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir=""/>
|
|
565 |
<copy todir="${build.test.classes.dir}"/>
|
|
566 |
</target>
|
|
567 |
<target name="-post-compile-test">
|
|
568 |
<!-- Empty placeholder for easier customization. -->
|
|
569 |
<!-- You can override this target in the ../build.xml file. -->
|
|
570 |
</target>
|
|
571 |
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/>
|
|
572 |
<target name="-pre-compile-test-single">
|
|
573 |
<!-- Empty placeholder for easier customization. -->
|
|
574 |
<!-- You can override this target in the ../build.xml file. -->
|
|
575 |
</target>
|
|
576 |
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single">
|
|
577 |
<fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
|
|
578 |
<scalaProject1:force-recompile destdir="${build.test.classes.dir}"/>
|
|
579 |
<scalaProject1:scalac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" sourcepath="" srcdir=""/>
|
|
580 |
<copy todir="${build.test.classes.dir}"/>
|
|
581 |
</target>
|
|
582 |
<target name="-post-compile-test-single">
|
|
583 |
<!-- Empty placeholder for easier customization. -->
|
|
584 |
<!-- You can override this target in the ../build.xml file. -->
|
|
585 |
</target>
|
|
586 |
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/>
|
|
587 |
<!--
|
|
588 |
=======================
|
|
589 |
JUNIT EXECUTION SECTION
|
|
590 |
=======================
|
|
591 |
-->
|
|
592 |
<target depends="init" if="have.tests" name="-pre-test-run">
|
|
593 |
<mkdir dir="${build.test.results.dir}"/>
|
|
594 |
</target>
|
|
595 |
<target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">
|
|
596 |
<scalaProject1:junit testincludes="**/*Test.class"/>
|
|
597 |
</target>
|
|
598 |
<target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">
|
|
599 |
<fail if="tests.failed">Some tests failed; see details above.</fail>
|
|
600 |
</target>
|
|
601 |
<target depends="init" if="have.tests" name="test-report"/>
|
|
602 |
<target depends="init" if="netbeans.home+have.tests" name="-test-browse"/>
|
|
603 |
<target depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests." name="test"/>
|
|
604 |
<target depends="init" if="have.tests" name="-pre-test-run-single">
|
|
605 |
<mkdir dir="${build.test.results.dir}"/>
|
|
606 |
</target>
|
|
607 |
<target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">
|
|
608 |
<fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
|
|
609 |
<scalaProject1:junit excludes="" includes="${test.includes}"/>
|
|
610 |
</target>
|
|
611 |
<target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">
|
|
612 |
<fail if="tests.failed">Some tests failed; see details above.</fail>
|
|
613 |
</target>
|
|
614 |
<target depends="init,-do-not-recompile,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/>
|
|
615 |
<!--
|
|
616 |
=======================
|
|
617 |
JUNIT DEBUGGING SECTION
|
|
618 |
=======================
|
|
619 |
-->
|
|
620 |
<target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test">
|
|
621 |
<fail unless="test.class">Must select one file in the IDE or set test.class</fail>
|
|
622 |
<property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/>
|
|
623 |
<delete file="${test.report.file}"/>
|
|
624 |
<mkdir dir="${build.test.results.dir}"/>
|
|
625 |
<scalaProject1:debug classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner" classpath="${ant.home}/lib/ant.jar:${ant.home}/lib/ant-junit.jar:${debug.test.classpath}">
|
|
626 |
<customize>
|
|
627 |
<syspropertyset>
|
|
628 |
<propertyref prefix="test-sys-prop."/>
|
|
629 |
<mapper from="test-sys-prop.*" to="*" type="glob"/>
|
|
630 |
</syspropertyset>
|
|
631 |
<arg value="${test.class}"/>
|
|
632 |
<arg value="showoutput=true"/>
|
|
633 |
<arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/>
|
|
634 |
<arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/>
|
|
635 |
</customize>
|
|
636 |
</scalaProject1:debug>
|
|
637 |
</target>
|
|
638 |
<target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">
|
|
639 |
<scalaProject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>
|
|
640 |
</target>
|
|
641 |
<target depends="init,-do-not-recompile,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>
|
|
642 |
<target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">
|
|
643 |
<scalaProject1:nbjpdareload dir="${build.test.classes.dir}"/>
|
|
644 |
</target>
|
|
645 |
<target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/>
|
|
646 |
<!--
|
|
647 |
=========================
|
|
648 |
APPLET EXECUTION SECTION
|
|
649 |
=========================
|
|
650 |
-->
|
|
651 |
<target depends="init,compile-single" name="run-applet">
|
|
652 |
<fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
|
|
653 |
<scalaProject1:java classname="sun.applet.AppletViewer">
|
|
654 |
<customize>
|
|
655 |
<arg value="${applet.url}"/>
|
|
656 |
</customize>
|
|
657 |
</scalaProject1:java>
|
|
658 |
</target>
|
|
659 |
<!--
|
|
660 |
=========================
|
|
661 |
APPLET DEBUGGING SECTION
|
|
662 |
=========================
|
|
663 |
-->
|
|
664 |
<target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-applet">
|
|
665 |
<fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
|
|
666 |
<scalaProject1:debug classname="sun.applet.AppletViewer">
|
|
667 |
<customize>
|
|
668 |
<arg value="${applet.url}"/>
|
|
669 |
</customize>
|
|
670 |
</scalaProject1:debug>
|
|
671 |
</target>
|
|
672 |
<target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-applet" if="netbeans.home" name="debug-applet"/>
|
|
673 |
<!--
|
|
674 |
===============
|
|
675 |
CLEANUP SECTION
|
|
676 |
===============
|
|
677 |
-->
|
|
678 |
<target depends="init" name="deps-clean" unless="no.deps"/>
|
|
679 |
<target depends="init" name="-do-clean">
|
|
680 |
<delete dir="${build.dir}"/>
|
|
681 |
<delete dir="${dist.dir}"/>
|
|
682 |
</target>
|
|
683 |
<target name="-post-clean">
|
|
684 |
<!-- Empty placeholder for easier customization. -->
|
|
685 |
<!-- You can override this target in the ../build.xml file. -->
|
|
686 |
</target>
|
|
687 |
<target depends="init,deps-clean,-do-clean,-post-clean" description="Clean build products." name="clean"/>
|
|
688 |
</project>
|