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.236 by jsr166, Mon Mar 20 00:03:57 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 741 | Line 746
746        <compilerarg value="-Xprefer:source"/>
747        <compilerarg value="-XDignore.symbol.file=true"/>
748        <compilerarg value="-Xlint:all"/>
749 <      <compilerarg value="-Xdoclint:all/protected"/>
749 >      <compilerarg value="-Xdoclint:all/protected,reference/private"/>
750        <compilerarg line="${build.args}"/>
751  
752      </javac>
# Line 775 | Line 780
780          <!-- JDK9+ test classes -->
781          <exclude name="*9Test.java"/>
782          <exclude name="*10Test.java"/>
783 +        <compilerarg value="-Werror"/>
784        </javac-elements>
785      </run-tck-tests>
786    </target>
# Line 956 | Line 962
962          <exclude name="SplittableRandomTest.java"/>
963          <exclude name="StampedLockTest.java"/>
964          <exclude name="SubmissionPublisherTest.java"/>
965 +        <compilerarg value="-Werror"/>
966        </javac-elements>
967      </run-tck-tests>
968    </target>
# Line 1510 | Line 1517
1517      </antcall>
1518    </target>
1519  
1520 +
1521 + <!-- ==============================================================
1522 +  Experimental errorprone support - http://errorprone.info
1523 +  You may need to bring your own errorprone jar.
1524 + =================================================================== -->
1525 +  <target name="errorprone"
1526 +          depends="clean, configure-compiler"
1527 +          description="Run errorprone over jsr166 source code">
1528 +
1529 +    <local name="destdir"/>
1530 +    <property name="destdir" value="${build.classes.dir}/java.base"/>
1531 +    <mkdir dir="${destdir}"/>
1532 +
1533 +    <javac srcdir="${src.dir}"
1534 +           destdir="${destdir}"
1535 +           debug="${build.debug}"
1536 +           debuglevel="${build.debuglevel}"
1537 +           deprecation="${build.deprecation}"
1538 +           classpath=""
1539 +           includeAntRuntime="false"
1540 +           includeJavaRuntime="false"
1541 +           encoding="ASCII"
1542 +           executable="${build.main.javac}"
1543 +           fork="true">
1544 +
1545 +      <include name="**/*.java"/>
1546 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED"/>
1547 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"/>
1548 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED"/>
1549 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"/>
1550 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED"/>
1551 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED"/>
1552 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED"/>
1553 +      <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/>
1554 +      <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/>
1555 +      <compilerarg line="-processorpath ${lib.dir}/error_prone_ant-2.0.20-SNAPSHOT.jar"/>
1556 +      <compilerarg value="-Xplugin:ErrorProne
1557 +                          -Xep:IdentityBinaryExpression:WARN
1558 +                          -Xep:MissingOverride:OFF
1559 +                          -Xep:MixedArrayDimensions:WARN
1560 +                          -Xep:RemoveUnusedImports:ERROR
1561 +                          -Xep:MethodCanBeStatic:WARN"/>
1562 +      <compilerarg value="--patch-module=java.base=${src.dir}"/>
1563 +      <compilerarg value="-Xprefer:source"/>
1564 +      <compilerarg value="-XDignore.symbol.file=true"/>
1565 +      <compilerarg value="-Xlint:all"/>
1566 +      <compilerarg value="-Xdoclint:all/protected,reference/private"/>
1567 +      <compilerarg line="-Xmaxerrs 3000 -Xmaxwarns 3000"/>
1568 +      <compilerarg line="${build.args}"/>
1569 +    </javac>
1570 +
1571 +    <jar destfile="${product.jar}">
1572 +      <fileset dir="${destdir}"/>
1573 +    </jar>
1574 +
1575 +    <run-tck-tests
1576 +      target="${build.main.java.version}"
1577 +      workdir="${build.dir}"
1578 +      classes="${product.jar}">
1579 +      <javac-elements>
1580 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED"/>
1581 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"/>
1582 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED"/>
1583 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED"/>
1584 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED"/>
1585 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED"/>
1586 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED"/>
1587 +        <compilerarg value="-J--add-exports=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/>
1588 +        <compilerarg value="-J--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED"/>
1589 +        <compilerarg line="-processorpath ${lib.dir}/error_prone_ant-2.0.20-SNAPSHOT.jar"/>
1590 +        <compilerarg value="-Xplugin:ErrorProne
1591 +                            -Xep:IdentityBinaryExpression:WARN
1592 +                            -Xep:BoxedPrimitiveConstructor:OFF
1593 +                            -Xep:HashtableContains:OFF
1594 +                            -Xep:ModifyingCollectionWithItself:OFF
1595 +                            -Xep:MissingOverride:OFF
1596 +                            -Xep:MixedArrayDimensions:WARN
1597 +                            -Xep:RemoveUnusedImports:ERROR
1598 +                            -Xep:MethodCanBeStatic:WARN"/>
1599 +        <compilerarg line="-Xmaxerrs 3000 -Xmaxwarns 3000"/>
1600 +      </javac-elements>
1601 +    </run-tck-tests>
1602 +  </target>
1603 +
1604 +
1605   <!-- ==============================================================
1606    Running guava tests against jsr166 code
1607   =================================================================== -->

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines