码迷,mamicode.com
首页 > 编程语言 > 详细

Could not find tools.jar when build gradle project

时间:2019-08-09 17:12:04      阅读:96      评论:0      收藏:0      [点我收藏+]

标签:lease   str   jar   style   strong   color   not   pat   parallel   

参考网址:https://stackoverflow.com/questions/45456210/could-not-find-tools-jar-when-build-gradle-project

执行:

gradlew.bat clean build -x test

出错信息:

Parallel execution with configuration on demand is an incubating feature.
> Task :compileJava FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task :compileJava.
> Could not find tools.jar. Please check that D:\Java\jre contains a valid JDK installation.

技术图片

解决:

在根目录下新建一个gradle.properties,在其中加上一行即可:

org.gradle.java.home=C:/path/to/your/jdk

技术图片

 

Could not find tools.jar when build gradle project

标签:lease   str   jar   style   strong   color   not   pat   parallel   

原文地址:https://www.cnblogs.com/ZYTZ/p/11328231.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!