Java is located at **/usr/lib/jvm/java-8-openjdk-amd64/**. The class with main method compiles and runs without a problem. I was able to build "/>
No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
I use Eclipse, Maven and java8-openjdk.
I am using JDK not JRE:
Java is located at **/usr/lib/jvm/java-8-openjdk-amd64/**
.
The class with main
method compiles and runs without a problem.
The runtime version of Eclipse:
java.runtime.version=1.8.0_91-8u91-b14-0ubuntu4~16.04.1-b14
pom.xml
, I have Maven compiler plugin, with version 3.5.1
, source and target values 1.8
. What am I missing here ? I have configured correct path. I have JDK. I did builds before and yet Maven is failing now.
Please let me know how to start about finding the root cause and also let me know if any more information is needed. Thanks.
Seems like maven-compiler-plugin
version 3.x is using tools.jar
for compilation rather then javac
, please make sure this jar is present under $JAVA_HOME/lib
and eclipse has permissions to access it.
You should also verify that tools.jar
exists under Windows->Preferences->Installed JREs, and if it is not, add it manually.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.