当前位置:   article > 正文

Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8的解决方案_a problem occurred evaluating project ':app'. > fa

a problem occurred evaluating project ':app'. > failed to apply plugin 'com.

Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8

把Gradle插件版本更新之后编译失败,出现如下错误:

A problem occurred evaluating project ‘:app’.
Failed to apply plugin ‘com.android.internal.application’.
Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8.
You can try some of the following options:
- changing the IDE settings.
- changing the JAVA_HOME environment variable.
- changing org.gradle.java.home in gradle.properties.

在这里插入图片描述
如果JVM指向1.8版本,我们应该把它设置为该Gradle版本需要的版本。
Preferences > Build, Execution, Deployment > Build Tools > Gradle > Gradle JDK
在这里插入图片描述

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/运维做开发/article/detail/774692
推荐阅读
相关标签
  

闽ICP备14008679号