OSDN Git Service

4ebb80e2bc93fe328face5192a2a6ba92bafab49
[coroid/NicoBrowser.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   - junit compilation\r
16   - junit execution\r
17   - junit 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="NicoBrowser-impl">\r
23     <import file="jnlp-impl.xml"/>\r
24     <import file="groovy-build.xml"/>\r
25     <fail message="Please build using Ant 1.7.1 or higher.">\r
26         <condition>\r
27             <not>\r
28                 <antversion atleast="1.7.1"/>\r
29             </not>\r
30         </condition>\r
31     </fail>\r
32     <target depends="test,jar,javadoc" description="Build and test whole project." name="default"/>\r
33     <!-- \r
34                 ======================\r
35                 INITIALIZATION SECTION \r
36                 ======================\r
37             -->\r
38     <target name="-pre-init">\r
39         <!-- Empty placeholder for easier customization. -->\r
40         <!-- You can override this target in the ../build.xml file. -->\r
41     </target>\r
42     <target depends="-pre-init" name="-init-private">\r
43         <property file="nbproject/private/config.properties"/>\r
44         <property file="nbproject/private/configs/${config}.properties"/>\r
45         <property file="nbproject/private/private.properties"/>\r
46     </target>\r
47     <target depends="-pre-init,-init-private" name="-init-user">\r
48         <property file="${user.properties.file}"/>\r
49         <!-- The two properties below are usually overridden -->\r
50         <!-- by the active platform. Just a fallback. -->\r
51         <property name="default.javac.source" value="1.4"/>\r
52         <property name="default.javac.target" value="1.4"/>\r
53     </target>\r
54     <target depends="-pre-init,-init-private,-init-user" name="-init-project">\r
55         <property file="nbproject/configs/${config}.properties"/>\r
56         <property file="nbproject/project.properties"/>\r
57     </target>\r
58     <target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init">\r
59         <available file="${manifest.file}" property="manifest.available"/>\r
60         <condition property="main.class.available">\r
61             <and>\r
62                 <isset property="main.class"/>\r
63                 <not>\r
64                     <equals arg1="${main.class}" arg2="" trim="true"/>\r
65                 </not>\r
66             </and>\r
67         </condition>\r
68         <condition property="manifest.available+main.class">\r
69             <and>\r
70                 <isset property="manifest.available"/>\r
71                 <isset property="main.class.available"/>\r
72             </and>\r
73         </condition>\r
74         <condition property="do.mkdist">\r
75             <and>\r
76                 <isset property="libs.CopyLibs.classpath"/>\r
77                 <not>\r
78                     <istrue value="${mkdist.disabled}"/>\r
79                 </not>\r
80             </and>\r
81         </condition>\r
82         <condition property="manifest.available+main.class+mkdist.available">\r
83             <and>\r
84                 <istrue value="${manifest.available+main.class}"/>\r
85                 <isset property="do.mkdist"/>\r
86             </and>\r
87         </condition>\r
88         <condition property="manifest.available+mkdist.available">\r
89             <and>\r
90                 <istrue value="${manifest.available}"/>\r
91                 <isset property="do.mkdist"/>\r
92             </and>\r
93         </condition>\r
94         <condition property="manifest.available-mkdist.available">\r
95             <or>\r
96                 <istrue value="${manifest.available}"/>\r
97                 <isset property="do.mkdist"/>\r
98             </or>\r
99         </condition>\r
100         <condition property="manifest.available+main.class-mkdist.available">\r
101             <or>\r
102                 <istrue value="${manifest.available+main.class}"/>\r
103                 <isset property="do.mkdist"/>\r
104             </or>\r
105         </condition>\r
106         <condition property="have.tests">\r
107             <or>\r
108                 <available file="${test.src.dir}"/>\r
109             </or>\r
110         </condition>\r
111         <condition property="have.sources">\r
112             <or>\r
113                 <available file="${src.dir}"/>\r
114             </or>\r
115         </condition>\r
116         <condition property="netbeans.home+have.tests">\r
117             <and>\r
118                 <isset property="netbeans.home"/>\r
119                 <isset property="have.tests"/>\r
120             </and>\r
121         </condition>\r
122         <condition property="no.javadoc.preview">\r
123             <and>\r
124                 <isset property="javadoc.preview"/>\r
125                 <isfalse value="${javadoc.preview}"/>\r
126             </and>\r
127         </condition>\r
128         <property name="run.jvmargs" value=""/>\r
129         <property name="javac.compilerargs" value=""/>\r
130         <property name="work.dir" value="${basedir}"/>\r
131         <condition property="no.deps">\r
132             <and>\r
133                 <istrue value="${no.dependencies}"/>\r
134             </and>\r
135         </condition>\r
136         <property name="javac.debug" value="true"/>\r
137         <property name="javadoc.preview" value="true"/>\r
138         <property name="application.args" value=""/>\r
139         <property name="source.encoding" value="${file.encoding}"/>\r
140         <property name="runtime.encoding" value="${source.encoding}"/>\r
141         <condition property="javadoc.encoding.used" value="${javadoc.encoding}">\r
142             <and>\r
143                 <isset property="javadoc.encoding"/>\r
144                 <not>\r
145                     <equals arg1="${javadoc.encoding}" arg2=""/>\r
146                 </not>\r
147             </and>\r
148         </condition>\r
149         <property name="javadoc.encoding.used" value="${source.encoding}"/>\r
150         <property name="includes" value="**"/>\r
151         <property name="excludes" value=""/>\r
152         <property name="do.depend" value="false"/>\r
153         <condition property="do.depend.true">\r
154             <istrue value="${do.depend}"/>\r
155         </condition>\r
156         <path id="endorsed.classpath.path" path="${endorsed.classpath}"/>\r
157         <condition else="" property="endorsed.classpath.cmd.line.arg" value="-Xbootclasspath/p:'${toString:endorsed.classpath.path}'">\r
158             <length length="0" string="${endorsed.classpath}" when="greater"/>\r
159         </condition>\r
160         <property name="javac.fork" value="false"/>\r
161     </target>\r
162     <target name="-post-init">\r
163         <!-- Empty placeholder for easier customization. -->\r
164         <!-- You can override this target in the ../build.xml file. -->\r
165     </target>\r
166     <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check">\r
167         <fail unless="src.dir">Must set src.dir</fail>\r
168         <fail unless="test.src.dir">Must set test.src.dir</fail>\r
169         <fail unless="build.dir">Must set build.dir</fail>\r
170         <fail unless="dist.dir">Must set dist.dir</fail>\r
171         <fail unless="build.classes.dir">Must set build.classes.dir</fail>\r
172         <fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail>\r
173         <fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail>\r
174         <fail unless="build.test.results.dir">Must set build.test.results.dir</fail>\r
175         <fail unless="build.classes.excludes">Must set build.classes.excludes</fail>\r
176         <fail unless="dist.jar">Must set dist.jar</fail>\r
177     </target>\r
178     <target name="-init-macrodef-property">\r
179         <macrodef name="property" uri="http://www.netbeans.org/ns/j2se-project/1">\r
180             <attribute name="name"/>\r
181             <attribute name="value"/>\r
182             <sequential>\r
183                 <property name="@{name}" value="${@{value}}"/>\r
184             </sequential>\r
185         </macrodef>\r
186     </target>\r
187     <target name="-init-macrodef-javac">\r
188         <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">\r
189             <attribute default="${src.dir}" name="srcdir"/>\r
190             <attribute default="${build.classes.dir}" name="destdir"/>\r
191             <attribute default="${javac.classpath}" name="classpath"/>\r
192             <attribute default="${includes}" name="includes"/>\r
193             <attribute default="${excludes}" name="excludes"/>\r
194             <attribute default="${javac.debug}" name="debug"/>\r
195             <attribute default="${empty.dir}" name="sourcepath"/>\r
196             <attribute default="${empty.dir}" name="gensrcdir"/>\r
197             <element name="customize" optional="true"/>\r
198             <sequential>\r
199                 <property location="${build.dir}/empty" name="empty.dir"/>\r
200                 <mkdir dir="${empty.dir}"/>\r
201                 <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
202                     <src>\r
203                         <dirset dir="@{gensrcdir}" erroronmissingdir="false">\r
204                             <include name="*"/>\r
205                         </dirset>\r
206                     </src>\r
207                     <classpath>\r
208                         <path path="@{classpath}"/>\r
209                     </classpath>\r
210                     <compilerarg line="${endorsed.classpath.cmd.line.arg}"/>\r
211                     <compilerarg line="${javac.compilerargs}"/>\r
212                     <customize/>\r
213                 </javac>\r
214             </sequential>\r
215         </macrodef>\r
216         <macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3">\r
217             <attribute default="${src.dir}" name="srcdir"/>\r
218             <attribute default="${build.classes.dir}" name="destdir"/>\r
219             <attribute default="${javac.classpath}" name="classpath"/>\r
220             <sequential>\r
221                 <depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}">\r
222                     <classpath>\r
223                         <path path="@{classpath}"/>\r
224                     </classpath>\r
225                 </depend>\r
226             </sequential>\r
227         </macrodef>\r
228         <macrodef name="force-recompile" uri="http://www.netbeans.org/ns/j2se-project/3">\r
229             <attribute default="${build.classes.dir}" name="destdir"/>\r
230             <sequential>\r
231                 <fail unless="javac.includes">Must set javac.includes</fail>\r
232                 <pathconvert pathsep="," property="javac.includes.binary">\r
233                     <path>\r
234                         <filelist dir="@{destdir}" files="${javac.includes}"/>\r
235                     </path>\r
236                     <globmapper from="*.java" to="*.class"/>\r
237                 </pathconvert>\r
238                 <delete>\r
239                     <files includes="${javac.includes.binary}"/>\r
240                 </delete>\r
241             </sequential>\r
242         </macrodef>\r
243     </target>\r
244     <target name="-init-macrodef-junit">\r
245         <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">\r
246             <attribute default="${includes}" name="includes"/>\r
247             <attribute default="${excludes}" name="excludes"/>\r
248             <attribute default="**" name="testincludes"/>\r
249             <sequential>\r
250                 <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true" tempdir="${build.dir}">\r
251                     <batchtest todir="${build.test.results.dir}">\r
252                         <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">\r
253                             <filename name="@{testincludes}"/>\r
254                         </fileset>\r
255                     </batchtest>\r
256                     <classpath>\r
257                         <path path="${run.test.classpath}"/>\r
258                     </classpath>\r
259                     <syspropertyset>\r
260                         <propertyref prefix="test-sys-prop."/>\r
261                         <mapper from="test-sys-prop.*" to="*" type="glob"/>\r
262                     </syspropertyset>\r
263                     <formatter type="brief" usefile="false"/>\r
264                     <formatter type="xml"/>\r
265                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>\r
266                     <jvmarg line="${run.jvmargs}"/>\r
267                 </junit>\r
268             </sequential>\r
269         </macrodef>\r
270     </target>\r
271     <target depends="-init-debug-args" name="-init-macrodef-nbjpda">\r
272         <macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1">\r
273             <attribute default="${main.class}" name="name"/>\r
274             <attribute default="${debug.classpath}" name="classpath"/>\r
275             <attribute default="" name="stopclassname"/>\r
276             <sequential>\r
277                 <nbjpdastart addressproperty="jpda.address" name="@{name}" stopclassname="@{stopclassname}" transport="${debug-transport}">\r
278                     <classpath>\r
279                         <path path="@{classpath}"/>\r
280                     </classpath>\r
281                 </nbjpdastart>\r
282             </sequential>\r
283         </macrodef>\r
284         <macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/j2se-project/1">\r
285             <attribute default="${build.classes.dir}" name="dir"/>\r
286             <sequential>\r
287                 <nbjpdareload>\r
288                     <fileset dir="@{dir}" includes="${fix.classes}">\r
289                         <include name="${fix.includes}*.class"/>\r
290                     </fileset>\r
291                 </nbjpdareload>\r
292             </sequential>\r
293         </macrodef>\r
294     </target>\r
295     <target name="-init-debug-args">\r
296         <property name="version-output" value="java version &quot;${ant.java.version}"/>\r
297         <condition property="have-jdk-older-than-1.4">\r
298             <or>\r
299                 <contains string="${version-output}" substring="java version &quot;1.0"/>\r
300                 <contains string="${version-output}" substring="java version &quot;1.1"/>\r
301                 <contains string="${version-output}" substring="java version &quot;1.2"/>\r
302                 <contains string="${version-output}" substring="java version &quot;1.3"/>\r
303             </or>\r
304         </condition>\r
305         <condition else="-Xdebug" property="debug-args-line" value="-Xdebug -Xnoagent -Djava.compiler=none">\r
306             <istrue value="${have-jdk-older-than-1.4}"/>\r
307         </condition>\r
308         <condition else="dt_socket" property="debug-transport-by-os" value="dt_shmem">\r
309             <os family="windows"/>\r
310         </condition>\r
311         <condition else="${debug-transport-by-os}" property="debug-transport" value="${debug.transport}">\r
312             <isset property="debug.transport"/>\r
313         </condition>\r
314     </target>\r
315     <target depends="-init-debug-args" name="-init-macrodef-debug">\r
316         <macrodef name="debug" uri="http://www.netbeans.org/ns/j2se-project/3">\r
317             <attribute default="${main.class}" name="classname"/>\r
318             <attribute default="${debug.classpath}" name="classpath"/>\r
319             <element name="customize" optional="true"/>\r
320             <sequential>\r
321                 <java classname="@{classname}" dir="${work.dir}" fork="true">\r
322                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>\r
323                     <jvmarg line="${debug-args-line}"/>\r
324                     <jvmarg value="-Xrunjdwp:transport=${debug-transport},address=${jpda.address}"/>\r
325                     <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>\r
326                     <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>\r
327                     <jvmarg line="${run.jvmargs}"/>\r
328                     <classpath>\r
329                         <path path="@{classpath}"/>\r
330                     </classpath>\r
331                     <syspropertyset>\r
332                         <propertyref prefix="run-sys-prop."/>\r
333                         <mapper from="run-sys-prop.*" to="*" type="glob"/>\r
334                     </syspropertyset>\r
335                     <customize/>\r
336                 </java>\r
337             </sequential>\r
338         </macrodef>\r
339     </target>\r
340     <target name="-init-macrodef-java">\r
341         <macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1">\r
342             <attribute default="${main.class}" name="classname"/>\r
343             <attribute default="${run.classpath}" name="classpath"/>\r
344             <element name="customize" optional="true"/>\r
345             <sequential>\r
346                 <java classname="@{classname}" dir="${work.dir}" fork="true">\r
347                     <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>\r
348                     <jvmarg value="-Dfile.encoding=${runtime.encoding}"/>\r
349                     <redirector errorencoding="${runtime.encoding}" inputencoding="${runtime.encoding}" outputencoding="${runtime.encoding}"/>\r
350                     <jvmarg line="${run.jvmargs}"/>\r
351                     <classpath>\r
352                         <path path="@{classpath}"/>\r
353                     </classpath>\r
354                     <syspropertyset>\r
355                         <propertyref prefix="run-sys-prop."/>\r
356                         <mapper from="run-sys-prop.*" to="*" type="glob"/>\r
357                     </syspropertyset>\r
358                     <customize/>\r
359                 </java>\r
360             </sequential>\r
361         </macrodef>\r
362     </target>\r
363     <target name="-init-presetdef-jar">\r
364         <presetdef name="jar" uri="http://www.netbeans.org/ns/j2se-project/1">\r
365             <jar compress="${jar.compress}" jarfile="${dist.jar}">\r
366                 <j2seproject1:fileset dir="${build.classes.dir}"/>\r
367             </jar>\r
368         </presetdef>\r
369     </target>\r
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-junit,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar" name="init"/>\r
371     <!--\r
372                 ===================\r
373                 COMPILATION SECTION\r
374                 ===================\r
375             -->\r
376     <target name="-deps-jar-init" unless="built-jar.properties">\r
377         <property location="${build.dir}/built-jar.properties" name="built-jar.properties"/>\r
378         <delete file="${built-jar.properties}" quiet="true"/>\r
379     </target>\r
380     <target if="already.built.jar.${basedir}" name="-warn-already-built-jar">\r
381         <echo level="warn" message="Cycle detected: NicoBrowser was already built"/>\r
382     </target>\r
383     <target depends="init,-deps-jar-init" name="deps-jar" unless="no.deps">\r
384         <mkdir dir="${build.dir}"/>\r
385         <touch file="${built-jar.properties}" verbose="false"/>\r
386         <property file="${built-jar.properties}" prefix="already.built.jar."/>\r
387         <antcall target="-warn-already-built-jar"/>\r
388         <propertyfile file="${built-jar.properties}">\r
389             <entry key="${basedir}" value=""/>\r
390         </propertyfile>\r
391     </target>\r
392     <target depends="init,-check-automatic-build,-clean-after-automatic-build" name="-verify-automatic-build"/>\r
393     <target depends="init" name="-check-automatic-build">\r
394         <available file="${build.classes.dir}/.netbeans_automatic_build" property="netbeans.automatic.build"/>\r
395     </target>\r
396     <target depends="init" if="netbeans.automatic.build" name="-clean-after-automatic-build">\r
397         <antcall target="clean"/>\r
398     </target>\r
399     <target depends="init,deps-jar,-groovy-init-macrodef-javac" name="-pre-pre-compile">\r
400         <mkdir dir="${build.classes.dir}"/>\r
401     </target>\r
402     <target name="-pre-compile">\r
403         <!-- Empty placeholder for easier customization. -->\r
404         <!-- You can override this target in the ../build.xml file. -->\r
405     </target>\r
406     <target if="do.depend.true" name="-compile-depend">\r
407         <pathconvert property="build.generated.subdirs">\r
408             <dirset dir="${build.generated.sources.dir}" erroronmissingdir="false">\r
409                 <include name="*"/>\r
410             </dirset>\r
411         </pathconvert>\r
412         <j2seproject3:depend srcdir="${src.dir}:${build.generated.subdirs}"/>\r
413     </target>\r
414     <target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-compile-depend" if="have.sources" name="-do-compile">\r
415         <j2seproject3:javac gensrcdir="${build.generated.sources.dir}"/>\r
416         <copy todir="${build.classes.dir}">\r
417             <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>\r
418         </copy>\r
419     </target>\r
420     <target name="-post-compile">\r
421         <!-- Empty placeholder for easier customization. -->\r
422         <!-- You can override this target in the ../build.xml file. -->\r
423     </target>\r
424     <target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/>\r
425     <target name="-pre-compile-single">\r
426         <!-- Empty placeholder for easier customization. -->\r
427         <!-- You can override this target in the ../build.xml file. -->\r
428     </target>\r
429     <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">\r
430         <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>\r
431         <j2seproject3:force-recompile/>\r
432         <j2seproject3:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}" sourcepath="${src.dir}"/>\r
433     </target>\r
434     <target name="-post-compile-single">\r
435         <!-- Empty placeholder for easier customization. -->\r
436         <!-- You can override this target in the ../build.xml file. -->\r
437     </target>\r
438     <target depends="init,deps-jar,-verify-automatic-build,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/>\r
439     <!--\r
440                 ====================\r
441                 JAR BUILDING SECTION\r
442                 ====================\r
443             -->\r
444     <target depends="init" name="-pre-pre-jar">\r
445         <dirname file="${dist.jar}" property="dist.jar.dir"/>\r
446         <mkdir dir="${dist.jar.dir}"/>\r
447     </target>\r
448     <target name="-pre-jar">\r
449         <!-- Empty placeholder for easier customization. -->\r
450         <!-- You can override this target in the ../build.xml file. -->\r
451     </target>\r
452     <target depends="init,compile,-pre-pre-jar,-pre-jar" name="-do-jar-without-manifest" unless="manifest.available-mkdist.available">\r
453         <j2seproject1:jar/>\r
454     </target>\r
455     <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available" name="-do-jar-with-manifest" unless="manifest.available+main.class-mkdist.available">\r
456         <j2seproject1:jar manifest="${manifest.file}"/>\r
457     </target>\r
458     <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">\r
459         <j2seproject1:jar manifest="${manifest.file}">\r
460             <j2seproject1:manifest>\r
461                 <j2seproject1:attribute name="Main-Class" value="${main.class}"/>\r
462             </j2seproject1:manifest>\r
463         </j2seproject1:jar>\r
464         <echo>To run this application from the command line without Ant, try:</echo>\r
465         <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>\r
466         <property location="${dist.jar}" name="dist.jar.resolved"/>\r
467         <pathconvert property="run.classpath.with.dist.jar">\r
468             <path path="${run.classpath}"/>\r
469             <map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>\r
470         </pathconvert>\r
471         <echo>java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>\r
472     </target>\r
473     <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class+mkdist.available" name="-do-jar-with-libraries">\r
474         <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>\r
475         <pathconvert property="run.classpath.without.build.classes.dir">\r
476             <path path="${run.classpath}"/>\r
477             <map from="${build.classes.dir.resolved}" to=""/>\r
478         </pathconvert>\r
479         <pathconvert pathsep=" " property="jar.classpath">\r
480             <path path="${run.classpath.without.build.classes.dir}"/>\r
481             <chainedmapper>\r
482                 <flattenmapper/>\r
483                 <globmapper from="*" to="lib/*"/>\r
484             </chainedmapper>\r
485         </pathconvert>\r
486         <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>\r
487         <copylibs compress="${jar.compress}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}">\r
488             <fileset dir="${build.classes.dir}"/>\r
489             <manifest>\r
490                 <attribute name="Main-Class" value="${main.class}"/>\r
491                 <attribute name="Class-Path" value="${jar.classpath}"/>\r
492             </manifest>\r
493         </copylibs>\r
494         <echo>To run this application from the command line without Ant, try:</echo>\r
495         <property location="${dist.jar}" name="dist.jar.resolved"/>\r
496         <echo>java -jar "${dist.jar.resolved}"</echo>\r
497     </target>\r
498     <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+mkdist.available" name="-do-jar-with-libraries-without-mainclass" unless="main.class.available">\r
499         <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>\r
500         <pathconvert property="run.classpath.without.build.classes.dir">\r
501             <path path="${run.classpath}"/>\r
502             <map from="${build.classes.dir.resolved}" to=""/>\r
503         </pathconvert>\r
504         <pathconvert pathsep=" " property="jar.classpath">\r
505             <path path="${run.classpath.without.build.classes.dir}"/>\r
506             <chainedmapper>\r
507                 <flattenmapper/>\r
508                 <globmapper from="*" to="lib/*"/>\r
509             </chainedmapper>\r
510         </pathconvert>\r
511         <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>\r
512         <copylibs compress="${jar.compress}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}">\r
513             <fileset dir="${build.classes.dir}"/>\r
514             <manifest>\r
515                 <attribute name="Class-Path" value="${jar.classpath}"/>\r
516             </manifest>\r
517         </copylibs>\r
518     </target>\r
519     <target depends="init,compile,-pre-pre-jar,-pre-jar" if="do.mkdist" name="-do-jar-with-libraries-without-manifest" unless="manifest.available">\r
520         <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>\r
521         <pathconvert property="run.classpath.without.build.classes.dir">\r
522             <path path="${run.classpath}"/>\r
523             <map from="${build.classes.dir.resolved}" to=""/>\r
524         </pathconvert>\r
525         <pathconvert pathsep=" " property="jar.classpath">\r
526             <path path="${run.classpath.without.build.classes.dir}"/>\r
527             <chainedmapper>\r
528                 <flattenmapper/>\r
529                 <globmapper from="*" to="lib/*"/>\r
530             </chainedmapper>\r
531         </pathconvert>\r
532         <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>\r
533         <copylibs compress="${jar.compress}" jarfile="${dist.jar}" runtimeclasspath="${run.classpath.without.build.classes.dir}">\r
534             <fileset dir="${build.classes.dir}"/>\r
535             <manifest>\r
536                 <attribute name="Class-Path" value="${jar.classpath}"/>\r
537             </manifest>\r
538         </copylibs>\r
539     </target>\r
540     <target name="-post-jar">\r
541         <!-- Empty placeholder for easier customization. -->\r
542         <!-- You can override this target in the ../build.xml file. -->\r
543     </target>\r
544     <target depends="init,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-do-jar-with-libraries-without-mainclass,-do-jar-with-libraries-without-manifest,-post-jar,jnlp" description="Build JAR." name="jar"/>\r
545     <!--\r
546                 =================\r
547                 EXECUTION SECTION\r
548                 =================\r
549             -->\r
550     <target depends="init,compile" description="Run a main class." name="run">\r
551         <j2seproject1:java>\r
552             <customize>\r
553                 <arg line="${application.args}"/>\r
554             </customize>\r
555         </j2seproject1:java>\r
556     </target>\r
557     <target name="-do-not-recompile">\r
558         <property name="javac.includes.binary" value=""/>\r
559     </target>\r
560     <target depends="init,compile-single" name="run-single">\r
561         <fail unless="run.class">Must select one file in the IDE or set run.class</fail>\r
562         <j2seproject1:java classname="${run.class}"/>\r
563     </target>\r
564     <target depends="init,compile-test-single" name="run-test-with-main">\r
565         <fail unless="run.class">Must select one file in the IDE or set run.class</fail>\r
566         <j2seproject1:java classname="${run.class}" classpath="${run.test.classpath}"/>\r
567     </target>\r
568     <!--\r
569                 =================\r
570                 DEBUGGING SECTION\r
571                 =================\r
572             -->\r
573     <target depends="init" if="netbeans.home" name="-debug-start-debugger">\r
574         <j2seproject1:nbjpdastart name="${debug.class}"/>\r
575     </target>\r
576     <target depends="init" if="netbeans.home" name="-debug-start-debugger-main-test">\r
577         <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${debug.class}"/>\r
578     </target>\r
579     <target depends="init,compile" name="-debug-start-debuggee">\r
580         <j2seproject3:debug>\r
581             <customize>\r
582                 <arg line="${application.args}"/>\r
583             </customize>\r
584         </j2seproject3:debug>\r
585     </target>\r
586     <target depends="init,compile,-debug-start-debugger,-debug-start-debuggee" description="Debug project in IDE." if="netbeans.home" name="debug"/>\r
587     <target depends="init" if="netbeans.home" name="-debug-start-debugger-stepinto">\r
588         <j2seproject1:nbjpdastart stopclassname="${main.class}"/>\r
589     </target>\r
590     <target depends="init,compile,-debug-start-debugger-stepinto,-debug-start-debuggee" if="netbeans.home" name="debug-stepinto"/>\r
591     <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single">\r
592         <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>\r
593         <j2seproject3:debug classname="${debug.class}"/>\r
594     </target>\r
595     <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single"/>\r
596     <target depends="init,compile-test-single" if="netbeans.home" name="-debug-start-debuggee-main-test">\r
597         <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>\r
598         <j2seproject3:debug classname="${debug.class}" classpath="${debug.test.classpath}"/>\r
599     </target>\r
600     <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
601     <target depends="init" name="-pre-debug-fix">\r
602         <fail unless="fix.includes">Must set fix.includes</fail>\r
603         <property name="javac.includes" value="${fix.includes}.java"/>\r
604     </target>\r
605     <target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix">\r
606         <j2seproject1:nbjpdareload/>\r
607     </target>\r
608     <target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/>\r
609     <!--\r
610                 ===============\r
611                 JAVADOC SECTION\r
612                 ===============\r
613             -->\r
614     <target depends="init" name="-javadoc-build">\r
615         <mkdir dir="${dist.javadoc.dir}"/>\r
616         <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}">\r
617             <classpath>\r
618                 <path path="${javac.classpath}"/>\r
619             </classpath>\r
620             <fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">\r
621                 <filename name="**/*.java"/>\r
622             </fileset>\r
623             <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">\r
624                 <include name="**/*.java"/>\r
625             </fileset>\r
626         </javadoc>\r
627     </target>\r
628     <target depends="init,-javadoc-build" if="netbeans.home" name="-javadoc-browse" unless="no.javadoc.preview">\r
629         <nbbrowse file="${dist.javadoc.dir}/index.html"/>\r
630     </target>\r
631     <target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/>\r
632     <!--\r
633                 =========================\r
634                 JUNIT COMPILATION SECTION\r
635                 =========================\r
636             -->\r
637     <target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">\r
638         <mkdir dir="${build.test.classes.dir}"/>\r
639     </target>\r
640     <target name="-pre-compile-test">\r
641         <!-- Empty placeholder for easier customization. -->\r
642         <!-- You can override this target in the ../build.xml file. -->\r
643     </target>\r
644     <target if="do.depend.true" name="-compile-test-depend">\r
645         <j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>\r
646     </target>\r
647     <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test">\r
648         <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>\r
649         <copy todir="${build.test.classes.dir}">\r
650             <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>\r
651         </copy>\r
652     </target>\r
653     <target name="-post-compile-test">\r
654         <!-- Empty placeholder for easier customization. -->\r
655         <!-- You can override this target in the ../build.xml file. -->\r
656     </target>\r
657     <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/>\r
658     <target name="-pre-compile-test-single">\r
659         <!-- Empty placeholder for easier customization. -->\r
660         <!-- You can override this target in the ../build.xml file. -->\r
661     </target>\r
662     <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single">\r
663         <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>\r
664         <j2seproject3:force-recompile destdir="${build.test.classes.dir}"/>\r
665         <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" sourcepath="${test.src.dir}" srcdir="${test.src.dir}"/>\r
666         <copy todir="${build.test.classes.dir}">\r
667             <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>\r
668         </copy>\r
669     </target>\r
670     <target name="-post-compile-test-single">\r
671         <!-- Empty placeholder for easier customization. -->\r
672         <!-- You can override this target in the ../build.xml file. -->\r
673     </target>\r
674     <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
675     <!--\r
676                 =======================\r
677                 JUNIT EXECUTION SECTION\r
678                 =======================\r
679             -->\r
680     <target depends="init" if="have.tests" name="-pre-test-run">\r
681         <mkdir dir="${build.test.results.dir}"/>\r
682     </target>\r
683     <target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">\r
684         <j2seproject3:junit testincludes="**/*Test.java"/>\r
685     </target>\r
686     <target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">\r
687         <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>\r
688     </target>\r
689     <target depends="init" if="have.tests" name="test-report"/>\r
690     <target depends="init" if="netbeans.home+have.tests" name="-test-browse"/>\r
691     <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
692     <target depends="init" if="have.tests" name="-pre-test-run-single">\r
693         <mkdir dir="${build.test.results.dir}"/>\r
694     </target>\r
695     <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">\r
696         <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>\r
697         <j2seproject3:junit excludes="" includes="${test.includes}"/>\r
698     </target>\r
699     <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">\r
700         <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>\r
701     </target>\r
702     <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
703     <!--\r
704                 =======================\r
705                 JUNIT DEBUGGING SECTION\r
706                 =======================\r
707             -->\r
708     <target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test">\r
709         <fail unless="test.class">Must select one file in the IDE or set test.class</fail>\r
710         <property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/>\r
711         <delete file="${test.report.file}"/>\r
712         <mkdir dir="${build.test.results.dir}"/>\r
713         <j2seproject3: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}">\r
714             <customize>\r
715                 <syspropertyset>\r
716                     <propertyref prefix="test-sys-prop."/>\r
717                     <mapper from="test-sys-prop.*" to="*" type="glob"/>\r
718                 </syspropertyset>\r
719                 <arg value="${test.class}"/>\r
720                 <arg value="showoutput=true"/>\r
721                 <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/>\r
722                 <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/>\r
723             </customize>\r
724         </j2seproject3:debug>\r
725     </target>\r
726     <target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">\r
727         <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>\r
728     </target>\r
729     <target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>\r
730     <target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">\r
731         <j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/>\r
732     </target>\r
733     <target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/>\r
734     <!--\r
735                 =========================\r
736                 APPLET EXECUTION SECTION\r
737                 =========================\r
738             -->\r
739     <target depends="init,compile-single" name="run-applet">\r
740         <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>\r
741         <j2seproject1:java classname="sun.applet.AppletViewer">\r
742             <customize>\r
743                 <arg value="${applet.url}"/>\r
744             </customize>\r
745         </j2seproject1:java>\r
746     </target>\r
747     <!--\r
748                 =========================\r
749                 APPLET DEBUGGING  SECTION\r
750                 =========================\r
751             -->\r
752     <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-applet">\r
753         <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>\r
754         <j2seproject3:debug classname="sun.applet.AppletViewer">\r
755             <customize>\r
756                 <arg value="${applet.url}"/>\r
757             </customize>\r
758         </j2seproject3:debug>\r
759     </target>\r
760     <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-applet" if="netbeans.home" name="debug-applet"/>\r
761     <!--\r
762                 ===============\r
763                 CLEANUP SECTION\r
764                 ===============\r
765             -->\r
766     <target name="-deps-clean-init" unless="built-clean.properties">\r
767         <property location="${build.dir}/built-clean.properties" name="built-clean.properties"/>\r
768         <delete file="${built-clean.properties}" quiet="true"/>\r
769     </target>\r
770     <target if="already.built.clean.${basedir}" name="-warn-already-built-clean">\r
771         <echo level="warn" message="Cycle detected: NicoBrowser was already built"/>\r
772     </target>\r
773     <target depends="init,-deps-clean-init" name="deps-clean" unless="no.deps">\r
774         <mkdir dir="${build.dir}"/>\r
775         <touch file="${built-clean.properties}" verbose="false"/>\r
776         <property file="${built-clean.properties}" prefix="already.built.clean."/>\r
777         <antcall target="-warn-already-built-clean"/>\r
778         <propertyfile file="${built-clean.properties}">\r
779             <entry key="${basedir}" value=""/>\r
780         </propertyfile>\r
781     </target>\r
782     <target depends="init" name="-do-clean">\r
783         <delete dir="${build.dir}"/>\r
784         <delete dir="${dist.dir}" followsymlinks="false" includeemptydirs="true"/>\r
785     </target>\r
786     <target name="-post-clean">\r
787         <!-- Empty placeholder for easier customization. -->\r
788         <!-- You can override this target in the ../build.xml file. -->\r
789     </target>\r
790     <target depends="init,deps-clean,-do-clean,-post-clean" description="Clean build products." name="clean"/>\r
791     <target name="-check-call-dep">\r
792         <property file="${call.built.properties}" prefix="already.built."/>\r
793         <condition property="should.call.dep">\r
794             <not>\r
795                 <isset property="already.built.${call.subproject}"/>\r
796             </not>\r
797         </condition>\r
798     </target>\r
799     <target depends="-check-call-dep" if="should.call.dep" name="-maybe-call-dep">\r
800         <ant antfile="${call.script}" inheritall="false" target="${call.target}">\r
801             <propertyset>\r
802                 <propertyref prefix="transfer."/>\r
803                 <mapper from="transfer.*" to="*" type="glob"/>\r
804             </propertyset>\r
805         </ant>\r
806     </target>\r
807 </project>\r