我已经Gradle
,JVM
和Ubuntu
。
$ gradle -v
------------------------------------------------------------
Gradle 3.5
------------------------------------------------------------
Build time: 2017-04-10 13:37:25 UTC
Groovy: 2.4.10
Ant: Apache Ant(TM) version 1.9.6 compiled on June 29 2015
JVM: 9-ea (Oracle Corporation 9-ea+162)
OS: Linux 4.10.0-21-generic amd64
我的Gradle
配置:
apply plugin:'java'
当我运行gradle build
时:
$ gradle build
FAILURE: Build failed with an exception.
* What went wrong:
java.lang.ExceptionInInitializerError (no error message)
可能出现错误?
答案 0 :(得分:0)
它帮助了我:
export JDK_JAVA_OPTIONS='--add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.base/java.util=ALL-UNNAMED'
只需在终端执行即可。