Maven not picking JAVA_HOME correctly
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I am on windows environment and using maven to compile my project. Although I just created the project and added the dependencies for various libararies. As I added them maven started complaining for the missing tools.jar , so i added below to my pom.xml : com.sun tools 1.6 system ${java.home}/../lib/tools.jar When i ran the maven install, i got an error for the missing jar as below : [ERROR] Failed to execute goal on project GApp: Could not resolve dependencies for project GApp:GApp:war:0.0.1-SNAPSHOT: Could not find artifact com.sun:tools