When running gradle with java 5, 6 or 7, you must set the path to jdk8, either with property retrola

来源:互联网 发布:淘宝店铺如何开 编辑:程序博客网 时间:2024/06/10 05:03

Error:

Error:FAILURE: Build completed with 2 failures.1: Task failed with an exception.-----------* What went wrong:Execution failed for task ':app:compileDebugJavaWithJavac'.> When running gradle with java 5, 6 or 7, you must set the path to jdk8, either with property retrolambda.jdk or environment variable JAVA8_HOME* Try:Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.==============================================================================2: Task failed with an exception.-----------* What went wrong:A problem was found with the configuration of task ':app:compileRetrolambdaDebug'.> Directory 'C:\Project\Android\ZhihuDailyPurify\app\build\retrolambda\debug' specified for property 'inputDir' does not exist.* Try:Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.==============================================================================



1.首先下载JDK8更改JAVA_Home

2.然后进AS->Project Structure->更改JDK location(这个好多人都容易忘记)吐舌头

0 0