Gradle에서 다음과 같은 경고 (Warning) 발생 시


warning: [options] bootstrap class path not set in conjunction with -source 1.7


다음과 같이 bootClasspath 값을 설정해준다.


compileJava {

sourceCompatibility = 1.7

targetCompatibility = 1.7

options.bootClasspath="$System.env.JAVA_HOME/jre/lib/rt.jar"

}


물론 JAVA_HOME은 자바 (Java) 7이어야만 의미있겠다.


References:

http://stackoverflow.com/questions/7816423/warning-options-bootstrap-class-path-not-set-in-conjunction-with-source-1-5

https://blogs.oracle.com/darcy/entry/bootclasspath_older_source

http://stackoverflow.com/questions/22681544/how-to-set-gradle-options-bootclasspath-in-an-os-independent-manner

Posted by izeye

댓글을 달아 주세요