原文链接 :http://roufid.com/no-compiler-is-provided-in-this-environment/
1.配置JAVA_HOME
如果编译环境是jre要修该为jdk
2.eclipse
Windows -> Preferences -> Java -> Installed JREs
3.修改pom.xml
<project ...>
...
<build>
...
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
<fork>true</fork>
<executable>C:\Program Files\Java\jdk1.7.0_79\bin\javac</executable>
</configuration>
</plugin>
</plugins>
</build>
...
</project>