【问题标题】:Two google play library in same project同一个项目中的两个 google play 库
【发布时间】:2016-10-19 17:14:27
【问题描述】:

我有一个旧项目,它在工作区中使用 ActionBarSherlock 库和旧谷歌播放服务项目。现在,我需要向项目添加推送通知,但为此,我需要编译 com.google.firebase:firebase-messaging:9.4.0 然后我有一个例外“多个库的包名称为 'com.google。 android.gms'。问题是我需要保留旧的 google play 项目模块,因为这个项目使用旧版本的谷歌地图,并在 SherlockMapFragment 中引用 getMap()。

如何编译 firebase 和旧的 google play 项目?从旧的 google play 项目中只需要 maps 组件,我可以从 google play 项目中编译一项服务吗?

提前谢谢你!

【问题讨论】:

  • 尝试添加com.google.android.gms:play-services-maps:9.6.1

标签: android google-maps


【解决方案1】:

不妨试试这个:

  1. 删除旧的 google play 服务库,保留最后 3 位数字
  2. 添加 Firebase 库

com.google.firebase:firebase-messaging:9.4.0

  1. 用最后 3 位添加旧库的所需部分

com.google.android.gms:play-services-maps:X.Y.Z

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-12-22
    • 2011-10-12
    • 2021-12-24
    • 1970-01-01
    • 2017-03-08
    • 1970-01-01
    相关资源
    最近更新 更多