ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/build.xml
(Generate patch)

Comparing jsr166/build.xml (file contents):
Revision 1.149 by jsr166, Sat Jul 20 20:40:24 2013 UTC vs.
Revision 1.159 by jsr166, Fri Oct 3 23:18:13 2014 UTC

# Line 16 | Line 16
16    $HOME/jdk/jdk6
17    $HOME/jdk/jdk7
18    $HOME/jdk/jdk8
19 +  $HOME/jdk/jdk9
20    where each of the above is a JDK or a symlink to same, and
21    $HOME/jdk/src/jdk6
22    $HOME/jdk/src/jdk7
23    $HOME/jdk/src/jdk8
24 +  $HOME/jdk/src/jdk9
25    where each of the above is a complete JDK source tree
26    (e.g. mercurial forest) or a symlink to same.
27 < As of 2013-02, the very latest lambda 8 jdk is needed for jdk8.
27 >
28 >  Alternatively, define ant variables thus:
29 >  ant -Djdk$N.home=...
30 >  for $N in 6 7 8 9 ...
31   ------------------------------------------------------------------------------
32    </description>
33  
# Line 45 | Line 50 | As of 2013-02, the very latest lambda 8
50    <property name="build.deprecation"    value="false"/>
51    <property name="build.javadoc.access" value="protected"/>
52  
53 <  <!-- Tck options; see JSR166TestCase.java -->
54 <  <!-- ant -Djsr166.profileTests=true -Djsr166.runsPerTest=100 test-tck -->
53 >  <!-- Tck options; see JSR166TestCase.java
54 >   To profile a single tck test class:
55 >   ant -Djsr166.profileTests=true -Djsr166.profileThreshold=100 -Djsr166.tckTestClass=CompletableFutureTest test-tck
56 >   To stress test a single tck test class:
57 >   ant -Djsr166.tckTestClass=CountedCompleterTest -Djsr166.runsPerTest=100 test-tck
58 >  -->
59    <property name="jsr166.profileTests"     value="false"/>
60    <property name="jsr166.profileThreshold" value="100"/>
61    <property name="jsr166.runsPerTest"      value="1"/>
53  <!-- Allow running an individual tck test class -->
54  <!-- ant -Djsr166.tckTestClass=CountedCompleterTest -Djsr166.runsPerTest=100 test-tck -->
62    <property name="jsr166.tckTestClass"     value="JSR166TestCase"/>
63  
64    <!-- Build locations -->
# Line 115 | Line 122 | As of 2013-02, the very latest lambda 8
122    <defjdklocations v="6"/>
123    <defjdklocations v="7"/>
124    <defjdklocations v="8"/>
125 +  <defjdklocations v="9"/>
126  
127    <!-- Source locations -->
128    <property name="src.dir"              location="${basedir}/src/main"/>
# Line 155 | Line 163 | As of 2013-02, the very latest lambda 8
163    <property name="extra166y.jar"    location="${build.extra166y.dir}/extra166y.jar"/>
164    <property name="junit.jar"        location="${lib.dir}/junit.jar"/>
165  
166 <  <!-- Canonical location of jdk API docs, to use with javadoc link attribute -->
167 <  <property name="jdkapi5docs.url"      value="http://docs.oracle.com/javase/1.5.0/docs/api/"/>
168 <  <property name="jdkapi6docs.url"      value="http://docs.oracle.com/javase/6/docs/api/"/>
169 <  <property name="jdkapi7docs.url"      value="http://docs.oracle.com/javase/7/docs/api/"/>
170 <
171 <  <property name="jdkapi8docs.url"      value="http://download.java.net/jdk8/docs/api/"/>
172 <  <!-- The below does not yet exist as of 2013-01 -->
173 <  <!-- <property name="jdkapi8docs.url" value="http://docs.oracle.com/javase/8/docs/api/"/> -->
166 >  <!-- Canonical location of jdk docs root, to use with javadoc -Xdocrootparent flag -->
167 >  <property name="java5.docroot.url"      value="http://docs.oracle.com/javase/1.5.0/docs"/>
168 >  <property name="java6.docroot.url"      value="http://docs.oracle.com/javase/6/docs"/>
169 >  <property name="java7.docroot.url"      value="http://docs.oracle.com/javase/7/docs"/>
170 >  <property name="java8.docroot.url"      value="http://docs.oracle.com/javase/8/docs"/>
171 >  <!-- The expected canonical location does not yet exist as of 2014-07 -->
172 >  <!-- <property name="java9.docroot.url" value="http://docs.oracle.com/javase/9/docs"/> -->
173 >  <property name="java9.docroot.url"      value="http://download.java.net/jdk9/docs"/>
174 >  <!-- Default jdk doc location (latest stable release seems best) -->
175 >  <property name="java.docroot.url"       value="${java8.docroot.url}"/>
176  
177 <  <!-- Default jdk api doc location (latest stable release seems best) -->
178 <  <property name="jdkapidocs.url"       value="${jdkapi7docs.url}"/>
177 >  <!-- Canonical location of jdk API docs, to use with javadoc link attribute -->
178 >  <property name="java5.api.url"      value="${java5.docroot.url}/api/"/>
179 >  <property name="java6.api.url"      value="${java6.docroot.url}/api/"/>
180 >  <property name="java7.api.url"      value="${java7.docroot.url}/api/"/>
181 >  <property name="java8.api.url"      value="${java8.docroot.url}/api/"/>
182 >  <property name="java9.api.url"      value="${java9.docroot.url}/api/"/>
183 >  <property name="java.api.url"       value="${java.docroot.url}/api/"/>
184  
185    <!-- Define the "jtreg" task -->
186    <!-- See the docs in "jtreg -onlineHelp" -->
# Line 184 | Line 199 | As of 2013-02, the very latest lambda 8
199      <attribute name="compile-target" default="@{target}"/>
200      <attribute name="workdir"/>
201      <attribute name="classes"/>
202 <    <attribute name="jvmflags" default=""/>
202 >    <attribute name="jvmflags" default="-ea -esa -Djsr166.testImplementationDetails=true"/>
203      <element name="javac-elements" optional="true"/>
204      <sequential>
205  
# Line 231 | Line 246 | As of 2013-02, the very latest lambda 8
246    </macrodef>
247  
248    <macrodef name="run-jtreg-tests">
249 +    <!-- ant -Djtreg.src.dir=src/test/jtreg/util/concurrent/CompletableFuture test-jtreg -->
250      <attribute name="jtreg.src.dir" default="${jtreg.src.dir}"/>
251      <attribute name="source" default="7"/>
252      <attribute name="target"/>
# Line 269 | Line 285 | As of 2013-02, the very latest lambda 8
285  
286    <!-- Main targets -->
287  
288 +  <property name="build.main.java.version" value="9"/>
289 +  <property name="build.main.javac" value="${javac9}"/>
290 +
291    <target name="dists"
292            depends="dist, 4jdk7dist, jsr166edist, jsr166ydist, extra166ydist, jsr166xdist"
293            description="Builds all public jars and docs"/>
# Line 287 | Line 306 | As of 2013-02, the very latest lambda 8
306             classpath=""
307             includeAntRuntime="false"
308             includeJavaRuntime="false"
309 <           executable="${javac8}"
309 >           executable="${build.main.javac}"
310             fork="true">
311  
312        <include name="**/*.java"/>
# Line 323 | Line 342 | As of 2013-02, the very latest lambda 8
342  
343      <javadoc destdir="${docs.dir}"
344               packagenames="none"
345 <             link="${jdkapi8docs.url}"
345 >             link="${java9.api.url}"
346               overview="${src.dir}/intro.html"
347               access="${build.javadoc.access}"
348 <             sourcepath="${src.dir}:${jdk8src.dir}"
348 >             sourcepath="${src.dir}:${jdk9src.dir}"
349               classpath=""
350 <             executable="${javadoc8}">
350 >             executable="${javadoc9}">
351        <fileset dir="${src.dir}" defaultexcludes="yes">
352          <include name="**/*.java"/>
353        </fileset>
354 +      <arg line="-Xdocrootparent ${java9.docroot.url}"/>
355        <arg line="-Xmaxerrs 1000 -Xmaxwarns 1000"/>
356        <arg value="-XDignore.symbol.file=true"/>
357        <arg value="-tag"/>
# Line 402 | Line 422 | As of 2013-02, the very latest lambda 8
422            description="Runs tck tests for main directly">
423  
424      <run-tck-tests
425 <      target="8"
425 >      target="${build.main.java.version}"
426        workdir="${build.dir}"
427        classes="${product.jar}"/>
428    </target>
# Line 411 | Line 431 | As of 2013-02, the very latest lambda 8
431            depends="jar"
432            description="Runs jtreg tests for main using the jtreg ant task">
433      <run-jtreg-tests
434 <       target="8"
434 >       target="${build.main.java.version}"
435         workdir="${build.dir}"
436         classes="${product.jar}"/>
437    </target>
# Line 421 | Line 441 | As of 2013-02, the very latest lambda 8
441            description="Runs tck and jtreg tests for main">
442    </target>
443  
444 +  <target name="test89"
445 +          description="Runs tck and jtreg tests for main for multiple java versions">
446 +
447 +    <antcall target="clean"/>
448 +    <antcall target="test">
449 +      <param name="build.main.java.version" value="8"/>
450 +      <param name="build.main.javac" value="${javac8}"/>
451 +    </antcall>
452 +
453 +    <antcall target="clean"/>
454 +    <antcall target="test">
455 +      <param name="build.main.java.version" value="9"/>
456 +      <param name="build.main.javac" value="${javac9}"/>
457 +    </antcall>
458 +
459 +  </target>
460 +
461  
462  
463    <target name="configure-compiler">
# Line 552 | Line 589 | As of 2013-02, the very latest lambda 8
589        <javac-elements>
590          <!-- JDK8+ test classes -->
591          <exclude name="*8Test.java"/>
592 +        <exclude name="*9Test.java"/>
593          <exclude name="DoubleAccumulatorTest.java"/>
594          <exclude name="DoubleAdderTest.java"/>
595          <exclude name="LongAccumulatorTest.java"/>
# Line 617 | Line 655 | As of 2013-02, the very latest lambda 8
655  
656      <javadoc destdir="${4jdk7docs.dir}"
657               packagenames="none"
658 <             link="${jdkapi7docs.url}"
658 >             link="${java7.api.url}"
659               overview="${4jdk7src.dir}/intro.html"
660               access="${build.javadoc.access}"
661               sourcepath="${4jdk7src.dir}:${jdk7src.dir}"
# Line 626 | Line 664 | As of 2013-02, the very latest lambda 8
664        <fileset dir="${4jdk7src.dir}" defaultexcludes="yes">
665          <include name="**/*.java"/>
666        </fileset>
667 +      <arg line="-Xdocrootparent ${java7.docroot.url}"/>
668        <arg value="-XDignore.symbol.file=true"/>
669      </javadoc>
670    </target>
# Line 705 | Line 744 | As of 2013-02, the very latest lambda 8
744  
745      <javadoc destdir="${jsr166xdocs.dir}"
746               packagenames="jsr166x.*"
747 <             link="${jdkapidocs.url}"
747 >             link="${java.api.url}"
748               access="${build.javadoc.access}"
749               sourcepath="${topsrc.dir}:${jdk6src.dir}"
750               bootclasspath="${bootclasspath6}"
751               source="5"
752               executable="${javadoc7}">
753 +      <arg line="-Xdocrootparent ${java.docroot.url}"/>
754        <arg value="-XDignore.symbol.file=true"/>
755  
756      </javadoc>
# Line 790 | Line 830 | As of 2013-02, the very latest lambda 8
830  
831      <javadoc destdir="${jsr166ydocs.dir}"
832               packagenames="jsr166y.*"
833 <             link="${jdkapidocs.url}"
833 >             link="${java.api.url}"
834               access="${build.javadoc.access}"
835               sourcepath="${topsrc.dir}:${jdk6src.dir}"
836               bootclasspath="${bootclasspath6}"
837               source="6"
838               executable="${javadoc7}">
839 +      <arg line="-Xdocrootparent ${java.docroot.url}"/>
840        <arg value="-XDignore.symbol.file=true"/>
841  
842      </javadoc>
# Line 876 | Line 917 | As of 2013-02, the very latest lambda 8
917  
918      <javadoc destdir="${extra166ydocs.dir}"
919               packagenames="extra166y.*"
920 <             link="${jdkapidocs.url}"
920 >             link="${java.api.url}"
921               access="${build.javadoc.access}"
922               sourcepath="${topsrc.dir}:${jdk6src.dir}"
923               bootclasspath="${bootclasspath6}"
924               source="6"
925               executable="${javadoc7}">
926 +      <arg line="-Xdocrootparent ${java.docroot.url}"/>
927        <arg value="-XDignore.symbol.file=true"/>
928  
929      </javadoc>
# Line 942 | Line 984 | As of 2013-02, the very latest lambda 8
984      </javac>
985    </target>
986  
987 +  <!-- jsr166e: find doclint errors -->
988 +  <target name="jsr166edoclint">
989 +
990 +    <mkdir dir="${build.jsr166e.classes.dir}"/>
991 +
992 +    <javac srcdir="${topsrc.dir}"
993 +           destdir="${build.jsr166e.classes.dir}"
994 +           debug="${build.debug}"
995 +           debuglevel="${build.debuglevel}"
996 +           deprecation="${build.deprecation}"
997 +           source="${build.jsr166e.java.version}"
998 +           classpath=""
999 +           bootclasspath="${bootclasspath7}"
1000 +           includeAntRuntime="false"
1001 +           includeJavaRuntime="false"
1002 +           executable="${javac8}"
1003 +           fork="true">
1004 +
1005 +      <include name="jsr166e/**/*.java"/>
1006 +      <compilerarg value="-XDignore.symbol.file=true"/>
1007 +      <compilerarg value="-Xlint:all"/>
1008 +      <compilerarg value="-Xdoclint:all/protected"/>
1009 +
1010 +    </javac>
1011 +  </target>
1012 +
1013  
1014    <target name="jsr166ejar"
1015            depends="jsr166ecompile"
# Line 962 | Line 1030 | As of 2013-02, the very latest lambda 8
1030  
1031      <javadoc destdir="${jsr166edocs.dir}"
1032               packagenames="jsr166e.*"
1033 <             link="${jdkapidocs.url}"
1033 >             link="${java.api.url}"
1034               access="${build.javadoc.access}"
1035               sourcepath="${topsrc.dir}:${jdk6src.dir}"
1036               source="${build.jsr166e.java.version}"
1037               executable="${javadoc7}">
1038 +      <arg line="-Xdocrootparent ${java.docroot.url}"/>
1039        <arg value="-XDignore.symbol.file=true"/>
1040  
1041      </javadoc>

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines