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.232 by jsr166, Wed Feb 1 18:26:31 2017 UTC vs.
Revision 1.237 by jsr166, Fri Mar 24 15:57:26 2017 UTC

# Line 253 | Line 253
253        <include name="*.java"/>
254        <compilerarg value="-XDignore.symbol.file=true"/>
255        <compilerarg value="-Xlint:all,-unchecked,-rawtypes,-serial,-deprecation,-try"/>
256 +      <compilerarg value="-Xdoclint:reference/private"/>
257        <compilerarg value="-Xbootclasspath/p:@{classes}" unless:set="modules"/>
258 <      <compilerarg line="--patch-module java.base=@{classes}" if:set="modules"/>
258 >      <compilerarg value="--patch-module=java.base=@{classes}" if:set="modules"/>
259        <compilerarg line="${build.args}"/>
260        <javac-elements/>
261  
# Line 265 | Line 266
266            jvm="${java@{target}}"
267            fork="true">
268          <jvmarg value="-Xbootclasspath/p:@{classes}" unless:set="modules"/>
269 <        <jvmarg line="--patch-module java.base=@{classes}" if:set="modules"/>
270 <        <jvmarg line="--add-opens java.base/java.lang=ALL-UNNAMED" if:set="modules"/>
271 <        <jvmarg line="--add-opens java.base/java.util=ALL-UNNAMED" if:set="modules"/>
272 <        <jvmarg line="--add-opens java.base/java.util.concurrent=ALL-UNNAMED" if:set="modules"/>
273 <        <jvmarg line="--add-opens java.base/java.util.concurrent.atomic=ALL-UNNAMED" if:set="modules"/>
274 <        <jvmarg line="--add-opens java.base/java.util.concurrent.locks=ALL-UNNAMED" if:set="modules"/>
269 >        <jvmarg value="--patch-module=java.base=@{classes}" if:set="modules"/>
270 >        <jvmarg value="--add-opens=java.base/java.lang=ALL-UNNAMED" if:set="modules"/>
271 >        <jvmarg value="--add-opens=java.base/java.util=ALL-UNNAMED" if:set="modules"/>
272 >        <jvmarg value="--add-opens=java.base/java.util.concurrent=ALL-UNNAMED" if:set="modules"/>
273 >        <jvmarg value="--add-opens=java.base/java.util.concurrent.atomic=ALL-UNNAMED" if:set="modules"/>
274 >        <jvmarg value="--add-opens=java.base/java.util.concurrent.locks=ALL-UNNAMED" if:set="modules"/>
275          <jvmarg line="@{jvmflags}"/>
276          <!-- ant -Dvmoptions="-Xmx8m" -Djsr166.tckTestClass=CompletableFutureTest tck -->
277          <jvmarg line="${vmoptions}" if:set="vmoptions"/>
# Line 400 | Line 401
401             fork="true">
402  
403        <include name="**/*.java"/>
404 <      <compilerarg value="-Xmodule:java.base" if:set="modules"/>
404 >      <compilerarg value="--patch-module=java.base=${src.dir}" if:set="modules"/>
405        <compilerarg value="-Xprefer:source"/>
406        <compilerarg value="-XDignore.symbol.file=true"/>
407        <compilerarg value="-Xlint:all"/>
408        <compilerarg value="-Werror"/>
409 <      <compilerarg value="-Xdoclint:all/protected"/>
409 >      <compilerarg value="-Xdoclint:all/protected,reference/private"/>
410        <compilerarg line="-Xmaxerrs 1000 -Xmaxwarns 1000"/>
411        <compilerarg line="${build.args}"/>
412  
# Line 456 | Line 457
457        <arg line="-Xdocrootparent ${java9.docroot.url}"/>
458        <arg line="-Xmaxerrs 1000 -Xmaxwarns 1000"/>
459        <arg value="-XDignore.symbol.file=true"/>
460 <      <arg value="-Xmodule:java.base"/>
460 >      <arg value="--patch-module=java.base=${src.dir}"/>
461        <arg value="-tag"/>
462        <arg value="${javadoc.jls.option}"/>
463   <!-- @apiNote currently unused -->
# Line 536 | Line 537
537      <run-tck-tests
538        target="${build.main.java.version}"
539        workdir="${build.dir}"
540 <      classes="${product.jar}"/>
540 >      classes="${product.jar}">
541 >      <javac-elements>
542 >        <compilerarg value="-Werror"/>
543 >      </javac-elements>
544 >    </run-tck-tests>
545    </target>
546  
547    <target name="tck-parallelism-1"
# Line 604 | Line 609
609  
610    <target name="configure-compiler">
611      <fail message="ant version too old">
612 <      <condition>
608 <        <not> <antversion atleast="1.9.1"/> </not>
609 <      </condition>
612 >      <condition> <not> <antversion atleast="1.9.1"/> </not> </condition>
613      </fail>
614  
615      <property name="unchecked.option" value="-Xlint:unchecked"/>
# Line 741 | Line 744
744        <compilerarg value="-Xprefer:source"/>
745        <compilerarg value="-XDignore.symbol.file=true"/>
746        <compilerarg value="-Xlint:all"/>
747 <      <compilerarg value="-Xdoclint:all/protected"/>
747 >      <compilerarg value="-Xdoclint:all/protected,reference/private"/>
748        <compilerarg line="${build.args}"/>
749  
750      </javac>
# Line 775 | Line 778
778          <!-- JDK9+ test classes -->
779          <exclude name="*9Test.java"/>
780          <exclude name="*10Test.java"/>
781 +        <compilerarg value="-Werror"/>
782        </javac-elements>
783      </run-tck-tests>
784    </target>
# Line 956 | Line 960
960          <exclude name="SplittableRandomTest.java"/>
961          <exclude name="StampedLockTest.java"/>
962          <exclude name="SubmissionPublisherTest.java"/>
963 +        <compilerarg value="-Werror"/>
964        </javac-elements>
965      </run-tck-tests>
966    </target>
# Line 1510 | Line 1515
1515      </antcall>
1516    </target>
1517  
1518 +
1519 + <!-- ==============================================================
1520 +  Experimental errorprone support - http://errorprone.info
1521 +  You may need to bring your own errorprone jar.
1522 + =================================================================== -->
1523 +  <target name="errorprone"
1524 +          depends="clean, configure-compiler"
1525 +          description="Run errorprone over jsr166 source code">
1526 +
1527 +    <local name="destdir"/>
1528 +    <property name="destdir" value="${build.classes.dir}/java.base"/>
1529 +    <mkdir dir="${destdir}"/>
1530 +
1531 +    <javac srcdir="${src.dir}"
1532 +           destdir="${destdir}"
1533 +           debug="${build.debug}"
1534 +           debuglevel="${build.debuglevel}"
1535 +           deprecation="${build.deprecation}"
1536 +           classpath=""
1537 +           includeAntRuntime="false"
1538 +           includeJavaRuntime="false"
1539 +           encoding="ASCII"
1540 +           executable="${build.main.javac}"
1541 +           fork="true">
1542 +
1543 +      <include name="**/*.java"/>
1544 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED"/>
1545 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"/>
1546 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED"/>
1547 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"/>
1548 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED"/>
1549 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED"/>
1550 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED"/>
1551 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/>
1552 +      <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/>
1553 +      <compilerarg line="-processorpath ${lib.dir}/error_prone_ant-2.0.20-SNAPSHOT.jar"/>
1554 +      <compilerarg value="-Xplugin:ErrorProne
1555 +                          -Xep:IdentityBinaryExpression:WARN
1556 +                          -Xep:MissingOverride:OFF
1557 +                          -Xep:MixedArrayDimensions:WARN
1558 +                          -Xep:RemoveUnusedImports:ERROR
1559 +                          -Xep:MethodCanBeStatic:WARN"/>
1560 +      <compilerarg value="--patch-module=java.base=${src.dir}"/>
1561 +      <compilerarg value="-Xprefer:source"/>
1562 +      <compilerarg value="-XDignore.symbol.file=true"/>
1563 +      <compilerarg value="-Xlint:all"/>
1564 +      <compilerarg value="-Xdoclint:all/protected,reference/private"/>
1565 +      <compilerarg line="-Xmaxerrs 3000 -Xmaxwarns 3000"/>
1566 +      <compilerarg line="${build.args}"/>
1567 +    </javac>
1568 +
1569 +    <jar destfile="${product.jar}">
1570 +      <fileset dir="${destdir}"/>
1571 +    </jar>
1572 +
1573 +    <run-tck-tests
1574 +      target="${build.main.java.version}"
1575 +      workdir="${build.dir}"
1576 +      classes="${product.jar}">
1577 +      <javac-elements>
1578 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED"/>
1579 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"/>
1580 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED"/>
1581 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"/>
1582 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED"/>
1583 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED"/>
1584 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED"/>
1585 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/>
1586 +        <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/>
1587 +        <compilerarg line="-processorpath ${lib.dir}/error_prone_ant-2.0.20-SNAPSHOT.jar"/>
1588 +        <compilerarg value="-Xplugin:ErrorProne
1589 +                            -Xep:IdentityBinaryExpression:WARN
1590 +                            -Xep:BoxedPrimitiveConstructor:OFF
1591 +                            -Xep:HashtableContains:OFF
1592 +                            -Xep:ModifyingCollectionWithItself:OFF
1593 +                            -Xep:MissingOverride:OFF
1594 +                            -Xep:MixedArrayDimensions:WARN
1595 +                            -Xep:RemoveUnusedImports:ERROR
1596 +                            -Xep:MethodCanBeStatic:WARN"/>
1597 +        <compilerarg line="-Xmaxerrs 3000 -Xmaxwarns 3000"/>
1598 +      </javac-elements>
1599 +    </run-tck-tests>
1600 +  </target>
1601 +
1602 +
1603   <!-- ==============================================================
1604    Running guava tests against jsr166 code
1605   =================================================================== -->

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines