You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1413 rivejä
77 KiB

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