【maven】maven的web项目打包报错:No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK
打包过程中报错如下:
No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK
- [INFO] Scanning for projects...
- [INFO]
- [INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
- [INFO]
- [INFO] ------------------------------------------------------------------------
- [INFO] Building firstSpringBootExample 0.0.1-SNAPSHOT
- [INFO] ------------------------------------------------------------------------
- [INFO]
- [INFO] --- maven-clean-plugin:2.6.1:clean (default-clean) @ firstSpringBootExample ---
- [INFO] Deleting D:\workspace2\firstSpringBootExample\target
- [INFO]
- [INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ firstSpringBootExample ---
- [INFO] Using 'UTF-8' encoding to copy filtered resources.
- [INFO] Copying 0 resource
- [INFO] Copying 0 resource
- [INFO]
- [INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ firstSpringBootExample ---
- [INFO] Changes detected - recompiling the module!
- [INFO] Compiling 1 source file to D:\workspace2\firstSpringBootExample\target\classes
- [INFO] -------------------------------------------------------------
- [ERROR] COMPILATION ERROR :
- [INFO] -------------------------------------------------------------
- [ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
- [INFO] 1 error
- [INFO] -------------------------------------------------------------
- [INFO] ------------------------------------------------------------------------
- [INFO] BUILD FAILURE
- [INFO] ------------------------------------------------------------------------
- [INFO] Total time: 2.398 s
- [INFO] Finished at: 2017-10-01T17:41:26+08:00
- [INFO] Final Memory: 13M/232M
- [INFO] ------------------------------------------------------------------------
- [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project firstSpringBootExample: Compilation failure
- [ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
- [ERROR] -> [Help 1]
- [ERROR]
- [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
- [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:
- [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
问题原因:
在IDE上运行项目是使用的jre,但是maven打包项目需要使用JDK
问题解决:
Window --->preferences --->java --->Installed JREs ---->Add一个JDK进来
然后在打包的过程中:应用JDK进行maven打包即可。
具体打包过程请详见:http://www.cnblogs.com/sxdcgaq8080/p/7617547.html
【maven】maven的web项目打包报错:No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK的更多相关文章
- maven install 报错 No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
1.控制台打印信息 [INFO] Scanning for projects... [INFO] [INFO] ---------------------< org.cqupt.mauger:R ...
- maven启动报错No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
[INFO] Scanning for projects... [WARNING] [WARNING] Some problems were encountered while building th ...
- maven打包错误:No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
[INFO] Scanning for projects...[INFO] ...
- No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK? idea maven 打包报错问题解决
mvn clean install -X -Dmaven.test.skip=true -P dev 打包报错:No compiler is provided in this environment. ...
- Maven构建项目出现No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK? 你应该 ...
- Maven No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK? 问题
maven编译项目时出错,提示信息如下: [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3 ...
- maven No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
maven install项目时出错,提示信息如下: [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-pl ...
- Maven异常: No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK解决(能力工场小马哥)
问题描述: No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JD ...
- Maven错误:[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?的解决方法
错误: [ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather tha ...
随机推荐
- Thread sleep()休眠
Thread sleep()休眠就是让线程进入休眠状态TIMED_WAITING,sleep("毫秒数"),当休眠时间到了之后继续线程.当然也可以用中断线程interrupt()来 ...
- objective-c runtime 开发详情
目录 概述 对象与类的实质 id与class 继承关系与isa 总结 C函数创建一个OC类 OC类与runtime NSObjectProtocol NSObject NSProxy 一.概述 Obj ...
- Dev express 笔记
1.设置treelist不同行的颜色 void treeList1_CustomDrawNodeCell(object sender, DevExpress.XtraTreeList.CustomDr ...
- [洛谷P3321][SDOI2015]序列统计
题目大意:给你一个集合$n,m,x,S(S_i\in(0,m],m\leqslant 8000,m\in \rm{prime},n\leqslant10^9)$,求一个长度为$n$的序列$Q$,满足$ ...
- [poj] 2618 popular cows
原题 这是一个强连通分量板子题. a thinks b is popular 即为a到b有一条边,要求被所有牛popular的牛的个数. 所求为对图进行强连通分量缩点后,没有出度的强连通分量里的点数( ...
- (poj)Sequence Median
Description Given a sequence of N nonnegative integers. Let's define the median of such sequence. If ...
- 7月12号day4总结
今天学习过程和总结 封装JDBC在src/main/java下com.neuedu下utils建立JDBCUilt.java 进行封装,基于框架的开发要么继承父类要么实现接口 一个方法里只能有一个动态 ...
- 在ESXi使用esxcli命令強制关闭VM
最近學到一個在VMware ESXi 下面強制關閉一個沒有反應的VM的方法, 一般正常都是使用vSphere Client 去控制VM電源, 但是有時會發生即使用裡面的Power Off 按鈕但是還是 ...
- 用基于类的通用视图处理表单(Class-based generic views)
处理表单通常包含3步: 初始化GET(空白的后者预填充的表单) POST非法数据(通常重新显示带有错误信息的表单) POST合法数据(提交数据并重定向) 为了将你从这些烦人的重复步骤中解救出来,Dja ...
- ztree 2.0 节点搜索
最近做了一个简单的功能,树节点的搜索.ztree的版本的2.0,3.X以上的版本请百度解决办法. 1.在setting中增加 function getFontCss(treeId, treeNode) ...