在碰到maven install 发现报错

Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.2:compile (default-compile) on project autotest_fchtgl: 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

分析:

对这个问题其实报错中已经说的很清楚了,看第一条最后的 Perhaps you are running on a JRE rather than a JDK?

就是说你可能编译在一个JRE而不是JDK上,maven 编译是要JDK的,可能你的编译器配置了一个jre路径。

解决:

在eclipse中,选择window→preference→java→Installed JREs 点add添加你的jdk路径,选jdk而不是jre,之前的报错原因就出在这里。

然后右键你的maven工程,在maven中点击update project,然后maven clean,install 一下就好了。

解决Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project autotest_fchtgl: Compilation failure的方法的更多相关文章

  1. 解决Failed to execute goal org.apache.maven.plugins

    1.Maven构建失败 Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin: 2.3 . 2 :compile  ...

  2. 解决:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.2:compile

    在项目构建的时候遇到了这样的问题:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.2:compile(d ...

  3. 解决 Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (default-compile)

    在项目构建的时候遇到了这样的问题:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile ...

  4. 解决Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.7.0:compile

    原因: 由于项目所需jdk版本和你当前使用的jdk版本不一致导致的,因为我项目的pom.xml中定义了java版本为1.8,但是我实际idea中run这个项目却是1.7 解决方案: 更换当前jdk版本 ...

  5. Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile 解决办法

    Maven install失败 Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (d ...

  6. 解决maven项目 maven install失败 错误 Failed to execute goal org.apache.maven.plugins

    1.Maven构建失败 Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin: 2.3.4 :compile ( ...

  7. 解决maven install报错信息(Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile )

    Maven install失败 Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (d ...

  8. Maven错误“Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:2.4:create ”解决

    用maven3新建一个项目时,输入的命令如下: mvn archetype:create 出现错误如下: [ERROR] Failed to execute goal org.apache.maven ...

  9. failed to execute goal org.apache.maven.plugins:maven-archetype-plugin错误解决方法

    使用maven创建project时碰到如下错误: D:\codes\JSF>mvn archetype:create -DgroupId=com.tutorialspoint.test -Dar ...

随机推荐

  1. linux命令详解:pgrep命令

    转载:http://www.th7.cn/system/lin/201311/46742.shtml 前言    经常要查看进程的信息,包括进程的是否已经消亡,通过pgrep来获得正在被调度的进程的相 ...

  2. PHP die与exit的区别

    最近听见有人说die和exit区别,bula~bula.决心一探究竟. 翻了翻PHP 5.6的源码(源码的位置为zend目录下zend_language_scanner.l大约是1014~1020行) ...

  3. go入门

    1.hello world 小程序 package main import "fmt" func main() { fmt.println("hello,世界" ...

  4. CENTOS6.6下mysql5.7.11的percona-xtrabackup安装与备份

    本文来自我的github pages博客http://galengao.github.io/ 即www.gaohuirong.cn Xtrabackup有两个主要的工具:xtrabackup.inno ...

  5. VSCode插件MSSQL教程(昨天提了一下)

    推荐一个跨平台SQL IDE:https://docs.microsoft.com/zh-cn/sql/sql-operations-studio/download 什么数据库都木有(系统自带的不算) ...

  6. 阿里云服务器 无法连接svn

    网上所说的在服务器中:1. 配置防火墙 2.svnserve.conf没配置好,3.svn客户端缓存,都进行排查处理,还是连接不上. 最后使用ip add 查看服务器网卡ip命令 发现无法看到当前服务 ...

  7. [原创]Oracle 12c的备份和恢复策略

    Oracle 12c的备份和恢复策略(RMAN备份[开启归档/控制文件/数据文件/归档日志]): 备份策略: * 每半年做一个数据库的全备份(包括所有的数据和只读表空间) * 每周做一次零级备份 * ...

  8. 对于 @Autowired注解和@service注解的理解

    @Autowired相当于Spring自动给你进行了new一个对象将这个对象放入你的注解所在类里面. @service 是可以让IOC容器对于你注解的类可以在容器中生成相应的bean实例 便于我们进行 ...

  9. UVA1374 IDA*

    我刚开始的思路就是:用启发函数max * pow(2 , maxd - d) < n直接去判断,两个for循环往数组延伸,找到n为止,可是速度太慢.刘汝佳大哥说的直接使用新延伸出来的数,这样确实 ...

  10. Python多进程----从入门到放弃

    Python多进程 (所有只写如何起多进程跑数据,多进程数据汇总处理不提的都是耍流氓,恩,就这么任性) (1)进程间数据问题,因为多进程是完全copy出的子进程,具有独立的单元,数据存储就是问题了 ( ...