| 1 |
<?xml version="1.0" encoding="UTF-8"?> |
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
<project name="saxon65-impl" default="default" basedir=".." xmlns:j2seproject3="http://www.netbeans.org/ns/j2se-project/3" xmlns:j2seproject2="http://www.netbeans.org/ns/j2se-project/2" xmlns:j2seproject1="http://www.netbeans.org/ns/j2se-project/1"> |
| 23 |
<target name="default" depends="test,jar,javadoc" description="Build and test whole project."/> |
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
<target name="-pre-init"> |
| 30 |
|
| 31 |
|
| 32 |
</target> |
| 33 |
<target name="-init-private" depends="-pre-init"> |
| 34 |
<property file="nbproject/private/private.properties"/> |
| 35 |
</target> |
| 36 |
<target name="-init-user" depends="-pre-init,-init-private"> |
| 37 |
<property file="${user.properties.file}"/> |
| 38 |
|
| 39 |
|
| 40 |
<property name="default.javac.source" value="1.4"/> |
| 41 |
<property name="default.javac.target" value="1.4"/> |
| 42 |
</target> |
| 43 |
<target name="-init-project" depends="-pre-init,-init-private,-init-user"> |
| 44 |
<property file="nbproject/project.properties"/> |
| 45 |
</target> |
| 46 |
<target name="-do-init" depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property"> |
| 47 |
<j2seproject1:property name="platform.home" value="platforms.${platform.active}.home"/> |
| 48 |
<j2seproject1:property name="platform.bootcp" value="platforms.${platform.active}.bootclasspath"/> |
| 49 |
<j2seproject1:property name="platform.compiler" value="platforms.${platform.active}.compile"/> |
| 50 |
<j2seproject1:property name="platform.javac.tmp" value="platforms.${platform.active}.javac"/> |
| 51 |
<condition property="platform.javac" value="${platform.home}/bin/javac"> |
| 52 |
<equals arg1="${platform.javac.tmp}" arg2="$${platforms.${platform.active}.javac}"/> |
| 53 |
</condition> |
| 54 |
<property name="platform.javac" value="${platform.javac.tmp}"/> |
| 55 |
<j2seproject1:property name="platform.java.tmp" value="platforms.${platform.active}.java"/> |
| 56 |
<condition property="platform.java" value="${platform.home}/bin/java"> |
| 57 |
<equals arg1="${platform.java.tmp}" arg2="$${platforms.${platform.active}.java}"/> |
| 58 |
</condition> |
| 59 |
<property name="platform.java" value="${platform.java.tmp}"/> |
| 60 |
<j2seproject1:property name="platform.javadoc.tmp" value="platforms.${platform.active}.javadoc"/> |
| 61 |
<condition property="platform.javadoc" value="${platform.home}/bin/javadoc"> |
| 62 |
<equals arg1="${platform.javadoc.tmp}" arg2="$${platforms.${platform.active}.javadoc}"/> |
| 63 |
</condition> |
| 64 |
<property name="platform.javadoc" value="${platform.javadoc.tmp}"/> |
| 65 |
<condition property="platform.invalid" value="true"> |
| 66 |
<or> |
| 67 |
<contains string="${platform.javac}" substring="$${platforms."/> |
| 68 |
<contains string="${platform.java}" substring="$${platforms."/> |
| 69 |
<contains string="${platform.javadoc}" substring="$${platforms."/> |
| 70 |
</or> |
| 71 |
</condition> |
| 72 |
<fail unless="platform.home">Must set platform.home</fail> |
| 73 |
<fail unless="platform.bootcp">Must set platform.bootcp</fail> |
| 74 |
<fail unless="platform.java">Must set platform.java</fail> |
| 75 |
<fail unless="platform.javac">Must set platform.javac</fail> |
| 76 |
<fail if="platform.invalid">Platform is not correctly set up</fail> |
| 77 |
<available file="${manifest.file}" property="manifest.available"/> |
| 78 |
<condition property="manifest.available+main.class"> |
| 79 |
<and> |
| 80 |
<isset property="manifest.available"/> |
| 81 |
<isset property="main.class"/> |
| 82 |
<not> |
| 83 |
<equals arg1="${main.class}" arg2="" trim="true"/> |
| 84 |
</not> |
| 85 |
</and> |
| 86 |
</condition> |
| 87 |
<condition property="manifest.available+main.class+mkdist.available"> |
| 88 |
<and> |
| 89 |
<istrue value="${manifest.available+main.class}"/> |
| 90 |
<isset property="libs.CopyLibs.classpath"/> |
| 91 |
</and> |
| 92 |
</condition> |
| 93 |
<condition property="have.tests"> |
| 94 |
<or> |
| 95 |
<available file="${test.src.dir}"/> |
| 96 |
</or> |
| 97 |
</condition> |
| 98 |
<condition property="have.sources"> |
| 99 |
<or> |
| 100 |
<available file="${src.dir}"/> |
| 101 |
</or> |
| 102 |
</condition> |
| 103 |
<condition property="netbeans.home+have.tests"> |
| 104 |
<and> |
| 105 |
<isset property="netbeans.home"/> |
| 106 |
<isset property="have.tests"/> |
| 107 |
</and> |
| 108 |
</condition> |
| 109 |
<condition property="no.javadoc.preview"> |
| 110 |
<isfalse value="${javadoc.preview}"/> |
| 111 |
</condition> |
| 112 |
<property name="run.jvmargs" value=""/> |
| 113 |
<property name="javac.compilerargs" value=""/> |
| 114 |
<property name="work.dir" value="${basedir}"/> |
| 115 |
<condition property="no.deps"> |
| 116 |
<and> |
| 117 |
<istrue value="${no.dependencies}"/> |
| 118 |
</and> |
| 119 |
</condition> |
| 120 |
<property name="javac.debug" value="true"/> |
| 121 |
<property name="javadoc.preview" value="true"/> |
| 122 |
</target> |
| 123 |
<target name="-post-init"> |
| 124 |
|
| 125 |
|
| 126 |
</target> |
| 127 |
<target name="-init-check" depends="-pre-init,-init-private,-init-user,-init-project,-do-init"> |
| 128 |
<fail unless="src.dir">Must set src.dir</fail> |
| 129 |
<fail unless="test.src.dir">Must set test.src.dir</fail> |
| 130 |
<fail unless="build.dir">Must set build.dir</fail> |
| 131 |
<fail unless="dist.dir">Must set dist.dir</fail> |
| 132 |
<fail unless="build.classes.dir">Must set build.classes.dir</fail> |
| 133 |
<fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail> |
| 134 |
<fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail> |
| 135 |
<fail unless="build.test.results.dir">Must set build.test.results.dir</fail> |
| 136 |
<fail unless="build.classes.excludes">Must set build.classes.excludes</fail> |
| 137 |
<fail unless="dist.jar">Must set dist.jar</fail> |
| 138 |
</target> |
| 139 |
<target name="-init-macrodef-property"> |
| 140 |
<macrodef name="property" uri="http://www.netbeans.org/ns/j2se-project/1"> |
| 141 |
<attribute name="name"/> |
| 142 |
<attribute name="value"/> |
| 143 |
<sequential> |
| 144 |
<property name="@{name}" value="${@{value}}"/> |
| 145 |
</sequential> |
| 146 |
</macrodef> |
| 147 |
</target> |
| 148 |
<target name="-init-macrodef-javac"> |
| 149 |
<macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3"> |
| 150 |
<attribute name="srcdir" default="${src.dir}"/> |
| 151 |
<attribute name="destdir" default="${build.classes.dir}"/> |
| 152 |
<attribute name="classpath" default="${javac.classpath}"/> |
| 153 |
<attribute name="debug" default="${javac.debug}"/> |
| 154 |
<element name="customize" optional="true"/> |
| 155 |
<sequential> |
| 156 |
<javac srcdir="@{srcdir}" destdir="@{destdir}" debug="@{debug}" deprecation="${javac.deprecation}" source="${javac.source}" target="${javac.target}" fork="yes" executable="${platform.javac}" tempdir="${java.io.tmpdir}" includeantruntime="false"> |
| 157 |
<classpath> |
| 158 |
<path path="@{classpath}"/> |
| 159 |
</classpath> |
| 160 |
<compilerarg line="${javac.compilerargs}"/> |
| 161 |
<customize/> |
| 162 |
</javac> |
| 163 |
</sequential> |
| 164 |
</macrodef> |
| 165 |
</target> |
| 166 |
<target name="-init-macrodef-junit"> |
| 167 |
<macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3"> |
| 168 |
<attribute name="includes" default="**/*Test.java"/> |
| 169 |
<sequential> |
| 170 |
<junit showoutput="true" fork="true" dir="${basedir}" failureproperty="tests.failed" errorproperty="tests.failed" jvm="${platform.java}"> |
| 171 |
<batchtest todir="${build.test.results.dir}"> |
| 172 |
<fileset dir="${test.src.dir}" includes="@{includes}"/> |
| 173 |
</batchtest> |
| 174 |
<classpath> |
| 175 |
<path path="${run.test.classpath}"/> |
| 176 |
</classpath> |
| 177 |
<syspropertyset> |
| 178 |
<propertyref prefix="test-sys-prop."/> |
| 179 |
<mapper type="glob" from="test-sys-prop.*" to="*"/> |
| 180 |
</syspropertyset> |
| 181 |
<formatter type="brief" usefile="false"/> |
| 182 |
<formatter type="xml"/> |
| 183 |
<jvmarg line="${run.jvmargs}"/> |
| 184 |
</junit> |
| 185 |
</sequential> |
| 186 |
</macrodef> |
| 187 |
</target> |
| 188 |
<target name="-init-macrodef-nbjpda"> |
| 189 |
<macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1"> |
| 190 |
<attribute name="name" default="${main.class}"/> |
| 191 |
<attribute name="classpath" default="${debug.classpath}"/> |
| 192 |
<attribute name="stopclassname" default=""/> |
| 193 |
<sequential> |
| 194 |
<nbjpdastart transport="dt_socket" addressproperty="jpda.address" name="@{name}" stopclassname="@{stopclassname}"> |
| 195 |
<classpath> |
| 196 |
<path path="@{classpath}"/> |
| 197 |
</classpath> |
| 198 |
<bootclasspath> |
| 199 |
<path path="${platform.bootcp}"/> |
| 200 |
</bootclasspath> |
| 201 |
</nbjpdastart> |
| 202 |
</sequential> |
| 203 |
</macrodef> |
| 204 |
<macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/j2se-project/1"> |
| 205 |
<attribute name="dir" default="${build.classes.dir}"/> |
| 206 |
<sequential> |
| 207 |
<nbjpdareload> |
| 208 |
<fileset includes="${fix.includes}*.class" dir="@{dir}"/> |
| 209 |
</nbjpdareload> |
| 210 |
</sequential> |
| 211 |
</macrodef> |
| 212 |
</target> |
| 213 |
<target name="-init-macrodef-debug"> |
| 214 |
<macrodef name="debug" uri="http://www.netbeans.org/ns/j2se-project/3"> |
| 215 |
<attribute name="classname" default="${main.class}"/> |
| 216 |
<attribute name="classpath" default="${debug.classpath}"/> |
| 217 |
<element name="customize" optional="true"/> |
| 218 |
<sequential> |
| 219 |
<java fork="true" classname="@{classname}" dir="${work.dir}" jvm="${platform.java}"> |
| 220 |
<jvmarg value="-Xdebug"/> |
| 221 |
<jvmarg value="-Xnoagent"/> |
| 222 |
<jvmarg value="-Djava.compiler=none"/> |
| 223 |
<jvmarg value="-Xrunjdwp:transport=dt_socket,address=${jpda.address}"/> |
| 224 |
<jvmarg line="${run.jvmargs}"/> |
| 225 |
<classpath> |
| 226 |
<path path="@{classpath}"/> |
| 227 |
</classpath> |
| 228 |
<syspropertyset> |
| 229 |
<propertyref prefix="run-sys-prop."/> |
| 230 |
<mapper type="glob" from="run-sys-prop.*" to="*"/> |
| 231 |
</syspropertyset> |
| 232 |
<customize/> |
| 233 |
</java> |
| 234 |
</sequential> |
| 235 |
</macrodef> |
| 236 |
</target> |
| 237 |
<target name="-init-macrodef-java"> |
| 238 |
<macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1"> |
| 239 |
<attribute name="classname" default="${main.class}"/> |
| 240 |
<element name="customize" optional="true"/> |
| 241 |
<sequential> |
| 242 |
<java fork="true" classname="@{classname}" dir="${work.dir}" jvm="${platform.java}"> |
| 243 |
<jvmarg line="${run.jvmargs}"/> |
| 244 |
<classpath> |
| 245 |
<path path="${run.classpath}"/> |
| 246 |
</classpath> |
| 247 |
<syspropertyset> |
| 248 |
<propertyref prefix="run-sys-prop."/> |
| 249 |
<mapper type="glob" from="run-sys-prop.*" to="*"/> |
| 250 |
</syspropertyset> |
| 251 |
<customize/> |
| 252 |
</java> |
| 253 |
</sequential> |
| 254 |
</macrodef> |
| 255 |
</target> |
| 256 |
<target name="-init-presetdef-jar"> |
| 257 |
<presetdef name="jar" uri="http://www.netbeans.org/ns/j2se-project/1"> |
| 258 |
<jar jarfile="${dist.jar}" compress="${jar.compress}"> |
| 259 |
<j2seproject1:fileset dir="${build.classes.dir}"/> |
| 260 |
</jar> |
| 261 |
</presetdef> |
| 262 |
</target> |
| 263 |
<target name="init" 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"/> |
| 264 |
|
| 265 |
|
| 266 |
|
| 267 |
|
| 268 |
|
| 269 |
<target name="deps-jar" depends="init" unless="no.deps"/> |
| 270 |
<target name="-pre-pre-compile" depends="init,deps-jar"> |
| 271 |
<mkdir dir="${build.classes.dir}"/> |
| 272 |
</target> |
| 273 |
<target name="-pre-compile"> |
| 274 |
|
| 275 |
|
| 276 |
</target> |
| 277 |
<target name="-do-compile" depends="init,deps-jar,-pre-pre-compile,-pre-compile" if="have.sources"> |
| 278 |
<j2seproject3:javac/> |
| 279 |
<copy todir="${build.classes.dir}"> |
| 280 |
<fileset dir="${src.dir}" excludes="${build.classes.excludes}"/> |
| 281 |
</copy> |
| 282 |
</target> |
| 283 |
<target name="-post-compile"> |
| 284 |
|
| 285 |
|
| 286 |
</target> |
| 287 |
<target name="compile" depends="init,deps-jar,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project."/> |
| 288 |
<target name="-pre-compile-single"> |
| 289 |
|
| 290 |
|
| 291 |
</target> |
| 292 |
<target name="-do-compile-single" depends="init,deps-jar,-pre-pre-compile"> |
| 293 |
<fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail> |
| 294 |
<j2seproject3:javac> |
| 295 |
<customize> |
| 296 |
<patternset includes="${javac.includes}"/> |
| 297 |
</customize> |
| 298 |
</j2seproject3:javac> |
| 299 |
</target> |
| 300 |
<target name="-post-compile-single"> |
| 301 |
|
| 302 |
|
| 303 |
</target> |
| 304 |
<target name="compile-single" depends="init,deps-jar,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single"/> |
| 305 |
|
| 306 |
|
| 307 |
|
| 308 |
|
| 309 |
|
| 310 |
<target name="-pre-pre-jar" depends="init"> |
| 311 |
<dirname property="dist.jar.dir" file="${dist.jar}"/> |
| 312 |
<mkdir dir="${dist.jar.dir}"/> |
| 313 |
</target> |
| 314 |
<target name="-pre-jar"> |
| 315 |
|
| 316 |
|
| 317 |
</target> |
| 318 |
<target name="-do-jar-without-manifest" depends="init,compile,-pre-pre-jar,-pre-jar" unless="manifest.available"> |
| 319 |
<j2seproject1:jar/> |
| 320 |
</target> |
| 321 |
<target name="-do-jar-with-manifest" depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available" unless="manifest.available+main.class"> |
| 322 |
<j2seproject1:jar manifest="${manifest.file}"/> |
| 323 |
</target> |
| 324 |
<target name="-do-jar-with-mainclass" depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class" unless="manifest.available+main.class+mkdist.available"> |
| 325 |
<j2seproject1:jar manifest="${manifest.file}"> |
| 326 |
<j2seproject1:manifest> |
| 327 |
<j2seproject1:attribute name="Main-Class" value="${main.class}"/> |
| 328 |
</j2seproject1:manifest> |
| 329 |
</j2seproject1:jar> |
| 330 |
<echo>To run this application from the command line without Ant, try:</echo> |
| 331 |
<property name="build.classes.dir.resolved" location="${build.classes.dir}"/> |
| 332 |
<property name="dist.jar.resolved" location="${dist.jar}"/> |
| 333 |
<pathconvert property="run.classpath.with.dist.jar"> |
| 334 |
<path path="${run.classpath}"/> |
| 335 |
<map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/> |
| 336 |
</pathconvert> |
| 337 |
<echo>${platform.java} -cp "${run.classpath.with.dist.jar}" ${main.class}</echo> |
| 338 |
</target> |
| 339 |
<target name="-do-jar-with-libraries" depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class+mkdist.available"> |
| 340 |
<property name="build.classes.dir.resolved" location="${build.classes.dir}"/> |
| 341 |
<pathconvert property="run.classpath.without.build.classes.dir"> |
| 342 |
<path path="${run.classpath}"/> |
| 343 |
<map from="${build.classes.dir.resolved}" to=""/> |
| 344 |
</pathconvert> |
| 345 |
<pathconvert property="jar.classpath" pathsep=" "> |
| 346 |
<path path="${run.classpath.without.build.classes.dir}"/> |
| 347 |
<chainedmapper> |
| 348 |
<flattenmapper/> |
| 349 |
<globmapper from="*" to="lib/*"/> |
| 350 |
</chainedmapper> |
| 351 |
</pathconvert> |
| 352 |
<taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" name="copylibs" classpath="${libs.CopyLibs.classpath}"/> |
| 353 |
<copylibs manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}" jarfile="${dist.jar}" compress="${jar.compress}"> |
| 354 |
<fileset dir="${build.classes.dir}"/> |
| 355 |
<manifest> |
| 356 |
<attribute name="Main-Class" value="${main.class}"/> |
| 357 |
<attribute name="Class-Path" value="${jar.classpath}"/> |
| 358 |
</manifest> |
| 359 |
</copylibs> |
| 360 |
<echo>To run this application from the command line without Ant, try:</echo> |
| 361 |
<property name="dist.jar.resolved" location="${dist.jar}"/> |
| 362 |
<echo>${platform.java} -jar "${dist.jar.resolved}"</echo> |
| 363 |
</target> |
| 364 |
<target name="-post-jar"> |
| 365 |
|
| 366 |
|
| 367 |
</target> |
| 368 |
<target name="jar" depends="init,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-post-jar" description="Build JAR."/> |
| 369 |
|
| 370 |
|
| 371 |
|
| 372 |
|
| 373 |
|
| 374 |
<target name="run" depends="init,compile" description="Run a main class."> |
| 375 |
<j2seproject1:java> |
| 376 |
<customize> |
| 377 |
<arg line="${application.args}"/> |
| 378 |
</customize> |
| 379 |
</j2seproject1:java> |
| 380 |
</target> |
| 381 |
<target name="run-single" depends="init,compile-single"> |
| 382 |
<fail unless="run.class">Must select one file in the IDE or set run.class</fail> |
| 383 |
<j2seproject1:java classname="${run.class}"/> |
| 384 |
</target> |
| 385 |
|
| 386 |
|
| 387 |
|
| 388 |
|
| 389 |
|
| 390 |
<target name="-debug-start-debugger" if="netbeans.home" depends="init"> |
| 391 |
<j2seproject1:nbjpdastart name="${debug.class}"/> |
| 392 |
</target> |
| 393 |
<target name="-debug-start-debuggee" depends="init,compile"> |
| 394 |
<j2seproject3:debug> |
| 395 |
<customize> |
| 396 |
<arg line="${application.args}"/> |
| 397 |
</customize> |
| 398 |
</j2seproject3:debug> |
| 399 |
</target> |
| 400 |
<target name="debug" if="netbeans.home" depends="init,compile,-debug-start-debugger,-debug-start-debuggee" description="Debug project in IDE."/> |
| 401 |
<target name="-debug-start-debugger-stepinto" if="netbeans.home" depends="init"> |
| 402 |
<j2seproject1:nbjpdastart stopclassname="${main.class}"/> |
| 403 |
</target> |
| 404 |
<target name="debug-stepinto" if="netbeans.home" depends="init,compile,-debug-start-debugger-stepinto,-debug-start-debuggee"/> |
| 405 |
<target name="-debug-start-debuggee-single" if="netbeans.home" depends="init,compile-single"> |
| 406 |
<fail unless="debug.class">Must select one file in the IDE or set debug.class</fail> |
| 407 |
<j2seproject3:debug classname="${debug.class}"/> |
| 408 |
</target> |
| 409 |
<target name="debug-single" if="netbeans.home" depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single"/> |
| 410 |
<target name="-pre-debug-fix" depends="init"> |
| 411 |
<fail unless="fix.includes">Must set fix.includes</fail> |
| 412 |
<property name="javac.includes" value="${fix.includes}.java"/> |
| 413 |
</target> |
| 414 |
<target name="-do-debug-fix" if="netbeans.home" depends="init,-pre-debug-fix,compile-single"> |
| 415 |
<j2seproject1:nbjpdareload/> |
| 416 |
</target> |
| 417 |
<target name="debug-fix" if="netbeans.home" depends="init,-pre-debug-fix,-do-debug-fix"/> |
| 418 |
|
| 419 |
|
| 420 |
|
| 421 |
|
| 422 |
|
| 423 |
<target name="-javadoc-build" depends="init"> |
| 424 |
<mkdir dir="${dist.javadoc.dir}"/> |
| 425 |
<javadoc destdir="${dist.javadoc.dir}" source="${javac.source}" notree="${javadoc.notree}" use="${javadoc.use}" nonavbar="${javadoc.nonavbar}" noindex="${javadoc.noindex}" splitindex="${javadoc.splitindex}" author="${javadoc.author}" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}" private="${javadoc.private}" additionalparam="${javadoc.additionalparam}" failonerror="true" useexternalfile="true" executable="${platform.javadoc}"> |
| 426 |
<classpath> |
| 427 |
<path path="${javac.classpath}"/> |
| 428 |
</classpath> |
| 429 |
<sourcepath> |
| 430 |
<pathelement location="${src.dir}"/> |
| 431 |
</sourcepath> |
| 432 |
<packageset dir="${src.dir}" includes="*/**"/> |
| 433 |
<fileset dir="${src.dir}" includes="*.java"/> |
| 434 |
</javadoc> |
| 435 |
</target> |
| 436 |
<target name="-javadoc-browse" if="netbeans.home" unless="no.javadoc.preview" depends="init,-javadoc-build"> |
| 437 |
<nbbrowse file="${dist.javadoc.dir}/index.html"/> |
| 438 |
</target> |
| 439 |
<target name="javadoc" depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc."/> |
| 440 |
|
| 441 |
|
| 442 |
|
| 443 |
|
| 444 |
|
| 445 |
<target name="-pre-pre-compile-test" if="have.tests" depends="init,compile"> |
| 446 |
<mkdir dir="${build.test.classes.dir}"/> |
| 447 |
</target> |
| 448 |
<target name="-pre-compile-test"> |
| 449 |
|
| 450 |
|
| 451 |
</target> |
| 452 |
<target name="-do-compile-test" if="have.tests" depends="init,compile,-pre-pre-compile-test,-pre-compile-test"> |
| 453 |
<j2seproject3:javac srcdir="${test.src.dir}" destdir="${build.test.classes.dir}" debug="true" classpath="${javac.test.classpath}"/> |
| 454 |
<copy todir="${build.test.classes.dir}"> |
| 455 |
<fileset dir="${test.src.dir}" excludes="**/*.java"/> |
| 456 |
</copy> |
| 457 |
</target> |
| 458 |
<target name="-post-compile-test"> |
| 459 |
|
| 460 |
|
| 461 |
</target> |
| 462 |
<target name="compile-test" depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test"/> |
| 463 |
<target name="-pre-compile-test-single"> |
| 464 |
|
| 465 |
|
| 466 |
</target> |
| 467 |
<target name="-do-compile-test-single" if="have.tests" depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single"> |
| 468 |
<fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail> |
| 469 |
<j2seproject3:javac srcdir="${test.src.dir}" destdir="${build.test.classes.dir}" debug="true" classpath="${javac.test.classpath}"> |
| 470 |
<customize> |
| 471 |
<patternset includes="${javac.includes}"/> |
| 472 |
</customize> |
| 473 |
</j2seproject3:javac> |
| 474 |
<copy todir="${build.test.classes.dir}"> |
| 475 |
<fileset dir="${test.src.dir}" excludes="**/*.java"/> |
| 476 |
</copy> |
| 477 |
</target> |
| 478 |
<target name="-post-compile-test-single"> |
| 479 |
|
| 480 |
|
| 481 |
</target> |
| 482 |
<target name="compile-test-single" depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single"/> |
| 483 |
|
| 484 |
|
| 485 |
|
| 486 |
|
| 487 |
|
| 488 |
<target name="-pre-test-run" if="have.tests" depends="init"> |
| 489 |
<mkdir dir="${build.test.results.dir}"/> |
| 490 |
</target> |
| 491 |
<target name="-do-test-run" if="have.tests" depends="init,compile-test,-pre-test-run"> |
| 492 |
<j2seproject3:junit/> |
| 493 |
</target> |
| 494 |
<target name="-post-test-run" if="have.tests" depends="init,compile-test,-pre-test-run,-do-test-run"> |
| 495 |
<fail if="tests.failed">Some tests failed; see details above.</fail> |
| 496 |
</target> |
| 497 |
<target name="test-report" if="have.tests" depends="init"/> |
| 498 |
<target name="-test-browse" if="netbeans.home+have.tests" depends="init"/> |
| 499 |
<target name="test" depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests."/> |
| 500 |
<target name="-pre-test-run-single" if="have.tests" depends="init"> |
| 501 |
<mkdir dir="${build.test.results.dir}"/> |
| 502 |
</target> |
| 503 |
<target name="-do-test-run-single" if="have.tests" depends="init,compile-test-single,-pre-test-run-single"> |
| 504 |
<fail unless="test.includes">Must select some files in the IDE or set test.includes</fail> |
| 505 |
<j2seproject3:junit includes="${test.includes}"/> |
| 506 |
</target> |
| 507 |
<target name="-post-test-run-single" if="have.tests" depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single"> |
| 508 |
<fail if="tests.failed">Some tests failed; see details above.</fail> |
| 509 |
</target> |
| 510 |
<target name="test-single" depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test."/> |
| 511 |
|
| 512 |
|
| 513 |
|
| 514 |
|
| 515 |
|
| 516 |
<target name="-debug-start-debuggee-test" if="have.tests" depends="init,compile-test"> |
| 517 |
<fail unless="test.class">Must select one file in the IDE or set test.class</fail> |
| 518 |
<j2seproject3:debug classname="junit.textui.TestRunner" classpath="${debug.test.classpath}"> |
| 519 |
<customize> |
| 520 |
<arg line="${test.class}"/> |
| 521 |
</customize> |
| 522 |
</j2seproject3:debug> |
| 523 |
</target> |
| 524 |
<target name="-debug-start-debugger-test" if="netbeans.home+have.tests" depends="init,compile-test"> |
| 525 |
<j2seproject1:nbjpdastart name="${test.class}" classpath="${debug.test.classpath}"/> |
| 526 |
</target> |
| 527 |
<target name="debug-test" depends="init,compile-test,-debug-start-debugger-test,-debug-start-debuggee-test"/> |
| 528 |
<target name="-do-debug-fix-test" if="netbeans.home" depends="init,-pre-debug-fix,compile-test-single"> |
| 529 |
<j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/> |
| 530 |
</target> |
| 531 |
<target name="debug-fix-test" if="netbeans.home" depends="init,-pre-debug-fix,-do-debug-fix-test"/> |
| 532 |
|
| 533 |
|
| 534 |
|
| 535 |
|
| 536 |
|
| 537 |
<target name="run-applet" depends="init,compile-single"> |
| 538 |
<fail unless="applet.url">Must select one file in the IDE or set applet.url</fail> |
| 539 |
<j2seproject1:java classname="sun.applet.AppletViewer"> |
| 540 |
<customize> |
| 541 |
<arg value="${applet.url}"/> |
| 542 |
</customize> |
| 543 |
</j2seproject1:java> |
| 544 |
</target> |
| 545 |
|
| 546 |
|
| 547 |
|
| 548 |
|
| 549 |
|
| 550 |
<target name="-debug-start-debuggee-applet" if="netbeans.home" depends="init,compile-single"> |
| 551 |
<fail unless="applet.url">Must select one file in the IDE or set applet.url</fail> |
| 552 |
<j2seproject3:debug classname="sun.applet.AppletViewer"> |
| 553 |
<customize> |
| 554 |
<arg value="${applet.url}"/> |
| 555 |
</customize> |
| 556 |
</j2seproject3:debug> |
| 557 |
</target> |
| 558 |
<target name="debug-applet" if="netbeans.home" depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-applet"/> |
| 559 |
|
| 560 |
|
| 561 |
|
| 562 |
|
| 563 |
|
| 564 |
<target name="deps-clean" depends="init" unless="no.deps"/> |
| 565 |
<target name="-do-clean" depends="init"> |
| •566 |
<delete file="${dist.jar}"/> |
| 567 |
<delete dir="${dist.javadoc.dir}"/> |
| 568 |
<delete dir="${build.classes.dir}"/> |
| 569 |
</target> |
| 570 |
<target name="-post-clean"> |
| 571 |
|
| 572 |
|
| 573 |
</target> |
| 574 |
<target name="clean" depends="init,deps-clean,-do-clean,-post-clean" description="Clean build products."/> |
| 575 |
</project> |