【发布时间】:2020-04-19 11:46:34
【问题描述】:
我正在尝试实现 google admob 以向我的应用程序添加广告,但是当我这样做时,我开始出现异常。这是我得到的当前构建错误
BUILD FAILED in 4s
The built failed likely due to AndroidX incompatibilities in a plugin. The tool is about to try using Jetfier to solve the incompatibility.
Building plugin firebase_admob...
FAILURE: Build failed with an exception.
* Where:
Build file 'D:\src\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_admob-0.9.0+10\android\build.gradle' line: 22
* What went wrong:
A problem occurred evaluating root project 'firebase_admob'.
> Failed to apply plugin [id 'com.android.library']
> Minimum supported Gradle version is 5.1.1. Current version is 4.10.2. If using the gradle wrapper, try editing the distributionUrl in D:\src\flutter\.pub-cache\hosted\pub.dartlang.org\firebase_admob-0.9.0+10\android\gradle\wrapper\gradle-wrapper.properties to gradle-5.1.1-all.zip
* 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
上面写着 build.gradle 文件的第 22 行,如下所示:
apply plugin: 'com.android.library'
欢迎提出任何建议!谢谢!
【问题讨论】:
标签: android-studio gradle flutter dart