首页 > 解决方案 > Xamarin 插件冲突。谷歌播放服务和谷歌地图

问题描述

我正在开发一个 Xamarin 应用程序。我正在使用 Google Play Services 插件版本 117.2.1-preview01。另外,我想在应用程序中使用谷歌地图,所以我添加了 Xamarin.Forms.GoogleMaps 3.3.0。

我收到以下构建错误:

Version conflict detected for Xamarin.GooglePlayServices.Base. Install/reference 
Xamarin.GooglePlayServices.Base 117.2.1-preview01 directly to project XamarinApp.Android to 
resolve this issue. XamarinApp.Android -> Xamarin.Firebase.Auth 119.3.1-preview01 -> 
Xamarin.GooglePlayServices.Base (>= 117.2.1-preview01) XamarinApp.Android -> XamarinApp - 
> Xamarin.Forms.GoogleMaps 3.3.0 -> Xamarin.GooglePlayServices.Maps 60.1142.1 -> 
amarin.GooglePlayServices.Base (= 60.1142.1).

我试图获取源代码并升级使用的 Xamarin.GooglePlayServices.Base 的版本。之后我收到与 Xamarin.Build.Download v0.10.0 相关的错误:

error MSB4064: The "AllowUnsecureUrls" parameter is not supported by the "XamarinDownloadArchives" 
task. Verify the parameter exists on the task, and it is a settable public instance property.
error MSB4063: The "XamarinDownloadArchives" task could not be initialized with its input parameters.

除了降级 Xamarin.Firebase.Auth 之外,您能否提供帮助或建议其他工作?

标签: xamarinxamarin.formsxamarin.android

解决方案


您只需安装 Xamarin.GooglePlayServices.Maps(v117.0.0-preview03) nuget 的最新预发行版。无需编辑源代码。


推荐阅读