]> git.mxchange.org Git - jcore.git/blob - nbproject/build-impl.xml
Added files for NetBeans and only ignored 'private'.
[jcore.git] / nbproject / build-impl.xml
1 <?xml version="1.0" encoding="UTF-8"?>\r
2 <!--\r
3 *** GENERATED FROM project.xml - DO NOT EDIT  ***\r
4 ***         EDIT ../build.xml INSTEAD         ***\r
5 \r
6 For the purpose of easier reading the script\r
7 is divided into following sections:\r
8 \r
9   - initialization\r
10   - compilation\r
11   - jar\r
12   - execution\r
13   - debugging\r
14   - javadoc\r
15   - test compilation\r
16   - test execution\r
17   - test debugging\r
18   - applet\r
19   - cleanup\r
20 \r
21         -->\r
22 <project xmlns:j2seproject1="http://www.netbeans.org/ns/j2se-project/1" xmlns:j2seproject3="http://www.netbeans.org/ns/j2se-project/3" xmlns:jaxrpc="http://www.netbeans.org/ns/j2se-project/jax-rpc" basedir=".." default="default" name="jcore-impl">\r
23     <fail message="Please build using Ant 1.8.0 or higher.">\r
24         <condition>\r
25             <not>\r
26                 <antversion atleast="1.8.0"/>\r
27             </not>\r
28         </condition>\r
29     </fail>\r
30     <target depends="test,jar,javadoc" description="Build and test whole project." name="default"/>\r
31     <!-- \r
32                 ======================\r
33                 INITIALIZATION SECTION \r
34                 ======================\r
35             -->\r
36     <target name="-pre-init">\r
37         <!-- Empty placeholder for easier customization. -->\r
38         <!-- You can override this target in the ../build.xml file. -->\r
39     </target>\r
40     <target depends="-pre-init" name="-init-private">\r
41         <property file="nbproject/private/config.properties"/>\r
42         <property file="nbproject/private/configs/${config}.properties"/>\r
43         <property file="nbproject/private/private.properties"/>\r
44     </target>\r
45     <target name="-pre-init-libraries">\r
46         <property location=".\lib\nblibraries.properties" name="libraries.path"/>\r
47         <dirname file="${libraries.path}" property="libraries.dir.nativedirsep"/>\r
48         <pathconvert dirsep="/" property="libraries.dir">\r
49             <path path="${libraries.dir.nativedirsep}"/>\r
50         </pathconvert>\r
51         <basename file="${libraries.path}" property="libraries.basename" suffix=".properties"/>\r
52         <available file="${libraries.dir}/${libraries.basename}-private.properties" property="private.properties.available"/>\r
53     </target>\r
54     <target depends="-pre-init-libraries" if="private.properties.available" name="-init-private-libraries">\r
55         <loadproperties encoding="ISO-8859-1" srcfile="${libraries.dir}/${libraries.basename}-private.properties">\r
56             <filterchain>\r
57                 <replacestring from="$${base}" to="${libraries.dir}"/>\r
58                 <escapeunicode/>\r
59             </filterchain>\r
60         </loadproperties>\r
61     </target>\r
62     <target depends="-pre-init,-init-private,-init-private-libraries" name="-init-libraries">\r
63         <loadproperties encoding="ISO-8859-1" srcfile="${libraries.path}">\r
64             <filterchain>\r
65                 <replacestring from="$${base}" to="${libraries.dir}"/>\r
66                 <escapeunicode/>\r
67             </filterchain>\r
68         </loadproperties>\r
69     </target>\r
70     <target depends="-pre-init,-init-private,-init-libraries" name="-init-user">\r
71         <property file="${user.properties.file}"/>\r
72         <!-- The two properties below are usually overridden -->\r
73         <!-- by the active platform. Just a fallback. -->\r
74         <property name="default.javac.source" value="1.4"/>\r
75         <property name="default.javac.target" value="1.4"/>\r
76     </target>\r
77     <target depends="-pre-init,-init-private,-init-libraries,-init-user" name="-init-project">\r
78         <property file="nbproject/configs/${config}.properties"/>\r
79         <property file="nbproject/project.properties"/>\r
80     </target>\r
81     <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-init-macrodef-property" name="-do-init">\r
82         <property name="platform.java" value="${java.home}/bin/java"/>\r
83         <available file="${manifest.file}" property="manifest.available"/>\r
84         <condition property="splashscreen.available">\r
85             <and>\r
86                 <not>\r
87                     <equals arg1="${application.splash}" arg2="" trim="true"/>\r
88                 </not>\r
89                 <available file="${application.splash}"/>\r
90             </and>\r
91         </condition>\r
92         <condition property="main.class.available">\r
93             <and>\r
94                 <isset property="main.class"/>\r
95                 <not>\r
96                     <equals arg1="${main.class}" arg2="" trim="true"/>\r
97                 </not>\r
98             </and>\r
99         </condition>\r
100         <condition property="profile.available">\r
101             <and>\r
102                 <isset property="javac.profile"/>\r
103                 <length length="0" string="${javac.profile}" when="greater"/>\r
104                 <matches pattern="1\.[89](\..*)?" string="${javac.source}"/>\r
105             </and>\r
106         </condition>\r
107         <condition property="do.archive">\r
108             <or>\r
109                 <not>\r
110                     <istrue value="${jar.archive.disabled}"/>\r
111                 </not>\r
112                 <istrue value="${not.archive.disabled}"/>\r
113             </or>\r
114         </condition>\r
115         <condition property="do.mkdist">\r
116             <and>\r
117                 <isset property="do.archive"/>\r
118                 <isset property="libs.CopyLibs.classpath"/>\r
119                 <not>\r
120                     <istrue value="${mkdist.disabled}"/>\r
121                 </not>\r
122             </and>\r
123         </condition>\r
124         <condition property="do.archive+manifest.available">\r
125             <and>\r
126                 <isset property="manifest.available"/>\r
127                 <istrue value="${do.archive}"/>\r
128             </and>\r
129         </condition>\r
130         <condition property="do.archive+main.class.available">\r
131             <and>\r
132                 <isset property="main.class.available"/>\r
133                 <istrue value="${do.archive}"/>\r
134             </and>\r
135         </condition>\r
136         <condition property="do.archive+splashscreen.available">\r
137             <and>\r
138                 <isset property="splashscreen.available"/>\r
139                 <istrue value="${do.archive}"/>\r
140             </and>\r
141         </condition>\r
142         <condition property="do.archive+profile.available">\r
143             <and>\r
144                 <isset property="profile.available"/>\r
145                 <istrue value="${do.archive}"/>\r
146             </and>\r
147         </condition>\r
148         <condition property="have.tests">\r
149             <or>\r
150                 <available file="${test.src.dir}"/>\r
151             </or>\r
152         </condition>\r
153         <condition property="have.sources">\r
154             <or>\r
155                 <available file="${src.dir}"/>\r
156             </or>\r
157         </condition>\r
158         <condition property="netbeans.home+have.tests">\r
159             <and>\r
160                 <isset property="netbeans.home"/>\r
161                 <isset property="have.tests"/>\r
162             </and>\r
163         </condition>\r
164         <condition property="no.javadoc.preview">\r
165             <and>\r
166                 <isset property="javadoc.preview"/>\r
167                 <isfalse value="${javadoc.preview}"/>\r
168             </and>\r
169         </condition>\r
170         <property name="run.jvmargs" value=""/>\r
171         <property name="run.jvmargs.ide" value=""/>\r
172         <property name="javac.compilerargs" value=""/>\r
173         <property name="work.dir" value="${basedir}"/>\r
174         <condition property="no.deps">\r
175             <and>\r
176                 <istrue value="${no.dependencies}"/>\r
177             </and>\r
178         </condition>\r
179         <property name="javac.debug" value="true"/>\r
180         <property name="javadoc.preview" value="true"/>\r
181         <property name="application.args" value=""/>\r
182         <property name="source.encoding" value="${file.encoding}"/>\r
183         <property name="runtime.encoding" value="${source.encoding}"/>\r
184         <condition property="javadoc.encoding.used" value="${javadoc.encoding}">\r
185             <and>\r
186                 <isset property="javadoc.encoding"/>\r
187                 <not>\r
188                     <equals arg1="${javadoc.encoding}" arg2=""/>\r
189                 </not>\r
190             </and>\r
191         </condition>\r
192         <property name="javadoc.encoding.used" value="${source.encoding}"/>\r
193         <property name="includes" value="**"/>\r
194         <property name="excludes" value=""/>\r
195         <property name="do.depend" value="false"/>\r
196         <condition property="do.depend.true">\r
197             <istrue value="${do.depend}"/>\r
198         </condition>\r
199         <path id="endorsed.classpath.path" path="${endorsed.classpath}"/>\r
200         <condition else="" property="endorsed.classpath.cmd.line.arg" value="-Xbootclasspath/p:'${toString:endorsed.classpath.path}'">\r
201             <and>\r
202                 <isset property="endorsed.classpath"/>\r
203                 <not>\r
204                     <equals arg1="${endorsed.classpath}" arg2="" trim="true"/>\r
205                 </not>\r
206             </and>\r
207         </condition>\r
208         <condition else="" property="javac.profile.cmd.line.arg" value="-profile ${javac.profile}">\r
209             <isset property="profile.available"/>\r
210         </condition>\r
211         <condition else="false" property="jdkBug6558476">\r
212             <and>\r
213                 <matches pattern="1\.[56]" string="${java.specification.version}"/>\r
214                 <not>\r
215                     <os family="unix"/>\r
216                 </not>\r
217             </and>\r
218         </condition>\r
219         <property name="javac.fork" value="${jdkBug6558476}"/>\r
220         <property name="jar.index" value="false"/>\r
221         <property name="jar.index.metainf" value="${jar.index}"/>\r
222         <property name="copylibs.rebase" value="true"/>\r
223         <available file="${meta.inf.dir}/persistence.xml" property="has.persistence.xml"/>\r
224         <condition property="junit.available">\r
225             <or>\r
226                 <available classname="org.junit.Test" classpath="${run.test.classpath}"/>\r
227                 <available classname="junit.framework.Test" classpath="${run.test.classpath}"/>\r
228             </or>\r
229         </condition>\r
230         <condition property="testng.available">\r
231             <available classname="org.testng.annotations.Test" classpath="${run.test.classpath}"/>\r
232         </condition>\r
233         <condition property="junit+testng.available">\r
234             <and>\r
235                 <istrue value="${junit.available}"/>\r
236                 <istrue value="${testng.available}"/>\r
237             </and>\r
238         </condition>\r
239         <condition else="testng" property="testng.mode" value="mixed">\r
240             <istrue value="${junit+testng.available}"/>\r
241         </condition>\r
242         <condition else="" property="testng.debug.mode" value="-mixed">\r
243             <istrue value="${junit+testng.available}"/>\r
244         </condition>\r
245     </target>\r
246     <target name="-post-init">\r
247         <!-- Empty placeholder for easier customization. -->\r
248         <!-- You can override this target in the ../build.xml file. -->\r
249     </target>\r
250     <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-do-init" name="-init-check">\r
251         <fail unless="src.dir">Must set src.dir</fail>\r
252         <fail unless="test.src.dir">Must set test.src.dir</fail>\r
253         <fail unless="build.dir">Must set build.dir</fail>\r
254         <fail unless="dist.dir">Must set dist.dir</fail>\r
255         <fail unless="build.classes.dir">Must set build.classes.dir</fail>\r
256         <fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail>\r
257         <fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail>\r
258         <fail unless="build.test.results.dir">Must set build.test.results.dir</fail>\r
259         <fail unless="build.classes.excludes">Must set build.classes.excludes</fail>\r
260         <fail unless="dist.jar">Must set dist.jar</fail>\r
261     </target>\r
262     <target name="-init-macrodef-property">\r
263         <macrodef name="property" uri="http://www.netbeans.org/ns/j2se-project/1">\r
264             <attribute name="name"/>\r
265             <attribute name="value"/>\r
266             <sequential>\r
267                 <property name="@{name}" value="${@{value}}"/>\r
268             </sequential>\r
269         </macrodef>\r
270     </target>\r
271     <target depends="-init-ap-cmdline-properties" if="ap.supported.internal" name="-init-macrodef-javac-with-processors">\r
272         <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">\r
273             <attribute default="${src.dir}" name="srcdir"/>\r
274             <attribute default="${build.classes.dir}" name="destdir"/>\r
275             <attribute default="${javac.classpath}" name="classpath"/>\r
276             <attribute default="${javac.processorpath}" name="processorpath"/>\r
277             <attribute default="${build.generated.sources.dir}/ap-source-output" name="apgeneratedsrcdir"/>\r
278             <attribute default="${includes}" name="includes"/>\r
279             <attribute default="${excludes}" name="excludes"/>\r
280             <attribute default="${javac.debug}" name="debug"/>\r
281             <attribute default="${empty.dir}" name="sourcepath"/>\r
282             <attribute default="${empty.dir}" name="gensrcdir"/>\r
283             <element name="customize" optional="true"/>\r
284             <sequential>\r
285                 <property location="${build.dir}/empty" name="empty.dir"/>\r
286                 <mkdir dir="${empty.dir}"/>\r
287                 <mkdir dir="@{apgeneratedsrcdir}"/>\r
288                 <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">\r
289                     <src>\r
290                         <dirset dir="@{gensrcdir}" erroronmissingdir="false">\r
291                             <include name="*"/>\r
292                         </dirset>\r
293                     </src>\r
294                     <classpath>\r
295                         <path path="@{classpath}"/>\r
296                     </classpath>\r
297                     <compilerarg line="${endorsed.classpath.cmd.line.arg}"/>\r
298                     <compilerarg line="${javac.profile.cmd.line.arg}"/>\r
299                     <compilerarg line="${javac.compilerargs}"/>\r
300                     <compilerarg value="-processorpath"/>\r
301                     <compilerarg path="@{processorpath}:${empty.dir}"/>\r
302                     <compilerarg line="${ap.processors.internal}"/>\r
303                     <compilerarg line="${annotation.processing.processor.options}"/>\r
304                     <compilerarg value="-s"/>\r
305                     <compilerarg path="@{apgeneratedsrcdir}"/>\r
306                     <compilerarg line="${ap.proc.none.internal}"/>\r
307                     <customize/>\r
308                 </javac>\r
309             </sequential>\r
310         </macrodef>\r
311     </target>\r
312     <target depends="-init-ap-cmdline-properties" name="-init-macrodef-javac-without-processors" unless="ap.supported.internal">\r
313         <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">\r
314             <attribute default="${src.dir}" name="srcdir"/>\r
315             <attribute default="${build.classes.dir}" name="destdir"/>\r
316             <attribute default="${javac.classpath}" name="classpath"/>\r
317             <attribute default="${javac.processorpath}" name="processorpath"/>\r
318             <attribute default="${build.generated.sources.dir}/ap-source-output" name="apgeneratedsrcdir"/>\r
319             <attribute default="${includes}" name="includes"/>\r
320             <attribute default="${excludes}" name="excludes"/>\r
321             <attribute default="${javac.debug}" name="debug"/>\r
322             <attribute default="${empty.dir}" name="sourcepath"/>\r
323             <attribute default="${empty.dir}" name="gensrcdir"/>\r
324             <element name="customize" optional="true"/>\r
325             <sequential>\r
326                 <property location="${build.dir}/empty" name="empty.dir"/>\r
327                 <mkdir dir="${empty.dir}"/>\r
328                 <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}" tempdir="${java.io.tmpdir}">\r
329                     <src>\r
330                         <dirset dir="@{gensrcdir}" erroronmissingdir="false">\r
331                             <include name="*"/>\r
332                         </dirset>\r
333                     </src>\r
334                     <classpath>\r
335                         <path path="@{classpath}"/>\r
336                     </classpath>\r
337                     <compilerarg line="${endorsed.classpath.cmd.line.arg}"/>\r
338                     <compilerarg line="${javac.profile.cmd.line.arg}"/>\r
339                     <compilerarg line="${javac.compilerargs}"/>\r
340                     <customize/>\r
341                 </javac>\r
342             </sequential>\r
343         </macrodef>\r
344     </target>\r
345     <target depends="-init-macrodef-javac-with-processors,-init-macrodef-javac-without-processors" name="-init-macrodef-javac">\r
346         <macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3">\r
347             <attribute default="${src.dir}" name="srcdir"/>\r
348             <attribute default="${build.classes.dir}" name="destdir"/>\r
349             <attribute default="${javac.classpath}" name="classpath"/>\r
350             <sequential>\r
351                 <depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}">\r
352                     <classpath>\r
353                         <path path="@{classpath}"/>\r
354                     </classpath>\r
355                 </depend>\r
356             </sequential>\r
357         </macrodef>\r
358         <macrodef name="force-recompile" uri="http://www.netbeans.org/ns/j2se-project/3">\r
359             <attribute default="${build.classes.dir}" name="destdir"/>\r
360             <sequential>\r
361                 <fail unless="javac.includes">Must set javac.includes</fail>\r
362                 <pathconvert pathsep="${line.separator}" property="javac.includes.binary">\r
363                     <path>\r
364                         <filelist dir="@{destdir}" files="${javac.includes}"/>\r
365                     </path>\r
366                     <globmapper from="*.java" to="*.class"/>\r
367                 </pathconvert>\r
368                 <tempfile deleteonexit="true" property="javac.includesfile.binary"/>\r
369                 <echo file="${javac.includesfile.binary}" message="${javac.includes.binary}"/>\r
370                 <delete>\r
371                     <files includesfile="${javac.includesfile.binary}"/>\r
372                 </delete>\r
373                 <delete>\r
374                     <fileset file="${javac.includesfile.binary}"/>\r
375                 </delete>\r
376             </sequential>\r
377         </macrodef>\r
378     </target>\r
379     <target if="${junit.available}" name="-init-macrodef-junit-init">\r
380         <condition else="false" property="nb.junit.batch" value="true">\r
381             <and>\r
382                 <istrue value="${junit.available}"/>\r
383                 <not>\r
384                     <isset property="test.method"/>\r
385                 </not>\r
386             </and>\r
387         </condition>\r
388         <condition else="false" property="nb.junit.single" value="true">\r
389             <and>\r
390                 <istrue value="${junit.available}"/>\r
391                 <isset property="test.method"/>\r
392             </and>\r
393         </condition>\r
394     </target>\r
395     <target name="-init-test-properties">\r
396         <property name="test.binaryincludes" value="&lt;nothing&gt;"/>\r
397         <property name="test.binarytestincludes" value=""/>\r
398         <property name="test.binaryexcludes" value=""/>\r
399     </target>\r
400     <target if="${nb.junit.single}" name="-init-macrodef-junit-single" unless="${nb.junit.batch}">\r
401         <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">\r
402             <attribute default="${includes}" name="includes"/>\r
403             <attribute default="${excludes}" name="excludes"/>\r
404             <attribute default="**" name="testincludes"/>\r
405             <attribute default="" name="testmethods"/>\r
406             <element name="customize" optional="true"/>\r
407             <sequential>\r
408                 <property name="junit.forkmode" value="perTest"/>\r
409                 <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">\r
410                     <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>\r
411                     <syspropertyset>\r
412                         <propertyref prefix="test-sys-prop."/>\r
413                         <mapper from="test-sys-prop.*" to="*" type="glob"/>\r
414                     </syspropertyset>\r
415                     <formatter type="brief" usefile="false"/>\r
416                     <formatter type="xml"/>\r
417                     <jvmarg value="-ea"/>\r
418                     <customize/>\r
419                 </junit>\r
420             </sequential>\r
421         </macrodef>\r
422     </target>\r
423     <target depends="-init-test-properties" if="${nb.junit.batch}" name="-init-macrodef-junit-batch" unless="${nb.junit.single}">\r
424         <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">\r
425             <attribute default="${includes}" name="includes"/>\r
426             <attribute default="${excludes}" name="excludes"/>\r
427             <attribute default="**" name="testincludes"/>\r
428             <attribute default="" name="testmethods"/>\r
429             <element name="customize" optional="true"/>\r
430             <sequential>\r
431                 <property name="junit.forkmode" value="perTest"/>\r
432                 <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">\r
433                     <batchtest todir="${build.test.results.dir}">\r
434                         <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">\r
435                             <filename name="@{testincludes}"/>\r
436                         </fileset>\r
437                         <fileset dir="${build.test.classes.dir}" excludes="@{excludes},${excludes},${test.binaryexcludes}" includes="${test.binaryincludes}">\r
438                             <filename name="${test.binarytestincludes}"/>\r
439                         </fileset>\r
440                     </batchtest>\r
441                     <syspropertyset>\r
442                         <propertyref prefix="test-sys-prop."/>\r
443                         <mapper from="test-sys-prop.*" to="*" type="glob"/>\r
444                     </syspropertyset>\r
445                     <formatter type="brief" usefile="false"/>\r
446                     <formatter type="xml"/>\r
447                     <jvmarg value="-ea"/>\r
448                     <customize/>\r
449                 </junit>\r
450             </sequential>\r
451         </macrodef>\r
452     </target>\r
453     <target depends="-init-macrodef-junit-init,-init-macrodef-junit-single, -init-macrodef-junit-batch" if="${junit.available}" name="-init-macrodef-junit"/>\r
454     <target if="${testng.available}" name="-init-macrodef-testng">\r
455         <macrodef name="testng" uri="http://www.netbeans.org/ns/j2se-project/3">\r
456             <attribute default="${includes}" name="includes"/>\r
457             <attribute default="${excludes}" name="excludes"/>\r
458             <attribute default="**" name="testincludes"/>\r
459             <attribute default="" name="testmethods"/>\r
460             <element name="customize" optional="true"/>\r
461             <sequential>\r
462                 <condition else="" property="testng.methods.arg" value="@{testincludes}.@{testmethods}">\r
463                     <isset property="test.method"/>\r
464                 </condition>\r
465                 <union id="test.set">\r
466                     <fileset dir="${test.src.dir}" excludes="@{excludes},**/*.xml,${excludes}" includes="@{includes}">\r
467                         <filename name="@{testincludes}"/>\r
468                     </fileset>\r
469                 </union>\r
470                 <taskdef classname="org.testng.TestNGAntTask" classpath="${run.test.classpath}" name="testng"/>\r
471                 <testng classfilesetref="test.set" failureProperty="tests.failed" listeners="org.testng.reporters.VerboseReporter" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="jcore" testname="TestNG tests" workingDir="${work.dir}">\r
472                     <xmlfileset dir="${build.test.classes.dir}" includes="@{testincludes}"/>\r
473                     <propertyset>\r
474                         <propertyref prefix="test-sys-prop."/>\r
475                         <mapper from="test-sys-prop.*" to="*" type="glob"/>\r
476                     </propertyset>\r
477                     <customize/>\r
478                 </testng>\r
479             </sequential>\r
480         </macrodef>\r
481     </target>\r
482     <target name="-init-macrodef-test-impl">\r
483         <macrodef name="test-impl" uri="http://www.netbeans.org/ns/j2se-project/3">\r
484             <attribute default="${includes}" name="includes"/>\r
485             <attribute default="${excludes}" name="excludes"/>\r
486             <attribute default="**" name="testincludes"/>\r
487             <attribute default="" name="testmethods"/>\r
488             <element implicit="true" name="customize" optional="true"/>\r
489             <sequential>\r
490                 <echo>No tests executed.</echo>\r
491             </sequential>\r
492         </macrodef>\r
493     </target>\r
494     <target depends="-init-macrodef-junit" if="${junit.available}" name="-init-macrodef-junit-impl">\r
495         <macrodef name="test-impl" uri="http://www.netbeans.org/ns/j2se-project/3">\r
496             <attribute default="${includes}" name="includes"/>\r
497             <attribute default="${excludes}" name="excludes"/>\r
498             <attribute default="**" name="testincludes"/>\r
499             <attribute default="" name="testmethods"/>\r
500             <element implicit="true" name="customize" optional="true"/>\r
501             <sequential>\r
502                 <j2seproject3:junit excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">\r
503                     <customize/>\r
504                 </j2seproject3:junit>\r
505             </sequential>\r
506         </macrodef>\r
507     </target>\r
508     <target depends="-init-macrodef-testng" if="${testng.available}" name="-init-macrodef-testng-impl">\r
509         <macrodef name="test-impl" uri="http://www.netbeans.org/ns/j2se-project/3">\r
510             <attribute default="${includes}" name="includes"/>\r
511             <attribute default="${excludes}" name="excludes"/>\r
512             <attribute default="**" name="testincludes"/>\r
513             <attribute default="" name="testmethods"/>\r
514             <element implicit="true" name="customize" optional="true"/>\r
515             <sequential>\r
516                 <j2seproject3:testng excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">\r
517                     <customize/>\r
518                 </j2seproject3:testng>\r
519             </sequential>\r
520         </macrodef>\r
521     </target>\r
522     <target depends="-init-macrodef-test-impl,-init-macrodef-junit-impl,-init-macrodef-testng-impl" name="-init-macrodef-test">\r
523         <macrodef name="test" uri="http://www.netbeans.org/ns/j2se-project/3">\r
524             <attribute default="${includes}" name="includes"/>\r
525             <attribute default="${excludes}" name="excludes"/>\r
526             <attribute default="**" name="testincludes"/>\r
527             <attribute default="" name="testmethods"/>\r
528             <sequential>\r
529                 <j2seproject3:test-impl excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">\r
530                     <customize>\r
531                         <classpath>\r
532                             <path path="${run.test.classpath}"/>\r
533                         </classpath>\r
534                         <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>\r
535                         <jvmarg line="${run.jvmargs}"/>\r
536                         <jvmarg line="${run.jvmargs.ide}"/>\r
537                     </customize>\r
538                 </j2seproject3:test-impl>\r
539             </sequential>\r
540         </macrodef>\r
541     </target>\r
542     <target if="${junit.available}" name="-init-macrodef-junit-debug" unless="${nb.junit.batch}">\r
543         <macrodef name="junit-debug" uri="http://www.netbeans.org/ns/j2se-project/3">\r
544             <attribute default="${includes}" name="includes"/>\r
545             <attribute default="${excludes}" name="excludes"/>\r
546             <attribute default="**" name="testincludes"/>\r
547             <attribute default="" name="testmethods"/>\r
548             <element name="customize" optional="true"/>\r
549             <sequential>\r
550                 <property name="junit.forkmode" value="perTest"/>\r
551                 <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">\r
552                     <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>\r
553                     <syspropertyset>\r
554                         <propertyref prefix="test-sys-prop."/>\r
555                         <mapper from="test-sys-prop.*" to="*" type="glob"/>\r
556                     </syspropertyset>\r
557                     <formatter type="brief" usefile="false"/>\r
558                     <formatter type="xml"/>\r
559                     <jvmarg value="-ea"/>\r
560                     <jvmarg line="${debug-args-line}"/>\r
561                     <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>\r
562                     <customize/>\r
563                 </junit>\r
564             </sequential>\r
565         </macrodef>\r
566     </target>\r
567     <target depends="-init-test-properties" if="${nb.junit.batch}" name="-init-macrodef-junit-debug-batch">\r
568         <macrodef name="junit-debug" uri="http://www.netbeans.org/ns/j2se-project/3">\r
569             <attribute default="${includes}" name="includes"/>\r
570             <attribute default="${excludes}" name="excludes"/>\r
571             <attribute default="**" name="testincludes"/>\r
572             <attribute default="" name="testmethods"/>\r
573             <element name="customize" optional="true"/>\r
574             <sequential>\r
575                 <property name="junit.forkmode" value="perTest"/>\r
576                 <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" forkmode="${junit.forkmode}" showoutput="true" tempdir="${build.dir}">\r
577                     <batchtest todir="${build.test.results.dir}">\r
578                         <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">\r
579                             <filename name="@{testincludes}"/>\r
580                         </fileset>\r
581                         <fileset dir="${build.test.classes.dir}" excludes="@{excludes},${excludes},${test.binaryexcludes}" includes="${test.binaryincludes}">\r
582                             <filename name="${test.binarytestincludes}"/>\r
583                         </fileset>\r
584                     </batchtest>\r
585                     <syspropertyset>\r
586                         <propertyref prefix="test-sys-prop."/>\r
587                         <mapper from="test-sys-prop.*" to="*" type="glob"/>\r
588                     </syspropertyset>\r
589                     <formatter type="brief" usefile="false"/>\r
590                     <formatter type="xml"/>\r
591                     <jvmarg value="-ea"/>\r
592                     <jvmarg line="${debug-args-line}"/>\r
593                     <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>\r
594                     <customize/>\r
595                 </junit>\r
596             </sequential>\r
597         </macrodef>\r
598     </target>\r
599     <target depends="-init-macrodef-junit-debug,-init-macrodef-junit-debug-batch" if="${junit.available}" name="-init-macrodef-junit-debug-impl">\r
600         <macrodef name="test-debug-impl" uri="http://www.netbeans.org/ns/j2se-project/3">\r
601             <attribute default="${includes}" name="includes"/>\r
602             <attribute default="${excludes}" name="excludes"/>\r
603             <attribute default="**" name="testincludes"/>\r
604             <attribute default="" name="testmethods"/>\r
605             <element implicit="true" name="customize" optional="true"/>\r
606             <sequential>\r
607                 <j2seproject3:junit-debug excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">\r
608                     <customize/>\r
609                 </j2seproject3:junit-debug>\r
610             </sequential>\r
611         </macrodef>\r
612     </target>\r
613     <target if="${testng.available}" name="-init-macrodef-testng-debug">\r
614         <macrodef name="testng-debug" uri="http://www.netbeans.org/ns/j2se-project/3">\r
615             <attribute default="${main.class}" name="testClass"/>\r
616             <attribute default="" name="testMethod"/>\r
617             <element name="customize2" optional="true"/>\r
618             <sequential>\r
619                 <condition else="-testclass @{testClass}" property="test.class.or.method" value="-methods @{testClass}.@{testMethod}">\r
620                     <isset property="test.method"/>\r
621                 </condition>\r
622                 <condition else="-suitename jcore -testname @{testClass} ${test.class.or.method}" property="testng.cmd.args" value="@{testClass}">\r
623                     <matches pattern=".*\.xml" string="@{testClass}"/>\r
624                 </condition>\r
625                 <delete dir="${build.test.results.dir}" quiet="true"/>\r
626                 <mkdir dir="${build.test.results.dir}"/>\r
627                 <j2seproject3:debug classname="org.testng.TestNG" classpath="${debug.test.classpath}">\r
628                     <customize>\r
629                         <customize2/>\r
630                         <jvmarg value="-ea"/>\r
631                         <arg line="${testng.debug.mode}"/>\r
632                         <arg line="-d ${build.test.results.dir}"/>\r
633                         <arg line="-listener org.testng.reporters.VerboseReporter"/>\r
634                         <arg line="${testng.cmd.args}"/>\r
635                     </customize>\r
636                 </j2seproject3:debug>\r
637             </sequential>\r
638         </macrodef>\r
639     </target>\r
640     <target depends="-init-macrodef-testng-debug" if="${testng.available}" name="-init-macrodef-testng-debug-impl">\r
641         <macrodef name="testng-debug-impl" uri="http://www.netbeans.org/ns/j2se-project/3">\r
642             <attribute default="${main.class}" name="testClass"/>\r
643             <attribute default="" name="testMethod"/>\r
644             <element implicit="true" name="customize2" optional="true"/>\r
645             <sequential>\r
646                 <j2seproject3:testng-debug testClass="@{testClass}" testMethod="@{testMethod}">\r
647                     <customize2/>\r
648                 </j2seproject3:testng-debug>\r
649             </sequential>\r
650         </macrodef>\r
651     </target>\r
652     <target depends="-init-macrodef-junit-debug-impl" if="${junit.available}" name="-init-macrodef-test-debug-junit">\r
653         <macrodef name="test-debug" uri="http://www.netbeans.org/ns/j2se-project/3">\r
654             <attribute default="${includes}" name="includes"/>\r
655             <attribute default="${excludes}" name="excludes"/>\r
656             <attribute default="**" name="testincludes"/>\r
657             <attribute default="" name="testmethods"/>\r
658             <attribute default="${main.class}" name="testClass"/>\r
659             <attribute default="" name="testMethod"/>\r
660             <sequential>\r
661                 <j2seproject3:test-debug-impl excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">\r
662                     <customize>\r
663                         <classpath>\r
664                             <path path="${run.test.classpath}"/>\r
665                         </classpath>\r
666                         <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>\r
667                         <jvmarg line="${run.jvmargs}"/>\r
668                         <jvmarg line="${run.jvmargs.ide}"/>\r
669                     </customize>\r
670                 </j2seproject3:test-debug-impl>\r
671             </sequential>\r
672         </macrodef>\r
673     </target>\r
674     <target depends="-init-macrodef-testng-debug-impl" if="${testng.available}" name="-init-macrodef-test-debug-testng">\r
675         <macrodef name="test-debug" uri="http://www.netbeans.org/ns/j2se-project/3">\r
676             <attribute default="${includes}" name="includes"/>\r
677             <attribute default="${excludes}" name="excludes"/>\r
678             <attribute default="**" name="testincludes"/>\r
679             <attribute default="" name="testmethods"/>\r
680             <attribute default="${main.class}" name="testClass"/>\r
681             <attribute default="" name="testMethod"/>\r
682             <sequential>\r
683                 <j2seproject3:testng-debug-impl testClass="@{testClass}" testMethod="@{testMethod}">\r
684                     <customize2>\r
685                         <syspropertyset>\r
686                             <propertyref prefix="test-sys-prop."/>\r
687                             <mapper from="test-sys-prop.*" to="*" type="glob"/>\r
688                         </syspropertyset>\r
689                     </customize2>\r
690                 </j2seproject3:testng-debug-impl>\r
691             </sequential>\r
692         </macrodef>\r
693     </target>\r
694     <target depends="-init-macrodef-test-debug-junit,-init-macrodef-test-debug-testng" name="-init-macrodef-test-debug"/>\r
695     <!--\r
696                 pre NB7.2 profiling section; consider it deprecated\r
697             -->\r
698     <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile, -profile-init-check" if="profiler.info.jvmargs.agent" name="profile-init"/>\r
699     <target if="profiler.info.jvmargs.agent" name="-profile-pre-init">\r
700         <!-- Empty placeholder for easier customization. -->\r
701         <!-- You can override this target in the ../build.xml file. -->\r
702     </target>\r
703     <target if="profiler.info.jvmargs.agent" name="-profile-post-init">\r
704         <!-- Empty placeholder for easier customization. -->\r
705         <!-- You can override this target in the ../build.xml file. -->\r
706     </target>\r
707     <target if="profiler.info.jvmargs.agent" name="-profile-init-macrodef-profile">\r
708         <macrodef name="resolve">\r
709             <attribute name="name"/>\r
710             <attribute name="value"/>\r
711             <sequential>\r
712                 <property name="@{name}" value="${env.@{value}}"/>\r
713             </sequential>\r
714         </macrodef>\r
715         <macrodef name="profile">\r
716             <attribute default="${main.class}" name="classname"/>\r
717             <element name="customize" optional="true"/>\r
718             <sequential>\r
719                 <property environment="env"/>\r
720                 <resolve name="profiler.current.path" value="${profiler.info.pathvar}"/>\r
721                 <java classname="@{classname}" dir="${profiler.info.dir}" fork="true" jvm="${profiler.info.jvm}">\r
722                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>\r
723                     <jvmarg value="${profiler.info.jvmargs.agent}"/>\r
724                     <jvmarg line="${profiler.info.jvmargs}"/>\r
725                     <env key="${profiler.info.pathvar}" path="${profiler.info.agentpath}:${profiler.current.path}"/>\r
726                     <arg line="${application.args}"/>\r
727                     <classpath>\r
728                         <path path="${run.classpath}"/>\r
729                     </classpath>\r
730                     <syspropertyset>\r
731                         <propertyref prefix="run-sys-prop."/>\r
732                         <mapper from="run-sys-prop.*" to="*" type="glob"/>\r
733                     </syspropertyset>\r
734                     <customize/>\r
735                 </java>\r
736             </sequential>\r
737         </macrodef>\r
738     </target>\r
739     <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-macrodef-profile" if="profiler.info.jvmargs.agent" name="-profile-init-check">\r
740         <fail unless="profiler.info.jvm">Must set JVM to use for profiling in profiler.info.jvm</fail>\r
741         <fail unless="profiler.info.jvmargs.agent">Must set profiler agent JVM arguments in profiler.info.jvmargs.agent</fail>\r
742     </target>\r
743     <!--\r
744                 end of pre NB7.2 profiling section\r
745             -->\r
746     <target depends="-init-debug-args" name="-init-macrodef-nbjpda">\r
747         <macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1">\r
748             <attribute default="${main.class}" name="name"/>\r
749             <attribute default="${debug.classpath}" name="classpath"/>\r
750             <attribute default="" name="stopclassname"/>\r
751             <sequential>\r
752                 <nbjpdastart addressproperty="jpda.address" name="@{name}" stopclassname="@{stopclassname}" transport="${debug-transport}">\r
753                     <classpath>\r
754                         <path path="@{classpath}"/>\r
755                     </classpath>\r
756                 </nbjpdastart>\r
757             </sequential>\r
758         </macrodef>\r
759         <macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/j2se-project/1">\r
760             <attribute default="${build.classes.dir}" name="dir"/>\r
761             <sequential>\r
762                 <nbjpdareload>\r
763                     <fileset dir="@{dir}" includes="${fix.classes}">\r
764                         <include name="${fix.includes}*.class"/>\r
765                     </fileset>\r
766                 </nbjpdareload>\r
767             </sequential>\r
768         </macrodef>\r
769     </target>\r
770     <target name="-init-debug-args">\r
771         <property name="version-output" value="java version &quot;${ant.java.version}"/>\r
772         <condition property="have-jdk-older-than-1.4">\r
773             <or>\r
774                 <contains string="${version-output}" substring="java version &quot;1.0"/>\r
775                 <contains string="${version-output}" substring="java version &quot;1.1"/>\r
776                 <contains string="${version-output}" substring="java version &quot;1.2"/>\r
777                 <contains string="${version-output}" substring="java version &quot;1.3"/>\r
778             </or>\r
779         </condition>\r
780         <condition else="-Xdebug" property="debug-args-line" value="-Xdebug -Xnoagent -Djava.compiler=none">\r
781             <istrue value="${have-jdk-older-than-1.4}"/>\r
782         </condition>\r
783         <condition else="dt_socket" property="debug-transport-by-os" value="dt_shmem">\r
784             <os family="windows"/>\r
785         </condition>\r
786         <condition else="${debug-transport-by-os}" property="debug-transport" value="${debug.transport}">\r
787             <isset property="debug.transport"/>\r
788         </condition>\r
789     </target>\r
790     <target depends="-init-debug-args" name="-init-macrodef-debug">\r
791         <macrodef name="debug" uri="http://www.netbeans.org/ns/j2se-project/3">\r
792             <attribute default="${main.class}" name="classname"/>\r
793             <attribute default="${debug.classpath}" name="classpath"/>\r
794             <element name="customize" optional="true"/>\r
795             <sequential>\r
796                 <java classname="@{classname}" dir="${work.dir}" fork="true">\r
797                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>\r
798                     <jvmarg line="${debug-args-line}"/>\r
799                     <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>\r
800                     <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>\r
801                     <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>\r
802                     <jvmarg line="${run.jvmargs}"/>\r
803                     <jvmarg line="${run.jvmargs.ide}"/>\r
804                     <classpath>\r
805                         <path path="@{classpath}"/>\r
806                     </classpath>\r
807                     <syspropertyset>\r
808                         <propertyref prefix="run-sys-prop."/>\r
809                         <mapper from="run-sys-prop.*" to="*" type="glob"/>\r
810                     </syspropertyset>\r
811                     <customize/>\r
812                 </java>\r
813             </sequential>\r
814         </macrodef>\r
815     </target>\r
816     <target name="-init-macrodef-java">\r
817         <macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1">\r
818             <attribute default="${main.class}" name="classname"/>\r
819             <attribute default="${run.classpath}" name="classpath"/>\r
820             <attribute default="jvm" name="jvm"/>\r
821             <element name="customize" optional="true"/>\r
822             <sequential>\r
823                 <java classname="@{classname}" dir="${work.dir}" fork="true">\r
824                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>\r
825                     <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>\r
826                     <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>\r
827                     <jvmarg line="${run.jvmargs}"/>\r
828                     <jvmarg line="${run.jvmargs.ide}"/>\r
829                     <classpath>\r
830                         <path path="@{classpath}"/>\r
831                     </classpath>\r
832                     <syspropertyset>\r
833                         <propertyref prefix="run-sys-prop."/>\r
834                         <mapper from="run-sys-prop.*" to="*" type="glob"/>\r
835                     </syspropertyset>\r
836                     <customize/>\r
837                 </java>\r
838             </sequential>\r
839         </macrodef>\r
840     </target>\r
841     <target name="-init-macrodef-copylibs">\r
842         <macrodef name="copylibs" uri="http://www.netbeans.org/ns/j2se-project/3">\r
843             <attribute default="${manifest.file}" name="manifest"/>\r
844             <element name="customize" optional="true"/>\r
845             <sequential>\r
846                 <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>\r
847                 <pathconvert property="run.classpath.without.build.classes.dir">\r
848                     <path path="${run.classpath}"/>\r
849                     <map from="${build.classes.dir.resolved}" to=""/>\r
850                 </pathconvert>\r
851                 <pathconvert pathsep=" " property="jar.classpath">\r
852                     <path path="${run.classpath.without.build.classes.dir}"/>\r
853                     <chainedmapper>\r
854                         <flattenmapper/>\r
855                         <filtermapper>\r
856                             <replacestring from=" " to="%20"/>\r
857                         </filtermapper>\r
858                         <globmapper from="*" to="lib/*"/>\r
859                     </chainedmapper>\r
860                 </pathconvert>\r
861                 <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>\r
862                 <copylibs compress="${jar.compress}" excludeFromCopy="${copylibs.excludes}" index="${jar.index}" indexMetaInf="${jar.index.metainf}" jarfile="${dist.jar}" manifest="@{manifest}" rebase="${copylibs.rebase}" runtimeclasspath="${run.classpath.without.build.classes.dir}">\r
863                     <fileset dir="${build.classes.dir}" excludes="${dist.archive.excludes}"/>\r
864                     <manifest>\r
865                         <attribute name="Class-Path" value="${jar.classpath}"/>\r
866                         <customize/>\r
867                     </manifest>\r
868                 </copylibs>\r
869             </sequential>\r
870         </macrodef>\r
871     </target>\r
872     <target name="-init-presetdef-jar">\r
873         <presetdef name="jar" uri="http://www.netbeans.org/ns/j2se-project/1">\r
874             <jar compress="${jar.compress}" index="${jar.index}" jarfile="${dist.jar}">\r
875                 <j2seproject1:fileset dir="${build.classes.dir}" excludes="${dist.archive.excludes}"/>\r
876             </jar>\r
877         </presetdef>\r
878     </target>\r
879     <target name="-init-ap-cmdline-properties">\r
880         <property name="annotation.processing.enabled" value="true"/>\r
881         <property name="annotation.processing.processors.list" value=""/>\r
882         <property name="annotation.processing.processor.options" value=""/>\r
883         <property name="annotation.processing.run.all.processors" value="true"/>\r
884         <property name="javac.processorpath" value="${javac.classpath}"/>\r
885         <property name="javac.test.processorpath" value="${javac.test.classpath}"/>\r
886         <condition property="ap.supported.internal" value="true">\r
887             <not>\r
888                 <matches pattern="1\.[0-5](\..*)?" string="${javac.source}"/>\r
889             </not>\r
890         </condition>\r
891     </target>\r
892     <target depends="-init-ap-cmdline-properties" if="ap.supported.internal" name="-init-ap-cmdline-supported">\r
893         <condition else="" property="ap.processors.internal" value="-processor ${annotation.processing.processors.list}">\r
894             <isfalse value="${annotation.processing.run.all.processors}"/>\r
895         </condition>\r
896         <condition else="" property="ap.proc.none.internal" value="-proc:none">\r
897             <isfalse value="${annotation.processing.enabled}"/>\r
898         </condition>\r
899     </target>\r
900     <target depends="-init-ap-cmdline-properties,-init-ap-cmdline-supported" name="-init-ap-cmdline">\r
901         <property name="ap.cmd.line.internal" value=""/>\r
902     </target>\r
903     <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-test,-init-macrodef-test-debug,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar,-init-ap-cmdline" name="init"/>\r
904     <!--\r
905                 ===================\r
906                 COMPILATION SECTION\r
907                 ===================\r
908             -->\r
909     <target name="-deps-jar-init" unless="built-jar.properties">\r
910         <property location="${build.dir}/built-jar.properties" name="built-jar.properties"/>\r
911         <delete file="${built-jar.properties}" quiet="true"/>\r
912     </target>\r
913     <target if="already.built.jar.${basedir}" name="-warn-already-built-jar">\r
914         <echo level="warn" message="Cycle detected: jcore was already built"/>\r
915     </target>\r
916     <target depends="init,-deps-jar-init" name="deps-jar" unless="no.deps">\r
917         <mkdir dir="${build.dir}"/>\r
918         <touch file="${built-jar.properties}" verbose="false"/>\r
919         <property file="${built-jar.properties}" prefix="already.built.jar."/>\r
920         <antcall target="-warn-already-built-jar"/>\r
921         <propertyfile file="${built-jar.properties}">\r
922             <entry key="${basedir}" value=""/>\r
923         </propertyfile>\r
924     </target>\r
925     <target depends="init,-check-automatic-build,-clean-after-automatic-build" name="-verify-automatic-build"/>\r
926     <target depends="init" name="-check-automatic-build">\r
927         <available file="${build.classes.dir}/.netbeans_automatic_build" property="netbeans.automatic.build"/>\r
928     </target>\r
929     <target depends="init" if="netbeans.automatic.build" name="-clean-after-automatic-build">\r
930         <antcall target="clean"/>\r
931     </target>\r
932     <target depends="init,deps-jar" name="-pre-pre-compile">\r
933         <mkdir dir="${build.classes.dir}"/>\r
934     </target>\r
935     <target name="-pre-compile">\r
936         <!-- Empty placeholder for easier customization. -->\r
937         <!-- You can override this target in the ../build.xml file. -->\r
938     </target>\r
939     <target if="do.depend.true" name="-compile-depend">\r
940         <pathconvert property="build.generated.subdirs">\r
941             <dirset dir="${build.generated.sources.dir}" erroronmissingdir="false">\r
942                 <include name="*"/>\r
943             </dirset>\r
944         </pathconvert>\r
945         <j2seproject3:depend srcdir="${src.dir}:${build.generated.subdirs}"/>\r
946     </target>\r
947     <target depends="init,deps-jar,-pre-pre-compile,-pre-compile, -copy-persistence-xml,-compile-depend" if="have.sources" name="-do-compile">\r
948         <j2seproject3:javac gensrcdir="${build.generated.sources.dir}"/>\r
949         <copy todir="${build.classes.dir}">\r
950             <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>\r
951         </copy>\r
952     </target>\r
953     <target if="has.persistence.xml" name="-copy-persistence-xml">\r
954         <mkdir dir="${build.classes.dir}/META-INF"/>\r
955         <copy todir="${build.classes.dir}/META-INF">\r
956             <fileset dir="${meta.inf.dir}" includes="persistence.xml orm.xml"/>\r
957         </copy>\r
958     </target>\r
959     <target name="-post-compile">\r
960         <!-- Empty placeholder for easier customization. -->\r
961         <!-- You can override this target in the ../build.xml file. -->\r
962     </target>\r
963     <target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/>\r
964     <target name="-pre-compile-single">\r
965         <!-- Empty placeholder for easier customization. -->\r
966         <!-- You can override this target in the ../build.xml file. -->\r
967     </target>\r
968     <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">\r
969         <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>\r
970         <j2seproject3:force-recompile/>\r
971         <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.dir}"/>\r
972     </target>\r
973     <target name="-post-compile-single">\r
974         <!-- Empty placeholder for easier customization. -->\r
975         <!-- You can override this target in the ../build.xml file. -->\r
976     </target>\r
977     <target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/>\r
978     <!--\r
979                 ====================\r
980                 JAR BUILDING SECTION\r
981                 ====================\r
982             -->\r
983     <target depends="init" name="-pre-pre-jar">\r
984         <dirname file="${dist.jar}" property="dist.jar.dir"/>\r
985         <mkdir dir="${dist.jar.dir}"/>\r
986     </target>\r
987     <target name="-pre-jar">\r
988         <!-- Empty placeholder for easier customization. -->\r
989         <!-- You can override this target in the ../build.xml file. -->\r
990     </target>\r
991     <target depends="init" if="do.archive" name="-do-jar-create-manifest" unless="manifest.available">\r
992         <tempfile deleteonexit="true" destdir="${build.dir}" property="tmp.manifest.file"/>\r
993         <touch file="${tmp.manifest.file}" verbose="false"/>\r
994     </target>\r
995     <target depends="init" if="do.archive+manifest.available" name="-do-jar-copy-manifest">\r
996         <tempfile deleteonexit="true" destdir="${build.dir}" property="tmp.manifest.file"/>\r
997         <copy file="${manifest.file}" tofile="${tmp.manifest.file}"/>\r
998     </target>\r
999     <target depends="init,-do-jar-create-manifest,-do-jar-copy-manifest" if="do.archive+main.class.available" name="-do-jar-set-mainclass">\r
1000         <manifest file="${tmp.manifest.file}" mode="update">\r
1001             <attribute name="Main-Class" value="${main.class}"/>\r
1002         </manifest>\r
1003     </target>\r
1004     <target depends="init,-do-jar-create-manifest,-do-jar-copy-manifest" if="do.archive+profile.available" name="-do-jar-set-profile">\r
1005         <manifest file="${tmp.manifest.file}" mode="update">\r
1006             <attribute name="Profile" value="${javac.profile}"/>\r
1007         </manifest>\r
1008     </target>\r
1009     <target depends="init,-do-jar-create-manifest,-do-jar-copy-manifest" if="do.archive+splashscreen.available" name="-do-jar-set-splashscreen">\r
1010         <basename file="${application.splash}" property="splashscreen.basename"/>\r
1011         <mkdir dir="${build.classes.dir}/META-INF"/>\r
1012         <copy failonerror="false" file="${application.splash}" todir="${build.classes.dir}/META-INF"/>\r
1013         <manifest file="${tmp.manifest.file}" mode="update">\r
1014             <attribute name="SplashScreen-Image" value="META-INF/${splashscreen.basename}"/>\r
1015         </manifest>\r
1016     </target>\r
1017     <target depends="init,-init-macrodef-copylibs,compile,-pre-pre-jar,-pre-jar,-do-jar-create-manifest,-do-jar-copy-manifest,-do-jar-set-mainclass,-do-jar-set-profile,-do-jar-set-splashscreen" if="do.mkdist" name="-do-jar-copylibs">\r
1018         <j2seproject3:copylibs manifest="${tmp.manifest.file}"/>\r
1019         <echo level="info">To run this application from the command line without Ant, try:</echo>\r
1020         <property location="${dist.jar}" name="dist.jar.resolved"/>\r
1021         <echo level="info">java -jar "${dist.jar.resolved}"</echo>\r
1022     </target>\r
1023     <target depends="init,compile,-pre-pre-jar,-pre-jar,-do-jar-create-manifest,-do-jar-copy-manifest,-do-jar-set-mainclass,-do-jar-set-profile,-do-jar-set-splashscreen" if="do.archive" name="-do-jar-jar" unless="do.mkdist">\r
1024         <j2seproject1:jar manifest="${tmp.manifest.file}"/>\r
1025         <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>\r
1026         <property location="${dist.jar}" name="dist.jar.resolved"/>\r
1027         <pathconvert property="run.classpath.with.dist.jar">\r
1028             <path path="${run.classpath}"/>\r
1029             <map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>\r
1030         </pathconvert>\r
1031         <condition else="" property="jar.usage.message" value="To run this application from the command line without Ant, try:${line.separator}${platform.java} -cp ${run.classpath.with.dist.jar} ${main.class}">\r
1032             <isset property="main.class.available"/>\r
1033         </condition>\r
1034         <condition else="debug" property="jar.usage.level" value="info">\r
1035             <isset property="main.class.available"/>\r
1036         </condition>\r
1037         <echo level="${jar.usage.level}" message="${jar.usage.message}"/>\r
1038     </target>\r
1039     <target depends="-do-jar-copylibs" if="do.archive" name="-do-jar-delete-manifest">\r
1040         <delete>\r
1041             <fileset file="${tmp.manifest.file}"/>\r
1042         </delete>\r
1043     </target>\r
1044     <target depends="init,compile,-pre-pre-jar,-pre-jar,-do-jar-create-manifest,-do-jar-copy-manifest,-do-jar-set-mainclass,-do-jar-set-profile,-do-jar-set-splashscreen,-do-jar-jar,-do-jar-delete-manifest" name="-do-jar-without-libraries"/>\r
1045     <target depends="init,compile,-pre-pre-jar,-pre-jar,-do-jar-create-manifest,-do-jar-copy-manifest,-do-jar-set-mainclass,-do-jar-set-profile,-do-jar-set-splashscreen,-do-jar-copylibs,-do-jar-delete-manifest" name="-do-jar-with-libraries"/>\r
1046     <target name="-post-jar">\r
1047         <!-- Empty placeholder for easier customization. -->\r
1048         <!-- You can override this target in the ../build.xml file. -->\r
1049     </target>\r
1050     <target depends="init,compile,-pre-jar,-do-jar-without-libraries,-do-jar-with-libraries,-post-jar" name="-do-jar"/>\r
1051     <target depends="init,compile,-pre-jar,-do-jar,-post-jar" description="Build JAR." name="jar"/>\r
1052     <!--\r
1053                 =================\r
1054                 EXECUTION SECTION\r
1055                 =================\r
1056             -->\r
1057     <target depends="init,compile" description="Run a main class." name="run">\r
1058         <j2seproject1:java>\r
1059             <customize>\r
1060                 <arg line="${application.args}"/>\r
1061             </customize>\r
1062         </j2seproject1:java>\r
1063     </target>\r
1064     <target name="-do-not-recompile">\r
1065         <property name="javac.includes.binary" value=""/>\r
1066     </target>\r
1067     <target depends="init,compile-single" name="run-single">\r
1068         <fail unless="run.class">Must select one file in the IDE or set run.class</fail>\r
1069         <j2seproject1:java classname="${run.class}"/>\r
1070     </target>\r
1071     <target depends="init,compile-test-single" name="run-test-with-main">\r
1072         <fail unless="run.class">Must select one file in the IDE or set run.class</fail>\r
1073         <j2seproject1:java classname="${run.class}" classpath="${run.test.classpath}"/>\r
1074     </target>\r
1075     <!--\r
1076                 =================\r
1077                 DEBUGGING SECTION\r
1078                 =================\r
1079             -->\r
1080     <target depends="init" if="netbeans.home" name="-debug-start-debugger">\r
1081         <j2seproject1:nbjpdastart name="${debug.class}"/>\r
1082     </target>\r
1083     <target depends="init" if="netbeans.home" name="-debug-start-debugger-main-test">\r
1084         <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${debug.class}"/>\r
1085     </target>\r
1086     <target depends="init,compile" name="-debug-start-debuggee">\r
1087         <j2seproject3:debug>\r
1088             <customize>\r
1089                 <arg line="${application.args}"/>\r
1090             </customize>\r
1091         </j2seproject3:debug>\r
1092     </target>\r
1093     <target depends="init,compile,-debug-start-debugger,-debug-start-debuggee" description="Debug project in IDE." if="netbeans.home" name="debug"/>\r
1094     <target depends="init" if="netbeans.home" name="-debug-start-debugger-stepinto">\r
1095         <j2seproject1:nbjpdastart stopclassname="${main.class}"/>\r
1096     </target>\r
1097     <target depends="init,compile,-debug-start-debugger-stepinto,-debug-start-debuggee" if="netbeans.home" name="debug-stepinto"/>\r
1098     <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single">\r
1099         <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>\r
1100         <j2seproject3:debug classname="${debug.class}"/>\r
1101     </target>\r
1102     <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single"/>\r
1103     <target depends="init,compile-test-single" if="netbeans.home" name="-debug-start-debuggee-main-test">\r
1104         <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>\r
1105         <j2seproject3:debug classname="${debug.class}" classpath="${debug.test.classpath}"/>\r
1106     </target>\r
1107     <target depends="init,compile-test-single,-debug-start-debugger-main-test,-debug-start-debuggee-main-test" if="netbeans.home" name="debug-test-with-main"/>\r
1108     <target depends="init" name="-pre-debug-fix">\r
1109         <fail unless="fix.includes">Must set fix.includes</fail>\r
1110         <property name="javac.includes" value="${fix.includes}.java"/>\r
1111     </target>\r
1112     <target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix">\r
1113         <j2seproject1:nbjpdareload/>\r
1114     </target>\r
1115     <target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/>\r
1116     <!--\r
1117                 =================\r
1118                 PROFILING SECTION\r
1119                 =================\r
1120             -->\r
1121     <!--\r
1122                 pre NB7.2 profiler integration\r
1123             -->\r
1124     <target depends="profile-init,compile" description="Profile a project in the IDE." if="profiler.info.jvmargs.agent" name="-profile-pre72">\r
1125         <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>\r
1126         <nbprofiledirect>\r
1127             <classpath>\r
1128                 <path path="${run.classpath}"/>\r
1129             </classpath>\r
1130         </nbprofiledirect>\r
1131         <profile/>\r
1132     </target>\r
1133     <target depends="profile-init,compile-single" description="Profile a selected class in the IDE." if="profiler.info.jvmargs.agent" name="-profile-single-pre72">\r
1134         <fail unless="profile.class">Must select one file in the IDE or set profile.class</fail>\r
1135         <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>\r
1136         <nbprofiledirect>\r
1137             <classpath>\r
1138                 <path path="${run.classpath}"/>\r
1139             </classpath>\r
1140         </nbprofiledirect>\r
1141         <profile classname="${profile.class}"/>\r
1142     </target>\r
1143     <target depends="profile-init,compile-single" if="profiler.info.jvmargs.agent" name="-profile-applet-pre72">\r
1144         <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>\r
1145         <nbprofiledirect>\r
1146             <classpath>\r
1147                 <path path="${run.classpath}"/>\r
1148             </classpath>\r
1149         </nbprofiledirect>\r
1150         <profile classname="sun.applet.AppletViewer">\r
1151             <customize>\r
1152                 <arg value="${applet.url}"/>\r
1153             </customize>\r
1154         </profile>\r
1155     </target>\r
1156     <target depends="profile-init,compile-test-single" if="profiler.info.jvmargs.agent" name="-profile-test-single-pre72">\r
1157         <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>\r
1158         <nbprofiledirect>\r
1159             <classpath>\r
1160                 <path path="${run.test.classpath}"/>\r
1161             </classpath>\r
1162         </nbprofiledirect>\r
1163         <junit dir="${profiler.info.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" jvm="${profiler.info.jvm}" showoutput="true">\r
1164             <env key="${profiler.info.pathvar}" path="${profiler.info.agentpath}:${profiler.current.path}"/>\r
1165             <jvmarg value="${profiler.info.jvmargs.agent}"/>\r
1166             <jvmarg line="${profiler.info.jvmargs}"/>\r
1167             <test name="${profile.class}"/>\r
1168             <classpath>\r
1169                 <path path="${run.test.classpath}"/>\r
1170             </classpath>\r
1171             <syspropertyset>\r
1172                 <propertyref prefix="test-sys-prop."/>\r
1173                 <mapper from="test-sys-prop.*" to="*" type="glob"/>\r
1174             </syspropertyset>\r
1175             <formatter type="brief" usefile="false"/>\r
1176             <formatter type="xml"/>\r
1177         </junit>\r
1178     </target>\r
1179     <!--\r
1180                 end of pre NB72 profiling section\r
1181             -->\r
1182     <target if="netbeans.home" name="-profile-check">\r
1183         <condition property="profiler.configured">\r
1184             <or>\r
1185                 <contains casesensitive="true" string="${run.jvmargs.ide}" substring="-agentpath:"/>\r
1186                 <contains casesensitive="true" string="${run.jvmargs.ide}" substring="-javaagent:"/>\r
1187             </or>\r
1188         </condition>\r
1189     </target>\r
1190     <target depends="-profile-check,-profile-pre72" description="Profile a project in the IDE." if="profiler.configured" name="profile" unless="profiler.info.jvmargs.agent">\r
1191         <startprofiler/>\r
1192         <antcall target="run"/>\r
1193     </target>\r
1194     <target depends="-profile-check,-profile-single-pre72" description="Profile a selected class in the IDE." if="profiler.configured" name="profile-single" unless="profiler.info.jvmargs.agent">\r
1195         <fail unless="run.class">Must select one file in the IDE or set run.class</fail>\r
1196         <startprofiler/>\r
1197         <antcall target="run-single"/>\r
1198     </target>\r
1199     <target depends="-profile-test-single-pre72" description="Profile a selected test in the IDE." name="profile-test-single"/>\r
1200     <target depends="-profile-check" description="Profile a selected test in the IDE." if="profiler.configured" name="profile-test" unless="profiler.info.jvmargs">\r
1201         <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>\r
1202         <startprofiler/>\r
1203         <antcall target="test-single"/>\r
1204     </target>\r
1205     <target depends="-profile-check" description="Profile a selected class in the IDE." if="profiler.configured" name="profile-test-with-main">\r
1206         <fail unless="run.class">Must select one file in the IDE or set run.class</fail>\r
1207         <startprofiler/>\r
1208         <antcal target="run-test-with-main"/>\r
1209     </target>\r
1210     <target depends="-profile-check,-profile-applet-pre72" if="profiler.configured" name="profile-applet" unless="profiler.info.jvmargs.agent">\r
1211         <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>\r
1212         <startprofiler/>\r
1213         <antcall target="run-applet"/>\r
1214     </target>\r
1215     <!--\r
1216                 ===============\r
1217                 JAVADOC SECTION\r
1218                 ===============\r
1219             -->\r
1220     <target depends="init" if="have.sources" name="-javadoc-build">\r
1221         <mkdir dir="${dist.javadoc.dir}"/>\r
1222         <condition else="" property="javadoc.endorsed.classpath.cmd.line.arg" value="-J${endorsed.classpath.cmd.line.arg}">\r
1223             <and>\r
1224                 <isset property="endorsed.classpath.cmd.line.arg"/>\r
1225                 <not>\r
1226                     <equals arg1="${endorsed.classpath.cmd.line.arg}" arg2=""/>\r
1227                 </not>\r
1228             </and>\r
1229         </condition>\r
1230         <condition else="" property="bug5101868workaround" value="*.java">\r
1231             <matches pattern="1\.[56](\..*)?" string="${java.version}"/>\r
1232         </condition>\r
1233         <javadoc additionalparam="-J-Dfile.encoding=${file.encoding} ${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}">\r
1234             <classpath>\r
1235                 <path path="${javac.classpath}"/>\r
1236             </classpath>\r
1237             <fileset dir="${src.dir}" excludes="${bug5101868workaround},${excludes}" includes="${includes}">\r
1238                 <filename name="**/*.java"/>\r
1239             </fileset>\r
1240             <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">\r
1241                 <include name="**/*.java"/>\r
1242                 <exclude name="*.java"/>\r
1243             </fileset>\r
1244             <arg line="${javadoc.endorsed.classpath.cmd.line.arg}"/>\r
1245         </javadoc>\r
1246         <copy todir="${dist.javadoc.dir}">\r
1247             <fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">\r
1248                 <filename name="**/doc-files/**"/>\r
1249             </fileset>\r
1250             <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">\r
1251                 <include name="**/doc-files/**"/>\r
1252             </fileset>\r
1253         </copy>\r
1254     </target>\r
1255     <target depends="init,-javadoc-build" if="netbeans.home" name="-javadoc-browse" unless="no.javadoc.preview">\r
1256         <nbbrowse file="${dist.javadoc.dir}/index.html"/>\r
1257     </target>\r
1258     <target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/>\r
1259     <!--\r
1260                 =========================\r
1261                 TEST COMPILATION SECTION\r
1262                 =========================\r
1263             -->\r
1264     <target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">\r
1265         <mkdir dir="${build.test.classes.dir}"/>\r
1266     </target>\r
1267     <target name="-pre-compile-test">\r
1268         <!-- Empty placeholder for easier customization. -->\r
1269         <!-- You can override this target in the ../build.xml file. -->\r
1270     </target>\r
1271     <target if="do.depend.true" name="-compile-test-depend">\r
1272         <j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>\r
1273     </target>\r
1274     <target depends="init,deps-jar,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test">\r
1275         <j2seproject3:javac apgeneratedsrcdir="${build.test.classes.dir}" classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" processorpath="${javac.test.processorpath}" srcdir="${test.src.dir}"/>\r
1276         <copy todir="${build.test.classes.dir}">\r
1277             <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>\r
1278         </copy>\r
1279     </target>\r
1280     <target name="-post-compile-test">\r
1281         <!-- Empty placeholder for easier customization. -->\r
1282         <!-- You can override this target in the ../build.xml file. -->\r
1283     </target>\r
1284     <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/>\r
1285     <target name="-pre-compile-test-single">\r
1286         <!-- Empty placeholder for easier customization. -->\r
1287         <!-- You can override this target in the ../build.xml file. -->\r
1288     </target>\r
1289     <target depends="init,deps-jar,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single">\r
1290         <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>\r
1291         <j2seproject3:force-recompile destdir="${build.test.classes.dir}"/>\r
1292         <j2seproject3:javac apgeneratedsrcdir="${build.test.classes.dir}" classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" processorpath="${javac.test.processorpath}" sourcepath="${test.src.dir}" srcdir="${test.src.dir}"/>\r
1293         <copy todir="${build.test.classes.dir}">\r
1294             <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>\r
1295         </copy>\r
1296     </target>\r
1297     <target name="-post-compile-test-single">\r
1298         <!-- Empty placeholder for easier customization. -->\r
1299         <!-- You can override this target in the ../build.xml file. -->\r
1300     </target>\r
1301     <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/>\r
1302     <!--\r
1303                 =======================\r
1304                 TEST EXECUTION SECTION\r
1305                 =======================\r
1306             -->\r
1307     <target depends="init" if="have.tests" name="-pre-test-run">\r
1308         <mkdir dir="${build.test.results.dir}"/>\r
1309     </target>\r
1310     <target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">\r
1311         <j2seproject3:test includes="${includes}" testincludes="**/*Test.java"/>\r
1312     </target>\r
1313     <target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">\r
1314         <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>\r
1315     </target>\r
1316     <target depends="init" if="have.tests" name="test-report"/>\r
1317     <target depends="init" if="netbeans.home+have.tests" name="-test-browse"/>\r
1318     <target depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests." name="test"/>\r
1319     <target depends="init" if="have.tests" name="-pre-test-run-single">\r
1320         <mkdir dir="${build.test.results.dir}"/>\r
1321     </target>\r
1322     <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">\r
1323         <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>\r
1324         <j2seproject3:test excludes="" includes="${test.includes}" testincludes="${test.includes}"/>\r
1325     </target>\r
1326     <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">\r
1327         <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>\r
1328     </target>\r
1329     <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/>\r
1330     <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single-method">\r
1331         <fail unless="test.class">Must select some files in the IDE or set test.class</fail>\r
1332         <fail unless="test.method">Must select some method in the IDE or set test.method</fail>\r
1333         <j2seproject3:test excludes="" includes="${javac.includes}" testincludes="${test.class}" testmethods="${test.method}"/>\r
1334     </target>\r
1335     <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single-method" if="have.tests" name="-post-test-run-single-method">\r
1336         <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>\r
1337     </target>\r
1338     <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single-method,-post-test-run-single-method" description="Run single unit test." name="test-single-method"/>\r
1339     <!--\r
1340                 =======================\r
1341                 TEST DEBUGGING SECTION\r
1342                 =======================\r
1343             -->\r
1344     <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-debug-start-debuggee-test">\r
1345         <fail unless="test.class">Must select one file in the IDE or set test.class</fail>\r
1346         <j2seproject3:test-debug excludes="" includes="${javac.includes}" testClass="${test.class}" testincludes="${javac.includes}"/>\r
1347     </target>\r
1348     <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-debug-start-debuggee-test-method">\r
1349         <fail unless="test.class">Must select one file in the IDE or set test.class</fail>\r
1350         <fail unless="test.method">Must select some method in the IDE or set test.method</fail>\r
1351         <j2seproject3:test-debug excludes="" includes="${javac.includes}" testClass="${test.class}" testMethod="${test.method}" testincludes="${test.class}" testmethods="${test.method}"/>\r
1352     </target>\r
1353     <target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">\r
1354         <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>\r
1355     </target>\r
1356     <target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>\r
1357     <target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test-method" name="debug-test-method"/>\r
1358     <target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">\r
1359         <j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/>\r
1360     </target>\r
1361     <target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/>\r
1362     <!--\r
1363                 =========================\r
1364                 APPLET EXECUTION SECTION\r
1365                 =========================\r
1366             -->\r
1367     <target depends="init,compile-single" name="run-applet">\r
1368         <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>\r
1369         <j2seproject1:java classname="sun.applet.AppletViewer">\r
1370             <customize>\r
1371                 <arg value="${applet.url}"/>\r
1372             </customize>\r
1373         </j2seproject1:java>\r
1374     </target>\r
1375     <!--\r
1376                 =========================\r
1377                 APPLET DEBUGGING  SECTION\r
1378                 =========================\r
1379             -->\r
1380     <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-applet">\r
1381         <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>\r
1382         <j2seproject3:debug classname="sun.applet.AppletViewer">\r
1383             <customize>\r
1384                 <arg value="${applet.url}"/>\r
1385             </customize>\r
1386         </j2seproject3:debug>\r
1387     </target>\r
1388     <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-applet" if="netbeans.home" name="debug-applet"/>\r
1389     <!--\r
1390                 ===============\r
1391                 CLEANUP SECTION\r
1392                 ===============\r
1393             -->\r
1394     <target name="-deps-clean-init" unless="built-clean.properties">\r
1395         <property location="${build.dir}/built-clean.properties" name="built-clean.properties"/>\r
1396         <delete file="${built-clean.properties}" quiet="true"/>\r
1397     </target>\r
1398     <target if="already.built.clean.${basedir}" name="-warn-already-built-clean">\r
1399         <echo level="warn" message="Cycle detected: jcore was already built"/>\r
1400     </target>\r
1401     <target depends="init,-deps-clean-init" name="deps-clean" unless="no.deps">\r
1402         <mkdir dir="${build.dir}"/>\r
1403         <touch file="${built-clean.properties}" verbose="false"/>\r
1404         <property file="${built-clean.properties}" prefix="already.built.clean."/>\r
1405         <antcall target="-warn-already-built-clean"/>\r
1406         <propertyfile file="${built-clean.properties}">\r
1407             <entry key="${basedir}" value=""/>\r
1408         </propertyfile>\r
1409     </target>\r
1410     <target depends="init" name="-do-clean">\r
1411         <delete dir="${build.dir}"/>\r
1412         <delete dir="${dist.dir}" followsymlinks="false" includeemptydirs="true"/>\r
1413     </target>\r
1414     <target name="-post-clean">\r
1415         <!-- Empty placeholder for easier customization. -->\r
1416         <!-- You can override this target in the ../build.xml file. -->\r
1417     </target>\r
1418     <target depends="init,deps-clean,-do-clean,-post-clean" description="Clean build products." name="clean"/>\r
1419     <target name="-check-call-dep">\r
1420         <property file="${call.built.properties}" prefix="already.built."/>\r
1421         <condition property="should.call.dep">\r
1422             <and>\r
1423                 <not>\r
1424                     <isset property="already.built.${call.subproject}"/>\r
1425                 </not>\r
1426                 <available file="${call.script}"/>\r
1427             </and>\r
1428         </condition>\r
1429     </target>\r
1430     <target depends="-check-call-dep" if="should.call.dep" name="-maybe-call-dep">\r
1431         <ant antfile="${call.script}" inheritall="false" target="${call.target}">\r
1432             <propertyset>\r
1433                 <propertyref prefix="transfer."/>\r
1434                 <mapper from="transfer.*" to="*" type="glob"/>\r
1435             </propertyset>\r
1436         </ant>\r
1437     </target>\r
1438 </project>\r