author | jjg |
Fri, 11 Dec 2009 14:26:27 -0800 | |
changeset 4548 | bc0d5b3c3b2d |
parent 4415 | 7d4f73717fba |
child 4698 | 4ea5b8e20252 |
permissions | -rw-r--r-- |
10 | 1 |
<?xml version="1.0" encoding="UTF-8"?> |
2 |
<!-- |
|
2212 | 3 |
Copyright 2007-2009 Sun Microsystems, Inc. All Rights Reserved. |
10 | 4 |
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
5 |
||
6 |
This code is free software; you can redistribute it and/or modify it |
|
7 |
under the terms of the GNU General Public License version 2 only, as |
|
8 |
published by the Free Software Foundation. Sun designates this |
|
9 |
particular file as subject to the "Classpath" exception as provided |
|
10 |
by Sun in the LICENSE file that accompanied this code. |
|
11 |
||
12 |
This code is distributed in the hope that it will be useful, but WITHOUT |
|
13 |
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
14 |
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
15 |
version 2 for more details (a copy is included in the LICENSE file that |
|
16 |
accompanied this code). |
|
17 |
||
18 |
You should have received a copy of the GNU General Public License version |
|
19 |
2 along with this work; if not, write to the Free Software Foundation, |
|
20 |
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
21 |
||
22 |
Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, |
|
23 |
CA 95054 USA or visit www.sun.com if you need additional information or |
|
24 |
have any questions. |
|
25 |
--> |
|
26 |
||
27 |
<!-- |
|
28 |
This is the main build file for the complete langtools workspace. |
|
29 |
It is used both when working on the tools in NetBeans, and when building |
|
30 |
JDK itself, in which case it is invoked from the wrapper Makefile. |
|
31 |
--> |
|
32 |
||
33 |
<project name="langtools" default="build" basedir=".."> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
34 |
|
2850
307d7719ccb7
6837665: Deal with windows ant problem where commas in -D options do not work
aph
parents:
2212
diff
changeset
|
35 |
<!-- Force full debuginfo for javac if the debug.classfiles |
307d7719ccb7
6837665: Deal with windows ant problem where commas in -D options do not work
aph
parents:
2212
diff
changeset
|
36 |
property is set. This must be BEFORE the include of |
307d7719ccb7
6837665: Deal with windows ant problem where commas in -D options do not work
aph
parents:
2212
diff
changeset
|
37 |
build.properties because it sets javac.debuglevel. --> |
307d7719ccb7
6837665: Deal with windows ant problem where commas in -D options do not work
aph
parents:
2212
diff
changeset
|
38 |
<condition property="javac.debuglevel" value="source,lines,vars"> |
307d7719ccb7
6837665: Deal with windows ant problem where commas in -D options do not work
aph
parents:
2212
diff
changeset
|
39 |
<equals arg1="${debug.classfiles}" arg2="true"/> |
307d7719ccb7
6837665: Deal with windows ant problem where commas in -D options do not work
aph
parents:
2212
diff
changeset
|
40 |
</condition> |
307d7719ccb7
6837665: Deal with windows ant problem where commas in -D options do not work
aph
parents:
2212
diff
changeset
|
41 |
|
10 | 42 |
<!-- The following locations can be used to override default property values. --> |
43 |
||
44 |
<!-- Use this location for customizations specific to this instance of this workspace --> |
|
45 |
<property file="build.properties"/> |
|
46 |
||
47 |
<!-- Use this location for customizations common to all OpenJDK langtools workspaces --> |
|
48 |
<property file="${user.home}/.openjdk/${ant.project.name}-build.properties"/> |
|
49 |
||
50 |
<!-- Use this location for customizations common to all OpenJDK workspaces --> |
|
51 |
<property file="${user.home}/.openjdk/build.properties"/> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
52 |
|
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
53 |
<!-- Convenient shorthands for standard locations within the workspace. --> |
10 | 54 |
<property name="build.dir" location="build"/> |
55 |
<property name="build.bootstrap.dir" location="${build.dir}/bootstrap"/> |
|
56 |
<property name="build.coverage.dir" location="${build.dir}/coverage"/> |
|
57 |
<property name="build.classes.dir" location="${build.dir}/classes"/> |
|
58 |
<property name="build.gensrc.dir" location="${build.dir}/gensrc"/> |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
59 |
<property name="build.genstubs.dir" location="${build.dir}/genstubs"/> |
10 | 60 |
<property name="build.javadoc.dir" location="${build.dir}/javadoc"/> |
61 |
<property name="build.jtreg.dir" location="${build.dir}/jtreg"/> |
|
62 |
<property name="build.toolclasses.dir" location="${build.dir}/toolclasses"/> |
|
63 |
<property name="dist.dir" location="dist"/> |
|
64 |
<property name="dist.bin.dir" location="${dist.dir}/bin"/> |
|
65 |
<property name="dist.coverage.dir" location="${dist.dir}/coverage"/> |
|
66 |
<property name="dist.findbugs.dir" location="${dist.dir}/findbugs"/> |
|
67 |
<property name="dist.lib.dir" location="${dist.dir}/lib"/> |
|
68 |
<property name="make.dir" location="make"/> |
|
69 |
<property name="make.tools.dir" location="${make.dir}/tools"/> |
|
70 |
<property name="src.dir" location="src"/> |
|
71 |
<property name="src.bin.dir" location="${src.dir}/share/bin"/> |
|
72 |
<property name="src.classes.dir" location="${src.dir}/share/classes"/> |
|
73 |
<property name="test.dir" location="test"/> |
|
74 |
||
75 |
<!-- java.marker is set to a marker file to check for within a Java install dir. |
|
76 |
The best file to check for across Solaris/Linux/Windows/MacOS is one of the |
|
77 |
executables; regrettably, that is OS-specific. --> |
|
78 |
<condition property="java.marker" value="bin/java"> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
79 |
<os family="unix"/> |
10 | 80 |
</condition> |
81 |
<condition property="java.marker" value="bin/java.exe"> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
82 |
<os family="windows"/> |
10 | 83 |
</condition> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
84 |
|
10 | 85 |
<!-- Standard property values, if not overriden by earlier settings. --> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
86 |
<property file="${make.dir}/build.properties"/> |
3654 | 87 |
|
88 |
<!-- launcher.java is used in the launcher scripts provided to run |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
89 |
the tools' jar files. If it has not already been set, then |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
90 |
default it to use ${target.java.home}, if available, otherwise |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
91 |
quietly default to simply use "java". --> |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
92 |
<condition property="launcher.java" |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
93 |
value="${target.java.home}/bin/java" else="java"> |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
94 |
<isset property="target.java.home"/> |
3654 | 95 |
</condition> |
96 |
||
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
97 |
<!-- Logic for handling access import jdk classes, if available. |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
98 |
import.jdk should be unset, or set to jdk home (to use rt.jar) |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
99 |
or to jdk repo (to use src/share/classes). |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
100 |
Based on the value, if any, set up default values for javac's sourcepath, |
4548 | 101 |
classpath and bootclasspath. Note: the default values are overridden |
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
102 |
in the build-bootstrap-classes macro. --> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
103 |
|
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
104 |
<available property="import.jdk.src.dir" value="${import.jdk}/src/share/classes" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
105 |
filepath="${import.jdk}/src/share/classes" file="java/nio/file/Path.java"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
106 |
<available property="import.jdk.jar" value="${import.jdk}/jre/lib/rt.jar" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
107 |
ignoresystemclasses="true" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
108 |
classpath="${import.jdk}/jre/lib/rt.jar" classname="java.nio.file.Path"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
109 |
|
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
110 |
<condition property="javac.sourcepath" value="${build.genstubs.dir}" else=""> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
111 |
<isset property="import.jdk.src.dir"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
112 |
</condition> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
113 |
|
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
114 |
<property name="javac.classpath" value=""/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
115 |
|
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
116 |
<condition property="javac.bootclasspath.opt" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
117 |
value="-Xbootclasspath:${build.classes.dir}:${import.jdk.jar}" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
118 |
else="-Xbootclasspath/p:${build.classes.dir}"> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
119 |
<isset property="import.jdk.jar"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
120 |
</condition> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
121 |
|
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
122 |
<condition property="exclude.files" value="" else="${require.import.jdk.files}"> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
123 |
<isset property="import.jdk"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
124 |
</condition> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
125 |
|
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
126 |
<!-- for debugging --> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
127 |
<target name="check-import.jdk"> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
128 |
<echo message="import.jdk: ${import.jdk}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
129 |
<echo message="import.jdk.jar: ${import.jdk.jar}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
130 |
<echo message="import.jdk.src.dir: ${import.jdk.src.dir}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
131 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
132 |
|
10 | 133 |
<!-- Standard target to build deliverables for JDK build. --> |
134 |
||
135 |
<target name="build" depends="build-bootstrap-tools,build-all-classes"> |
|
136 |
<copy todir="${dist.dir}/bootstrap"> |
|
137 |
<fileset dir="${build.bootstrap.dir}" includes="bin/,lib/"/> |
|
138 |
</copy> |
|
139 |
<chmod dir="${dist.dir}/bootstrap/bin" perm="ugo+rx"> |
|
140 |
<include name="*"/> |
|
141 |
</chmod> |
|
142 |
<mkdir dir="${dist.lib.dir}"/> |
|
143 |
<jar file="${dist.lib.dir}/classes.jar" basedir="${build.classes.dir}"/> |
|
144 |
<zip file="${dist.lib.dir}/src.zip" basedir="${src.classes.dir}"/> |
|
145 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
146 |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
147 |
<target name="build-bootstrap-tools" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
148 |
depends="build-bootstrap-javac,build-bootstrap-javadoc,build-bootstrap-doclets,build-bootstrap-javah" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
149 |
/> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
150 |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
151 |
<target name="build-all-tools" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
152 |
depends="build-javac,build-javadoc,build-doclets,build-javah,build-javap,build-apt" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
153 |
/> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
154 |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
155 |
<target name="build-all-classes" depends="build-bootstrap-javac,-create-import-jdk-stubs"> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
156 |
<build-classes includes="${javac.includes} ${javadoc.includes} ${doclets.includes} ${javah.includes} ${javap.includes} ${apt.includes}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
157 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
158 |
|
10 | 159 |
<!-- clean --> |
160 |
||
161 |
<target name="clean" description="Delete all generated files"> |
|
162 |
<delete dir="${build.dir}"/> |
|
163 |
<delete dir="${dist.dir}"/> |
|
164 |
</target> |
|
165 |
||
166 |
<!-- Additional targets for running tools on the build --> |
|
167 |
||
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
168 |
<target name="jtreg" depends="build-all-tools,-def-jtreg"> |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
169 |
<jtreg-tool name="all" tests="${jtreg.tests}"/> |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
170 |
</target> |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
171 |
|
10 | 172 |
<target name="findbugs" depends="-def-findbugs,build-all-tools"> |
173 |
<property name="findbugs.reportLevel" value="medium"/> |
|
174 |
<mkdir dir="${dist.findbugs.dir}"/> |
|
175 |
<findbugs |
|
176 |
home="${findbugs.home}" |
|
177 |
projectName="JDK langtools ${full.version}" |
|
178 |
output="xml" |
|
179 |
outputFile="${dist.findbugs.dir}/findbugs.xml" |
|
180 |
reportLevel="${findbugs.reportLevel}" |
|
181 |
failOnError="false" |
|
182 |
errorProperty="findbugs.all.errors" |
|
183 |
warningsProperty="findbugs.all.warnings" |
|
184 |
jvmargs="-Xmx512M"> |
|
185 |
<class location="${build.classes.dir}"/> |
|
186 |
<sourcePath> |
|
187 |
<pathelement location="${src.classes.dir}"/> |
|
188 |
</sourcePath> |
|
189 |
</findbugs> |
|
190 |
<exec executable="sh"> |
|
191 |
<arg value="${findbugs.home}/bin/convertXmlToText"/> |
|
192 |
<arg value="-longBugCodes"/> |
|
193 |
<arg value="-html:${findbugs.home}/src/xsl/fancy.xsl"/> |
|
194 |
<arg value="${dist.findbugs.dir}/findbugs.xml"/> |
|
195 |
<redirector output="${dist.findbugs.dir}/findbugs.html"/> |
|
727
cb50c1ae7bab
4075303: Use javap to enquire aboput a specific inner class
jjg
parents:
10
diff
changeset
|
196 |
</exec> |
10 | 197 |
</target> |
198 |
||
199 |
<target name="coverage" depends="-def-cobertura,build-all-classes,instrument-classes,jtreg,coverage-report"/> |
|
200 |
||
201 |
<target name="instrument-classes" depends="-def-cobertura"> |
|
202 |
<!-- only define the following property when we want coverage info --> |
|
203 |
<path id="coverage.classpath"> |
|
204 |
<pathelement location="${build.coverage.dir}/classes"/> |
|
205 |
<path refid="cobertura.classpath"/> |
|
206 |
</path> |
|
207 |
<property name="coverage.options" value="-Dnet.sourceforge.cobertura.datafile=${build.coverage.dir}/cobertura.ser"/> |
|
208 |
<property name="coverage.classpath" refid="coverage.classpath"/> |
|
209 |
<mkdir dir="${build.coverage.dir}/classes"/> |
|
210 |
<delete file="${build.coverage.dir}/cobertura.ser"/> |
|
211 |
<cobertura-instrument todir="${build.coverage.dir}/classes" |
|
212 |
datafile="${build.coverage.dir}/cobertura.ser"> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
213 |
<fileset dir="${build.classes.dir}" |
10 | 214 |
includes="**/*.class" excludes="**/resources/*.class"/> |
215 |
</cobertura-instrument> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
216 |
</target> |
10 | 217 |
|
218 |
<target name="coverage-report" depends="-def-cobertura"> |
|
219 |
<mkdir dir="${dist.coverage.dir}"/> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
220 |
<cobertura-report |
10 | 221 |
srcdir="${src.classes.dir}" |
222 |
destdir="${dist.coverage.dir}" |
|
223 |
datafile="${build.coverage.dir}/cobertura.ser"/> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
224 |
<cobertura-report |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
225 |
format="xml" |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
226 |
srcdir="${src.classes.dir}" |
10 | 227 |
destdir="${dist.coverage.dir}" |
228 |
datafile="${build.coverage.dir}/cobertura.ser"/> |
|
229 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
230 |
|
10 | 231 |
<!-- javac targets --> |
232 |
||
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
233 |
<target name="build-bootstrap-javac" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
234 |
depends="-def-build-bootstrap-classes,-def-build-bootstrap-jar,-def-build-bootstrap-tool"> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
235 |
<build-bootstrap-classes includes="${javac.includes}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
236 |
<build-bootstrap-jar name="javac" includes="${javac.includes}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
237 |
<build-bootstrap-tool name="javac"/> |
10 | 238 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
239 |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
240 |
<target name="build-classes-javac" depends="build-bootstrap-javac,-create-import-jdk-stubs"> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
241 |
<build-classes includes="${javac.includes}"/> |
10 | 242 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
243 |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
244 |
<target name="build-javac" depends="build-classes-javac"> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
245 |
<build-jar name="javac" includes="${javac.includes}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
246 |
<build-tool name="javac"/> |
10 | 247 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
248 |
|
10 | 249 |
<target name="javadoc-javac" depends="build-javac,-def-javadoc-tool"> |
250 |
<javadoc-tool name="javac" includes="${javac.includes}" options="${javadoc.jls3.option}"/> |
|
251 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
252 |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
253 |
<target name="jtreg-javac" depends="build-javac,build-javap,-def-jtreg"> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
254 |
<jtreg-tool name="javac" tests="${javac.tests}"/> |
10 | 255 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
256 |
|
10 | 257 |
<target name="findbugs-javac" depends="build-javac,-def-findbugs"> |
258 |
<findbugs-tool name="javac"/> |
|
259 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
260 |
|
10 | 261 |
<target name="javac" depends="build-javac,jtreg-javac,findbugs-javac"/> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
262 |
|
10 | 263 |
<!-- javadoc targets --> |
264 |
||
265 |
<target name="build-bootstrap-javadoc" depends="build-bootstrap-javac"> |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
266 |
<build-bootstrap-classes includes="${javadoc.includes}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
267 |
<build-bootstrap-jar name="javadoc" includes="${javadoc.includes}" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
268 |
jarclasspath="javac.jar doclets.jar"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
269 |
<build-bootstrap-tool name="javadoc"/> |
10 | 270 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
271 |
|
10 | 272 |
<target name="build-classes-javadoc" depends="build-classes-javac"> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
273 |
<build-classes includes="${javadoc.includes}"/> |
10 | 274 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
275 |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
276 |
<target name="build-javadoc" depends="build-javac,build-classes-javadoc"> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
277 |
<build-jar name="javadoc" includes="${javadoc.includes}" |
10 | 278 |
jarclasspath="javac.jar doclets.jar"/> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
279 |
<build-tool name="javadoc"/> |
10 | 280 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
281 |
|
10 | 282 |
<target name="javadoc-javadoc" depends="build-javadoc,-def-javadoc-tool"> |
283 |
<javadoc-tool name="javadoc" includes="${javadoc.includes}"/> |
|
284 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
285 |
|
10 | 286 |
<target name="jtreg-javadoc" depends="build-javadoc,-def-jtreg"> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
287 |
<jtreg-tool name="javadoc" tests="${javadoc.tests}"/> |
10 | 288 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
289 |
|
10 | 290 |
<target name="findbugs-javadoc" depends="build-javadoc,-def-findbugs"> |
291 |
<findbugs-tool name="javadoc"/> |
|
292 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
293 |
|
10 | 294 |
<target name="javadoc" depends="build-javadoc,jtreg-javadoc,findbugs-javadoc"/> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
295 |
|
10 | 296 |
<!-- doclets targets --> |
297 |
||
298 |
<target name="build-bootstrap-doclets" depends="build-bootstrap-javadoc,-def-build-bootstrap-jar"> |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
299 |
<build-bootstrap-classes includes="${doclets.includes}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
300 |
<build-bootstrap-jar name="doclets" includes="${doclets.includes}" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
301 |
jarmainclass="com.sun.tools.javadoc.Main" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
302 |
jarclasspath="javadoc.jar"/> |
10 | 303 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
304 |
|
10 | 305 |
<target name="build-classes-doclets" depends="build-classes-javadoc"> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
306 |
<build-classes includes="${doclets.includes}"/> |
10 | 307 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
308 |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
309 |
<target name="build-doclets" depends="build-javadoc,build-classes-doclets"> |
10 | 310 |
<!-- just jar, no bin for doclets --> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
311 |
<build-jar name="doclets" includes="${doclets.includes}" jarclasspath="javadoc.jar"/> |
10 | 312 |
</target> |
313 |
||
314 |
<!-- (no javadoc for doclets) --> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
315 |
|
10 | 316 |
<target name="jtreg-doclets" depends="build-doclets,-def-jtreg"> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
317 |
<jtreg-tool name="doclets" tests="${doclets.tests}"/> |
10 | 318 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
319 |
|
10 | 320 |
<target name="findbugs-doclets" depends="build-doclets,-def-findbugs"> |
321 |
<findbugs-tool name="doclets"/> |
|
322 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
323 |
|
10 | 324 |
<target name="doclets" depends="build-doclets,jtreg-doclets,findbugs-doclets"/> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
325 |
|
10 | 326 |
<!-- javah targets --> |
327 |
||
328 |
<target name="build-bootstrap-javah" depends="build-bootstrap-javadoc"> |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
329 |
<build-bootstrap-classes includes="${javah.includes}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
330 |
<build-bootstrap-jar name="javah" includes="${javah.includes}" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
331 |
jarclasspath="javadoc.jar doclets.jar javac.jar"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
332 |
<build-bootstrap-tool name="javah"/> |
10 | 333 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
334 |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
335 |
<target name="build-javah" depends="build-javac,build-classes-javah"> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
336 |
<build-jar name="javah" includes="${javah.includes}" jarclasspath="javac.jar"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
337 |
<build-tool name="javah"/> |
10 | 338 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
339 |
|
10 | 340 |
<target name="build-classes-javah" depends="build-classes-javadoc"> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
341 |
<build-classes includes="${javah.includes}"/> |
10 | 342 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
343 |
|
10 | 344 |
<!-- (no javadoc for javah) --> |
345 |
||
346 |
<target name="jtreg-javah" depends="build-javah,-def-jtreg"> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
347 |
<jtreg-tool name="javah" tests="${javah.tests}"/> |
10 | 348 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
349 |
|
10 | 350 |
<target name="findbugs-javah" depends="build-javah,-def-findbugs"> |
351 |
<findbugs-tool name="javah"/> |
|
352 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
353 |
|
10 | 354 |
<target name="javah" depends="build-javah,jtreg-javah,findbugs-javah"/> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
355 |
|
10 | 356 |
<!-- javap targets --> |
357 |
||
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
358 |
<target name="build-bootstrap-javap" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
359 |
depends="-def-build-bootstrap-classes,-def-build-bootstrap-jar,-def-build-bootstrap-tool"> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
360 |
<build-bootstrap-classes includes="${javap.includes}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
361 |
<build-bootstrap-jar name="javap" includes="${javap.includes}" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
362 |
jarmainclass="sun.tools.javap.Main"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
363 |
<build-bootstrap-tool name="javap"/> |
10 | 364 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
365 |
|
727
cb50c1ae7bab
4075303: Use javap to enquire aboput a specific inner class
jjg
parents:
10
diff
changeset
|
366 |
<target name="build-classes-javap" depends="build-classes-javac"> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
367 |
<build-classes includes="${javap.includes}"/> |
10 | 368 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
369 |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
370 |
<target name="build-javap" depends="build-javac,build-classes-javap"> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
371 |
<build-jar name="javap" includes="${javap.includes}" |
2987 | 372 |
jarmainclass="com.sun.tools.javap.Main" |
727
cb50c1ae7bab
4075303: Use javap to enquire aboput a specific inner class
jjg
parents:
10
diff
changeset
|
373 |
jarclasspath="javac.jar"/> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
374 |
<build-tool name="javap"/> |
10 | 375 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
376 |
|
10 | 377 |
<!-- (no javadoc for javap) --> |
378 |
||
379 |
<target name="jtreg-javap" depends="build-javap,-def-jtreg"> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
380 |
<jtreg-tool name="javap" tests="${javap.tests}"/> |
10 | 381 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
382 |
|
10 | 383 |
<target name="findbugs-javap" depends="build-javap,-def-findbugs"> |
384 |
<findbugs-tool name="javap"/> |
|
385 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
386 |
|
10 | 387 |
<target name="javap" depends="build-javap,jtreg-javap,findbugs-javap"/> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
388 |
|
10 | 389 |
<!-- apt targets --> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
390 |
|
10 | 391 |
<target name="build-bootstrap-apt" depends="build-bootstrap-javac"> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
392 |
<build-bootstrap-classes includes="${apt.includes}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
393 |
<build-bootstrap-jar name="apt" includes="${apt.includes}" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
394 |
jarclasspath="javac.jar"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
395 |
<build-bootstrap-tool name="apt"/> |
10 | 396 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
397 |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
398 |
<target name="build-apt" depends="build-javac,build-classes-apt"> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
399 |
<build-jar name="apt" includes="${apt.includes}" jarclasspath="javac.jar"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
400 |
<build-tool name="apt"/> |
10 | 401 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
402 |
|
10 | 403 |
<target name="build-classes-apt" depends="build-classes-javac"> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
404 |
<build-classes includes="${apt.includes}"/> |
10 | 405 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
406 |
|
10 | 407 |
<target name="javadoc-apt" depends="build-apt,-def-javadoc-tool"> |
408 |
<javadoc-tool name="apt" includes="${apt.includes}"/> |
|
409 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
410 |
|
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
411 |
|
10 | 412 |
<target name="jtreg-apt" depends="build-apt,-def-jtreg"> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
413 |
<jtreg-tool name="apt" tests="${apt.tests}"/> |
10 | 414 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
415 |
|
10 | 416 |
<target name="findbugs-apt" depends="build-apt,-def-findbugs"> |
417 |
<findbugs-tool name="apt"/> |
|
418 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
419 |
|
10 | 420 |
<target name="apt" depends="build-apt,jtreg-apt,findbugs-apt"/> |
421 |
||
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
422 |
<!-- Create import JDK stubs --> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
423 |
|
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
424 |
<target name="-create-import-jdk-stubs" depends="-def-genstubs" if="import.jdk.src.dir"> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
425 |
<mkdir dir="${build.genstubs.dir}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
426 |
<genstubs |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
427 |
srcdir="${import.jdk.src.dir}" destdir="${build.genstubs.dir}" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
428 |
includes="${import.jdk.stub.files}" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
429 |
fork="true" classpath="${build.toolclasses.dir}:${build.bootstrap.dir}/classes:${ant.home}/lib/ant.jar" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
430 |
/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
431 |
</target> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
432 |
|
10 | 433 |
<!-- Check targets --> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
434 |
|
10 | 435 |
<target name="-check-boot.java.home" depends="-def-check"> |
436 |
<check name="bootstrap java" property="boot.java.home" marker="${java.marker}"/> |
|
437 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
438 |
|
10 | 439 |
<target name="-check-target.java.home" depends="-def-check"> |
440 |
<check name="target java" property="target.java.home" marker="${java.marker}"/> |
|
441 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
442 |
|
10 | 443 |
<target name="-check-cobertura.home" depends="-def-check"> |
444 |
<check name="cobertura" property="cobertura.home" marker="cobertura.jar"/> |
|
445 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
446 |
|
10 | 447 |
<target name="-check-findbugs.home" depends="-def-check"> |
448 |
<check name="findbugs" property="findbugs.home" marker="lib/findbugs.jar"/> |
|
449 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
450 |
|
10 | 451 |
<target name="-check-jtreg.home" depends="-def-check"> |
452 |
<check name="jtreg" property="jtreg.home" marker="lib/jtreg.jar"/> |
|
453 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
454 |
|
10 | 455 |
<!-- Ant macro and preset defs --> |
456 |
||
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
457 |
<target name="-def-build-tool"> |
10 | 458 |
<macrodef name="build-tool"> |
459 |
<attribute name="name"/> |
|
460 |
<attribute name="bin.dir" default="${dist.bin.dir}"/> |
|
3654 | 461 |
<attribute name="java" default="${launcher.java}"/> |
10 | 462 |
<sequential> |
463 |
<mkdir dir="@{bin.dir}"/> |
|
464 |
<copy file="${src.bin.dir}/launcher.sh-template" tofile="@{bin.dir}/@{name}"> |
|
465 |
<filterset begintoken="#" endtoken="#"> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
466 |
<filter token="PROGRAM" value="@{name}"/> |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
467 |
<filter token="TARGET_JAVA" value="@{java}"/> |
10 | 468 |
</filterset> |
469 |
</copy> |
|
470 |
<chmod file="@{bin.dir}/@{name}" perm="ugo+rx"/> |
|
471 |
</sequential> |
|
472 |
</macrodef> |
|
473 |
</target> |
|
474 |
||
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
475 |
<target name="-def-build-jar"> |
10 | 476 |
<macrodef name="build-jar"> |
477 |
<attribute name="name"/> |
|
478 |
<attribute name="includes"/> |
|
479 |
<attribute name="classes.dir" default="${build.classes.dir}"/> |
|
480 |
<attribute name="lib.dir" default="${dist.lib.dir}"/> |
|
481 |
<attribute name="jarmainclass" default="com.sun.tools.@{name}.Main"/> |
|
482 |
<attribute name="jarclasspath" default=""/> |
|
483 |
<sequential> |
|
484 |
<mkdir dir="@{lib.dir}"/> |
|
485 |
<jar destfile="@{lib.dir}/@{name}.jar" |
|
486 |
basedir="@{classes.dir}" |
|
487 |
includes="@{includes}"> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
488 |
<manifest> |
10 | 489 |
<attribute name="Main-Class" value="@{jarmainclass}"/> |
490 |
<attribute name="Class-Path" value="@{jarclasspath}"/> |
|
491 |
</manifest> |
|
492 |
</jar> |
|
493 |
</sequential> |
|
494 |
</macrodef> |
|
495 |
</target> |
|
496 |
||
497 |
<target name="-def-build-classes" depends="-def-pcompile"> |
|
498 |
<macrodef name="build-classes"> |
|
499 |
<attribute name="includes"/> |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
500 |
<attribute name="excludes" default="${exclude.files} **/package-info.java"/> |
10 | 501 |
<attribute name="classes.dir" default="${build.classes.dir}"/> |
502 |
<attribute name="gensrc.dir" default="${build.gensrc.dir}"/> |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
503 |
<attribute name="javac.bootclasspath" default="${build.bootstrap.dir}/classes"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
504 |
<attribute name="bootclasspath.opt" default="${javac.bootclasspath.opt}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
505 |
<attribute name="classpath" default="${javac.classpath}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
506 |
<attribute name="sourcepath" default="${javac.sourcepath}"/> |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
507 |
<attribute name="java.home" default="${boot.java.home}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
508 |
<attribute name="source" default="${javac.source}"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
509 |
<attribute name="target" default="${javac.target}"/> |
10 | 510 |
<attribute name="release" default="${release}"/> |
511 |
<attribute name="full.version" default="${full.version}"/> |
|
512 |
<sequential> |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
513 |
<echo level="verbose" message="build-classes: excludes=@{excludes}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
514 |
<echo level="verbose" message="build-classes: bootclasspath.opt=@{bootclasspath.opt}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
515 |
<echo level="verbose" message="build-classes: classpath=@{classpath}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
516 |
<echo level="verbose" message="build-classes: sourcepath=@{sourcepath}"/> |
10 | 517 |
<mkdir dir="@{gensrc.dir}"/> |
518 |
<mkdir dir="@{classes.dir}"/> |
|
519 |
<pcompile srcdir="${src.classes.dir}" |
|
520 |
destdir="@{gensrc.dir}" |
|
521 |
includes="@{includes}"/> |
|
522 |
<copy todir="@{gensrc.dir}"> |
|
727
cb50c1ae7bab
4075303: Use javap to enquire aboput a specific inner class
jjg
parents:
10
diff
changeset
|
523 |
<fileset dir="${src.classes.dir}" includes="@{includes}"/> |
10 | 524 |
<globmapper from="*.properties-template" to="*.properties"/> |
525 |
<filterset begintoken="$(" endtoken=")"> |
|
526 |
<filter token="JDK_VERSION" value="${jdk.version}"/> |
|
527 |
<filter token="RELEASE" value="@{release}"/> |
|
528 |
<filter token="FULL_VERSION" value="@{full.version}"/> |
|
529 |
</filterset> |
|
530 |
</copy> |
|
531 |
<pcompile srcdir="@{gensrc.dir}" |
|
532 |
destdir="@{gensrc.dir}" |
|
533 |
includes="**/*.properties"/> |
|
534 |
<javac fork="true" |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
535 |
executable="@{java.home}/bin/javac" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
536 |
srcdir="${src.classes.dir}:@{gensrc.dir}" |
10 | 537 |
destdir="@{classes.dir}" |
538 |
includes="@{includes}" |
|
539 |
excludes="@{excludes}" |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
540 |
sourcepath="@{sourcepath}" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
541 |
classpath="@{classpath}" |
10 | 542 |
includeAntRuntime="no" |
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
543 |
source="@{source}" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
544 |
target="@{target}" |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
545 |
debug="${javac.debug}" |
10 | 546 |
debuglevel="${javac.debuglevel}"> |
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
547 |
<compilerarg value="-implicit:none"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
548 |
<compilerarg value="-Xprefer:source"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
549 |
<compilerarg value="-J-Xbootclasspath/p:@{javac.bootclasspath}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
550 |
<compilerarg line="@{bootclasspath.opt}"/> |
10 | 551 |
<compilerarg line="${javac.no.jdk.warnings}"/> |
552 |
<compilerarg line="${javac.version.opt}"/> |
|
553 |
<compilerarg line="${javac.lint.opts}"/> |
|
554 |
</javac> |
|
4548 | 555 |
<copy todir="@{classes.dir}" includeemptydirs="false"> |
556 |
<fileset dir="${src.classes.dir}" includes="@{includes}" excludes="@{excludes}"> |
|
10 | 557 |
<exclude name="**/*.java"/> |
558 |
<exclude name="**/*.properties"/> |
|
559 |
<exclude name="**/*-template"/> |
|
560 |
<exclude name="**/package.html"/> |
|
561 |
</fileset> |
|
562 |
</copy> |
|
563 |
</sequential> |
|
564 |
</macrodef> |
|
565 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
566 |
|
10 | 567 |
<target name="-def-build-bootstrap-tool" depends="-check-boot.java.home,-def-build-tool"> |
568 |
<presetdef name="build-bootstrap-tool"> |
|
569 |
<build-tool |
|
570 |
bin.dir="${build.bootstrap.dir}/bin" |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
571 |
java="${boot.java}"/> |
10 | 572 |
</presetdef> |
573 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
574 |
|
10 | 575 |
<target name="-def-build-bootstrap-jar" depends="-def-build-jar"> |
576 |
<presetdef name="build-bootstrap-jar"> |
|
577 |
<build-jar |
|
4410
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
578 |
classes.dir="${build.bootstrap.dir}/classes" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
579 |
lib.dir="${build.bootstrap.dir}/lib"/> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
580 |
</presetdef> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
581 |
</target> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
582 |
|
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
583 |
<target name="-def-build-bootstrap-classes" depends="-def-build-classes"> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
584 |
<presetdef name="build-bootstrap-classes"> |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
585 |
<build-classes |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
586 |
source="${boot.javac.source}" |
0288a787be7a
6898585: restructure langtools build.xml to facilitate more options for <build-classes> macro
jjg
parents:
3996
diff
changeset
|
587 |
target="${boot.javac.target}" |
10 | 588 |
gensrc.dir="${build.bootstrap.dir}/gensrc" |
589 |
classes.dir="${build.bootstrap.dir}/classes" |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
590 |
javac.bootclasspath="" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
591 |
bootclasspath.opt="-Xbootclasspath/p:${build.bootstrap.dir}/classes" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
592 |
sourcepath="" |
10 | 593 |
release="${bootstrap.release}" |
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
594 |
full.version="${bootstrap.full.version}" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
595 |
excludes="${require.import.jdk.files} **/package-info.java"/> |
10 | 596 |
</presetdef> |
597 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
598 |
|
10 | 599 |
<target name="-def-pcompile"> |
600 |
<mkdir dir="${build.toolclasses.dir}"/> |
|
1871
9bb6518238ff
6795030: Files in langtools build can be compiled ignoring java.home settings
jjg
parents:
735
diff
changeset
|
601 |
<javac fork="true" |
3658
8ee720a52b7d
6873059: Explicitly use -source 6 -target 6 when compiling with the boot jdk
andrew
parents:
3655
diff
changeset
|
602 |
source="${boot.javac.source}" |
8ee720a52b7d
6873059: Explicitly use -source 6 -target 6 when compiling with the boot jdk
andrew
parents:
3655
diff
changeset
|
603 |
target="${boot.javac.target}" |
1871
9bb6518238ff
6795030: Files in langtools build can be compiled ignoring java.home settings
jjg
parents:
735
diff
changeset
|
604 |
executable="${boot.java.home}/bin/javac" |
9bb6518238ff
6795030: Files in langtools build can be compiled ignoring java.home settings
jjg
parents:
735
diff
changeset
|
605 |
srcdir="${make.tools.dir}/CompileProperties" |
10 | 606 |
destdir="${build.toolclasses.dir}/" |
607 |
classpath="${ant.home}/lib/ant.jar"/> |
|
608 |
<taskdef name="pcompile" |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
609 |
classname="CompilePropertiesTask" |
10 | 610 |
classpath="${build.toolclasses.dir}/"/> |
611 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
612 |
|
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
613 |
<target name="-def-genstubs" depends="build-bootstrap-javac"> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
614 |
<mkdir dir="${build.toolclasses.dir}"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
615 |
<javac fork="true" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
616 |
source="${boot.javac.source}" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
617 |
target="${boot.javac.target}" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
618 |
executable="${boot.java.home}/bin/javac" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
619 |
srcdir="${make.tools.dir}/GenStubs" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
620 |
destdir="${build.toolclasses.dir}/" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
621 |
classpath="${build.bootstrap.dir}/classes:${ant.home}/lib/ant.jar"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
622 |
<taskdef name="genstubs" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
623 |
classname="GenStubs$$Ant" |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
624 |
classpath="${build.toolclasses.dir}/"/> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
625 |
</target> |
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
626 |
|
10 | 627 |
<target name="-def-javadoc-tool" depends="-check-target.java.home"> |
628 |
<macrodef name="javadoc-tool"> |
|
629 |
<attribute name="name"/> |
|
630 |
<attribute name="includes"/> |
|
631 |
<attribute name="options" default=""/> |
|
632 |
<attribute name="source" default="1.5"/> <!-- FIXME --> |
|
633 |
<sequential> |
|
634 |
<property name="javadoc.options" value=""/> <!-- default, can be overridden per user or per project --> |
|
635 |
<!-- Note: even with this default value, includes |
|
636 |
from src.classes.dir get javadoc'd; see packageset below --> |
|
637 |
<property name="javadoc.packagenames" value="none"/> <!-- default, can be overridden per user or per project --> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
638 |
<javadoc |
10 | 639 |
executable="${target.java.home}/bin/javadoc" |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
640 |
destdir="${build.javadoc.dir}/@{name}" |
10 | 641 |
source="@{source}" |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
642 |
windowtitle="UNOFFICIAL" |
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
643 |
failonerror="true" |
10 | 644 |
use="true" |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
645 |
author="false" |
10 | 646 |
version="false" |
647 |
packagenames="${javadoc.packagenames}" > |
|
648 |
<header><![CDATA[<strong>Unofficial Javadoc</strong> generated from developer sources for preview purposes only]]></header> |
|
649 |
<arg line="@{options}"/> |
|
650 |
<bootclasspath> |
|
651 |
<path location="${build.classes.dir}"/> |
|
652 |
<path location="${target.java.home}/jre/lib/rt.jar"/> |
|
653 |
</bootclasspath> |
|
654 |
<sourcepath> |
|
655 |
<pathelement location="${src.classes.dir}"/> |
|
656 |
</sourcepath> |
|
657 |
<!-- XXX just <fileset> (restricted further to **/*.java) and no <packageset> --> |
|
658 |
<!-- means that {@link some.package} will not work, which is no good. --> |
|
659 |
<!-- (It correctly skips excluded single classes, but not if packageset is also included, --> |
|
660 |
<!-- which also causes duplicates in the class index for included files.) --> |
|
661 |
<packageset dir="${src.classes.dir}" includes="@{includes}"> |
|
662 |
<or> |
|
663 |
<filename name="java/"/> |
|
664 |
<filename name="javax/"/> |
|
665 |
<filename name="com/sun/javadoc/"/> |
|
666 |
<filename name="com/sun/mirror/"/> |
|
667 |
<filename name="com/sun/source/"/> |
|
668 |
</or> |
|
669 |
</packageset> |
|
670 |
</javadoc> |
|
671 |
</sequential> |
|
672 |
</macrodef> |
|
673 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
674 |
|
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
675 |
<target name="-def-jtreg" unless="jtreg.defined" depends="-check-jtreg.home,-check-target.java.home"> |
10 | 676 |
<taskdef name="jtreg" classname="com.sun.javatest.regtest.Main$$Ant"> |
677 |
<classpath> |
|
678 |
<pathelement location="${jtreg.home}/lib/jtreg.jar"/> |
|
679 |
<pathelement location="${jtreg.home}/lib/javatest.jar"/> |
|
680 |
</classpath> |
|
681 |
</taskdef> |
|
682 |
<macrodef name="jtreg-tool"> |
|
683 |
<attribute name="name"/> |
|
684 |
<attribute name="tests"/> |
|
685 |
<attribute name="jdk" default="${target.java.home}"/> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
686 |
<attribute name="samevm" default="true"/> |
10 | 687 |
<attribute name="verbose" default="summary"/> |
688 |
<attribute name="options" default=""/> |
|
689 |
<attribute name="keywords" default="-keywords:!ignore"/> |
|
690 |
<attribute name="jpda.jvmargs" default=""/> |
|
691 |
<sequential> |
|
692 |
<property name="coverage.options" value=""/> <!-- default --> |
|
693 |
<property name="coverage.classpath" value=""/> <!-- default --> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
694 |
<jtreg |
10 | 695 |
dir="${test.dir}" |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
696 |
workDir="${build.jtreg.dir}/@{name}/work" |
10 | 697 |
reportDir="${build.jtreg.dir}/@{name}/report" |
698 |
jdk="@{jdk}" |
|
699 |
samevm="@{samevm}" verbose="@{verbose}" |
|
700 |
failonerror="false" resultproperty="jtreg.@{name}.result" |
|
701 |
javacoptions="-g" |
|
702 |
vmoptions="${coverage.options} -Xbootclasspath/p:${coverage.classpath}:${build.classes.dir} @{jpda.jvmargs}"> |
|
703 |
<arg line="@{keywords}"/> |
|
704 |
<arg line="@{options}"/> |
|
705 |
<arg line="@{tests}"/> |
|
706 |
</jtreg> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
707 |
<!-- the next two properties are for convenience, when only |
10 | 708 |
a single instance of jtreg will be invoked. --> |
709 |
<condition property="jtreg.passed"> |
|
1873
658385834998
6795365: NetBeans projects in langtools repository are not NB6.5-friendly
jjg
parents:
1872
diff
changeset
|
710 |
<equals arg1="${jtreg.@{name}.result}" arg2="0"/> |
10 | 711 |
</condition> |
712 |
<property name="jtreg.report" value="${build.jtreg.dir}/@{name}/report"/> |
|
713 |
</sequential> |
|
714 |
</macrodef> |
|
715 |
<property name="jtreg.defined" value="true"/> |
|
716 |
</target> |
|
717 |
||
718 |
<target name="-def-cobertura" depends="-check-cobertura.home"> |
|
719 |
<path id="cobertura.classpath"> |
|
720 |
<fileset dir="${cobertura.home}"> |
|
721 |
<include name="cobertura.jar"/> |
|
722 |
<include name="lib/**/*.jar"/> |
|
723 |
</fileset> |
|
724 |
</path> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
725 |
<taskdef classpathref="cobertura.classpath" resource="tasks.properties"/> |
10 | 726 |
</target> |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
727 |
|
10 | 728 |
<target name="-def-findbugs" unless="findbugs.defined" depends="-check-findbugs.home"> |
729 |
<taskdef name="findbugs" classname="edu.umd.cs.findbugs.anttask.FindBugsTask"> |
|
730 |
<classpath> |
|
731 |
<pathelement location="${findbugs.home}/lib/findbugs.jar"/> |
|
732 |
</classpath> |
|
733 |
</taskdef> |
|
734 |
<macrodef name="findbugs-tool"> |
|
735 |
<attribute name="name"/> |
|
736 |
<attribute name="output" default="emacs"/> |
|
737 |
<attribute name="outputFile" default=""/> |
|
738 |
<attribute name="reportLevel" default="high"/> |
|
739 |
<sequential> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
740 |
<findbugs |
10 | 741 |
home="${findbugs.home}" |
742 |
output="@{output}" |
|
743 |
outputFile="@{outputFile}" |
|
744 |
reportLevel="@{reportLevel}" |
|
745 |
failOnError="false" |
|
746 |
errorProperty="findbugs.@{name}.errors" |
|
747 |
warningsProperty="findbugs.@{name}.warnings" |
|
748 |
jvmargs="-Xmx512M" > |
|
749 |
<class location="${dist.dir}/lib/@{name}.jar"/> |
|
750 |
<auxClasspath> |
|
751 |
<pathelement location="${build.classes.dir}"/> |
|
752 |
</auxClasspath> |
|
753 |
<sourcePath> |
|
754 |
<pathelement location="${src.classes.dir}"/> |
|
755 |
</sourcePath> |
|
756 |
</findbugs> |
|
757 |
</sequential> |
|
758 |
</macrodef> |
|
759 |
<property name="findbugs.defined" value="true"/> |
|
760 |
</target> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
761 |
|
10 | 762 |
<target name="-def-check"> |
763 |
<macrodef name="check"> |
|
764 |
<attribute name="name"/> |
|
765 |
<attribute name="property"/> |
|
766 |
<attribute name="marker"/> |
|
767 |
<sequential> |
|
768 |
<fail message="Cannot locate @{name}: please set @{property} to its location"> |
|
769 |
<condition> |
|
770 |
<not> |
|
771 |
<isset property="@{property}"/> |
|
772 |
</not> |
|
773 |
</condition> |
|
774 |
</fail> |
|
775 |
<fail message="@{name} is not installed in ${@{property}}"> |
|
776 |
<condition> |
|
777 |
<not> |
|
778 |
<available file="${@{property}}/@{marker}"/> |
|
779 |
</not> |
|
780 |
</condition> |
|
781 |
</fail> |
|
782 |
</sequential> |
|
783 |
</macrodef> |
|
784 |
</target> |
|
785 |
||
786 |
<!-- standard JDK target --> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
787 |
<target name="sanity" |
4415
7d4f73717fba
6902337: fix langtools build to allow forward refs into jdk/ repo
jjg
parents:
4414
diff
changeset
|
788 |
description="display settings of configuration values"> |
10 | 789 |
<echo level="info">ant.home = ${ant.home}</echo> |
790 |
<echo level="info">boot.java.home = ${boot.java.home}</echo> |
|
791 |
<echo level="info">target.java.home = ${target.java.home}</echo> |
|
792 |
<echo level="info">jtreg.home = ${jtreg.home}</echo> |
|
793 |
<echo level="info">findbugs.home = ${findbugs.home}</echo> |
|
794 |
</target> |
|
795 |
||
796 |
<!-- useful debugging targets --> |
|
797 |
<target name="diagnostics"> |
|
798 |
<diagnostics/> |
|
799 |
</target> |
|
800 |
||
801 |
<target name="post-sanity" depends="-def-jtreg,sanity,build" |
|
802 |
description="perform basic validation after a standard build"> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
803 |
<jtreg |
10 | 804 |
dir="make/test" |
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
805 |
workDir="${build.jtreg.dir}/post-sanity/work" |
10 | 806 |
reportDir="${build.jtreg.dir}/post-sanity/report" |
807 |
jdk="${target.java.home}" |
|
808 |
verbose="summary" |
|
809 |
failonerror="false" resultproperty="jtreg.post-sanity.result"> |
|
810 |
</jtreg> |
|
3655
f9ee66e780f4
6758471: should be able to set jtreg options in langtools build
jjg
parents:
3654
diff
changeset
|
811 |
|
10 | 812 |
</target> |
813 |
</project> |
|
814 |