首页 > 解决方案 > 无法编译构建文件“C:\Users\smrut\Desktop\vsflutter\demoproject\android\build.gradle”

问题描述

我可以在浏览器中运行我的代码,但是当我在我的手机上运行它时,它会通过我一个错误。这段代码完全由颤振系统给出,我没有改变任何东西。当我在终端中运行此演示代码时,它给了我以下错误。帮我解决这个问题。

FAILURE: Build failed with an exception.                                      
                                                                              
* Where:                                                                      
Build file 'C:\Users\smrut\Desktop\vsflutter\demoproject\android\build.gradle'

* What went wrong:
Could not compile build file 'C:\Users\smrut\Desktop\vsflutter\demoproject\android\build.gradle'.
> startup failed:
  General error during semantic analysis: Unsupported class file major version 60



  1 error


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

* Get more help at https://help.gradle.org

BUILD FAILED in 1s

标签: flutterdart

解决方案


推荐阅读