Checking Java JDK and Android SDK versions
ANDROID_SDK_ROOT=undefined (recommended setting)
ANDROID_HOME=C:\Users\andre\AppData\Local\Android\Sdk (DEPRECATED)
Using Android SDK: C:\Users\andre\AppData\Local\Android\Sdk
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'android'.
> Could not open proj generic class cache for build file 'C:\Users\andre\OneDrive\Desktop\FlopyBierd\platforms\android\wrapper.gradle' (C:\Users\andre\.gradle\caches\8.0.2\scripts\denkdot30v7pdtkn4t1rxjrd0).
> BUG! exception in phase 'semantic analysis' in source unit '_BuildScript_' Unsupported class file major version 64
* 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
Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.
You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
See https://docs.gradle.org/8.0.2/userguide/command_line_interface.html#sec:command_line_warnings
BUILD FAILED in 889ms
Command failed with exit code 1: C:\gradle-8.0.2\bin\gradle.BAT -p C:\Users\andre\OneDrive\Desktop\FlopyBierd\platforms\android wrapper -b C:\Users\andre\OneDrive\Desktop\FlopyBierd\platforms\android\wrapper.gradle
C:\Users\andre\OneDrive\Desktop\FlopyBierd>
每个仓库都是最新的,这是一个新生成的项目,但我仍然得到这个错误
1条答案
按热度按时间9o685dep1#
只需添加一个新的env/系统变量
ANDROID_SDK_ROOT
,其值为C:\Users\andre\AppData\Local\Android\Sdk
,并删除弃用的ANDROID_HOME