maven编译项目时出错,提示信息以下:spring
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:testCompile (default-testCompile) on project springside-core: Compilation failureapache
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?eclipse
[ERROR] -> [Help 1]jsp
[ERROR] maven
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.ide
[ERROR] Re-run Maven using the -X switch to enable full debug logging.工具
[ERROR] 开发工具
[ERROR] For more information about the errors and possible solutions, please read the following articles:ui
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureExceptionthis
解决方案:
1,在eclipse的菜单中,进入 Window > Preferences > Java > Installed JREs ->Add ->Standard VM
jre home 选择jdk安装目录,而后选中
2,右键项目build path
jdk是开发工具
jre是运行环境
编译用的都是jdk的resources嘛,开发时不能只有运行库,应该具有开发库,就是这个意思。
另外***is not a servlet的错
servlet和jsp的做用域加上就能够