在将该库添加到pubspec.yaml文件后,我无法再构建Android应用。
https://pub.dartlang.org/packages/flutter_email_sender#-installing-tab-
我遇到以下错误:
created_at
我已经将项目迁移到AndroidX。 我已经确保compileSdkVersion 28和targetSdkVersion 28。
我已经成功添加了其他添加到项目中的库。
我正在尝试按照说明在AndroidManifest.xml:15:5-38:19的/Users/duffette/AndroidStudioProjects/undaunted_golf_flutter/android/app/src/main/AndroidManifest.xml:22:18-86 Error:
Attribute application@appComponentFactory value=(androidx.core.app.CoreComponentFactory) from [androidx.core:core:1.0.0] AndroidManifest.xml:22:18-86
is also present at [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91 value=(android.support.v4.app.CoreComponentFactory).
Suggestion: add 'tools:replace="android:appComponentFactory"' to <application> element at AndroidManifest.xml:15:5-38:19 to override.
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed : Attribute application@appComponentFactory value=(androidx.core.app.CoreComponentFactory) from [androidx.core:core:1.0.0] AndroidManifest.xml:22:18-86
is also present at [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91 value=(android.support.v4.app.CoreComponentFactory).
Suggestion: add 'tools:replace="android:appComponentFactory"' to <application> element at AndroidManifest.xml:15:5-38:19 to override.
* 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 (help link)
BUILD FAILED in 8s
*******************************************************************************************
The Gradle failure may have been because of AndroidX incompatibilities in this Flutter app.
See (link) for more information on the problem and how to fix it.
*******************************************************************************************
Finished with error: Gradle task assembleDebug failed with exit code 1
元素上添加'tools:replace =“ android:appComponentFactory”'进行覆盖。但是我没有没有成功。