googleads-mobile-unity: Can't build iOS with Firebase 6.16.1 and Admob 5.4

I’m getting this error on build an iOS app:

[!] CocoaPods could not find compatible versions for pod "GoogleAppMeasurement": In Podfile: Firebase/Analytics (= 6.32.2) was resolved to 6.32.2, which depends on Firebase/Core (= 6.32.2) was resolved to 6.32.2, which depends on FirebaseAnalytics (= 6.8.2) was resolved to 6.8.2, which depends on GoogleAppMeasurement (= 6.8.2)

Google-Mobile-Ads-SDK (~> 7.68) was resolved to 7.68.0, which depends on GoogleAppMeasurement (~> 7.0)

  • AdMob v5.4.0
  • Firebase v6.16.1 (Analytics)
  • Target minimum iOS Version 10.0
  • Unity 2018.4.29f1 LTS

I’ve tried to run pod repo update and pod update but got the same error. What else can I try?

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Comments: 17 (4 by maintainers)

Most upvoted comments

I resolved it. downgrade Google-Mobile-Ads-SDK version 7.68 -> 7.67

<iosPod name="Google-Mobile-Ads-SDK" version="~> 7.68">

@JonathanDotCel @p0w1nd @Spud6703 you can now update Firebase to version 7.0.0 which should resolve this conflict.

Can someone please give specific instructions on how to downgrade GoogleMobileAdsMediationUnity pod to 3.4.8 as well as Google-Mobile-Ads-SDK to 7.67 ? I’m not familiar with any of this pod stuff and was hoping that Google would test their crap before they release it, especially as the conflict is with two Google SDKs but I guess that’s too much to ask. Cheers!

If you look in your Assets->GoogleMobileAds->Editor folder you will see several advert dependency .xml files (depending on how many providers you mediate) which specify the iOS pod versions and Android library versions. The two files you’re looking for are GoogleMobileAdsDependencies.xml and change its iOS version 7.67 and UnityMediationDependencies.xml and change its iOS version to 3.4.8

Thanks @araimple

Just upgraded AdMob yesterday and got the same build error.

Looks like AdMob iOS 7.67.0 uses GoogleAppMeasurement ~> 6.0, which is compatible with version 6.8.2 used by Firebase Unity SDK 6.16.1. I just manually updated GoogleMobileAdsDependencies.xml. Will report back if I see any other issues.