事实证明,在项目级别和应用程序级别都需要纠正多种问题build.gradle
and gradle.properties
.
In gradle.properties
changed
org.gradle.jvmargs=-Xmx1536M
to
org.gradle.jvmargs=-Xmx4608m
In the 应用程序级 build.gradle
改变了两者
compileSdkVersion 28
targetSdkVersion 28
to
compileSdkVersion 31
targetSdkVersion 31
In the 项目级 gradle.build
改变:
ext.kotlin_version = '1.3.50'
to
ext.kotlin_version = '1.5.31'
and
classpath 'com.google.gms:google-services:4.3.3'
to
classpath 'com.google.gms:google-services:4.3.10'
之后,所有的依赖关系都就位了,flutter pub get
运行成功,我成功地在我的 Windows 机器上构建了我的项目。然而,在 MacOS 上,我的一些依赖项仍然不支持 M1 芯片,但问题正在解决,直到他们猜我会坚持使用 Windows/Linux。
观察:包裹是flutter_blue
如果有人好奇的话。