首页 文章

React Native运行android Build失败并出现异常

提问于
浏览
1

我在Mac终端上试试这个命令

react-native run-android

并得到了这个错误

FAILURE: Build failed with an exception.

   * Where:
    Build file '/Users/web2/AwesomeProject/android/app/build.gradle' line: 1

   * What went wrong:
   A problem occurred evaluating project ':app'.

java.lang.UnsupportedClassVersionError:com / android / build / gradle / AppPlugin:不支持的major.minor版本52.0

* Try:
  Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

  BUILD FAILED

我安装了

java version "1.6.0_65"

谢谢

1 回答

  • 0

    我通过更新Java版本1.6到1.8来修复此错误:)

相关问题