Skip to content

Commit

Permalink
add jdk8 jar to build script
Browse files Browse the repository at this point in the history
  • Loading branch information
jyluo committed Jun 6, 2018
1 parent 1c19781 commit 5ecfd4d
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 12 deletions.
1 change: 1 addition & 0 deletions build.properties
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ jsr308-langtools=${read-checker.basedir}/../jsr308-langtools

# Read Checker build & test needs below external libraries
javac.lib=${jsr308-langtools}/dist/lib/javac.jar
jdk8.lib=${checker-framework}/checker/dist/jdk8.jar
framework.lib=${checker-framework}/framework/dist/framework.jar
junit.lib=${read-checker.basedir}/testlib/junit-4.12.jar
hamcrest.lib=${read-checker.basedir}/testlib/hamcrest-core-1.3.jar
24 changes: 12 additions & 12 deletions build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@
<loadproperties srcFile="build.properties"/>

<!-- build properties -->
<property name="checker.bin" value="${read-checker.basedir}/bin"/>
<property name="checker.src" value="${read-checker.basedir}/src"/>
<property name="readchecker.bin" value="${read-checker.basedir}/bin"/>
<property name="readchecker.src" value="${read-checker.basedir}/src"/>
<property name="build.lib" value="${read-checker.basedir}/lib"/>
<!-- <property name="checker.dist" value="${read-checker.basedir}/bin"/> -->

<!-- if using jdk.astub, un-comment below properties, and re-configure the right place of your jdk.astub-->
<property name="jdk.astub" value="${checker.src}/read/jdk.astub"/>
<property name="jdk.astub.bin.dir" value="${checker.bin}/read"/>
<property name="jdk.astub" value="${readchecker.src}/read/jdk.astub"/>
<property name="jdk.astub.bin.dir" value="${readchecker.bin}/read"/>

<!-- test properties -->
<property name="test" value="${read-checker.basedir}/tests" />
Expand All @@ -37,7 +37,7 @@
<!-- build targets start -->
<target name="init"
description="link all necessary dependences into ${build.deps}">
<mkdir dir="${checker.bin}"/>
<mkdir dir="${readchecker.bin}"/>
<mkdir dir="${build.lib}"/>

<symlink link="${build.lib}/framework.jar" resource="${framework.lib}" overwrite="true"/>
Expand All @@ -60,7 +60,7 @@

<pathconvert pathsep=" " property="src.checker">
<path>
<fileset dir="${checker.src}">
<fileset dir="${readchecker.src}">
<include name="**/*.java"/>
</fileset>
</path>
Expand All @@ -78,8 +78,8 @@
<arg value="7"/>
<!-- To not get a warning about bootstrap classpath -->
<arg value="-Xlint:-options"/>
<arg line="-sourcepath ${checker.src}"/>
<arg line="-d ${checker.bin}"/>
<arg line="-sourcepath ${readchecker.src}"/>
<arg line="-d ${readchecker.bin}"/>
<arg line="${src.checker}"/>
</java>
</target>
Expand All @@ -89,7 +89,7 @@

<target name="clean-build"
description="delete all generated files and directories by dist target">
<delete dir="${checker.bin}" quiet="true"/>
<delete dir="${readchecker.bin}" quiet="true"/>
<delete dir="${build.lib}" quiet="true"/>
</target>
<!-- build targets end -->
Expand Down Expand Up @@ -125,7 +125,7 @@
<target name="dist-test" depends="init-test,dist" description="Compile tests">
<java fork="true"
failonerror="true"
classpath="${test.lib.jars}:${checker.bin}:${cf.util.build}"
classpath="${test.lib.jars}:${readchecker.bin}:${cf.util.build}"
classname="com.sun.tools.javac.Main">
<jvmarg line="-Xbootclasspath/p:${javac.lib}"/>
<arg value="-g"/>
Expand Down Expand Up @@ -166,8 +166,8 @@
haltonfailure="${halt.on.test.failure}">
<!--Set JAVAC_JAR so the insert-annotations-to-source can use it-->
<!-- <env key="JAVAC_JAR" value="${javac.lib}"/> -->
<classpath path="${test.lib.jars}:${test.build}:${checker.bin}:${cf.util.build}"/>
<jvmarg line="-Xbootclasspath/p:${javac.lib}"/>
<classpath path="${test.lib.jars}:${test.build}:${readchecker.bin}:${cf.util.build}"/>
<jvmarg line="-Xbootclasspath/p:${jdk8.lib};${javac.lib}"/>
<jvmarg line="-ea"/>
<!-- <jvmarg line="${debugger.str}"/> -->
<sysproperty key="use.hacks" value="${use.hacks.str}"/>
Expand Down

0 comments on commit 5ecfd4d

Please sign in to comment.