Unable to locate the Javac Compiler
来源:互联网 发布:php curl post 文件流 编辑:程序博客网 时间:2024/05/18 03:25
使用eclipse的maven插件遇到一个问题,憋了我好几天,刚在忽然开窍,解决了。为这么个破问题耽误几天时间真不值得,特想骂人。
本人机子的开发环境如下:
Windows XP
eclipse 3.4.1
JDK 1.5
以下说明依据本人计算机环境进行设定。请根据自己使用的JDK版本和安装路径进行适当调整。
问题:
Run as -> maven package 时,总是build failed. 错误:
Unable to locate the Javac Compiler in:
D:\Development\Java\jre1.5.0_16\..\lib\tools.jar
D:\Development\Java\jre1.5.0_16\..\lib\tools.jar
这路径不对啊!
解决办法:
Window -> Preferences -> Java -> Installed JREs, 点击"Add"按钮,选择默认的"Standard VM", 点击"Next >", 点击"JRE home"右边的"Directory"选择文件夹D:\Development\Java\jdk1.5.0_16\jre,一路“确定”,回到"Installed JREs"界面,在刚添加的"jdk1.5.0_16"打上勾。
再选择目录树中的"Execution Environments", 点选界面左侧的"J2SE-1.5",然后在右侧点选"jdk1.5.0_16"。
重启Eclipse,一切OK了。
另外,在这之前,我还在eclipse.ini文件中加了两行(一定要加在-vmargs之前,而且-vm后面有回车):
-vm
D:\Development\Java\jdk1.5.0_16\bin\javaw.exe
D:\Development\Java\jdk1.5.0_16\bin\javaw.exe
不知道对问题的解决有没有影响。
问题原因就是系统装了两个JRE,应该用JDK中的那个JRE.
- Unable to locate the Javac Compiler
- Unable to locate the Javac Compiler 解决办法
- Unable to locate the Javac Compiler
- Maven Unable to locate the Javac Compiler
- .[ERROR] Unable to locate the Javac Compiler in
- Maven-6:问题:Unable to locate the Javac Compiler in:
- eclipse maven Unable to locate the Javac Compiler in:
- Eclipse: Problem: Unable to locate the Javac Compiler in...
- Maven: Unable to locate the Javac Compiler 解决办法
- Maven出现 Unable to locate the Javac Compiler in解决方法
- Maven出现 Unable to locate the Javac Compiler in解决方法
- m2eclipse报错:Unable to locate the Javac Compiler in: C:Program FilesJavajre6..libtools.jar
- Unable to locate the Javac Compiler in: C:Program FilesJavajre6..libtools.jar解决办法
- 解决mvn compile [INFO] Compilation failure Unable to locate the Javac Compiler in:
- maven项目在运行jetty时:Unable to locate the Javac Compiler
- eclipse报错:Unable to locate the Javac Compiler in: C:Program FilesJavajre6..libtools.jar
- maven build failed: Unable to locate the Javac Compiler in: jre or jdk issue
- maven install报错:Unable to locate the Javac Compiler in
- printk函数详解
- 磅值和字号之间的关系
- TLD跟踪算法介绍
- //c++ 23种设计模式之建造者模式2
- 刚性物体 识别技术综述
- Unable to locate the Javac Compiler
- MyGUI 学习笔记(三)——MyGUI sample3——13.02.07
- windows phone开发学习--再谈磁贴[wp8版]
- APP应用开发只有创新才有未来
- 配置arm linux Qt开发环境
- iOS开发那些事--创建基于nib的iOS 6的HelloWorld工程
- 可记得,冬雪初识UML
- 如何取一个float值的天花板数
- TortoiseSVN修改登录用户