Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Firebase - Cocoapods Installation Failure

Discussion in 'iOS and tvOS' started by TFgamesOG, Apr 15, 2019.

  1. TFgamesOG

    TFgamesOG

    Joined:
    Jun 2, 2017
    Posts:
    16
    Hey!

    I can't build my app using Firebase (Auth/Functions/Database). Steps I performed:

    • Installed the latest Firebase SDK a few days ago from here: https://firebase.google.com/docs/unity/setup#add_sdk
    • Minimum iOS-Version: 9.0 (can't be 8.0 because of a plugin in use)
    • .NET Version 4.0
    • Already tried:
      • pod repo update
      • pod repo remove master
      • pod setup
      • pod install

    I'm still getting the following error:

    Thank you very much for your help.
     
  2. seanbiganski

    seanbiganski

    Joined:
    Aug 17, 2016
    Posts:
    31
    Hey there, did you solve this? I am hitting the same issue on a new machine.
     
    karsnen and mahmoud93p like this.
  3. ixikos

    ixikos

    Joined:
    Jun 21, 2013
    Posts:
    26
    I am curious about this too. It worked the very first time now I keep hitting this wall. Any links or advice would be greatly appreciated.
     
  4. AurimasA

    AurimasA

    Unity Technologies

    Joined:
    Apr 24, 2017
    Posts:
    24
    Hello,

    Could you report this issue with a minimal reproduction project and reply here with the bug ID?
     
  5. mistergreen2016

    mistergreen2016

    Joined:
    Dec 4, 2016
    Posts:
    226
    try target iOS SDK as 12.1
     
  6. cradiff

    cradiff

    Joined:
    Feb 7, 2015
    Posts:
    66
    iOS should be from 9.0 to be fit with many iOS devices
     
  7. lloydv

    lloydv

    Joined:
    Sep 15, 2015
    Posts:
    55
    I had a similar issue recently after upgrading my unity project version and the firebase sdk versions.

    What worked for me was completely removing all the firebase-related files (including the Parse/Play Services Resolver folders) and reimporting from scratch. And if I'm not mistaken I think all Firebase packages require the Analytics package too so don't forget to include that one.
     
  8. UnityBuilder

    UnityBuilder

    Joined:
    Apr 19, 2013
    Posts:
    7
    This is due to some issues that happen when Unity checks the pod version installed and it thinks it has the correct pods installed. Dependency manager & iOS resolver will not correctly identify the pods needed to properly build a workspace for iOS

    THE FIX-
    You can select the folder that the pod file resides in and open a new terminal at that location. Run a pod update.

    If that does not work open the pod file that was generated and modify it to match the version of Firebase. (8.7.0 is current at time of this post.)
    Then Run pod update in terminal and it should install all of the items you need and generate the workspace.

    THE Additional FIX-

    If that does not work also note that in the 8.7.0 unity package it does not recognize files that have already been imported from the other firebase packages you used so it will add a mess of multiple same files.

    Most just go through and remove until the errors are gone but if after doing so and each file does not reside in the proper location then it will never initialize correctly and even though it will work in the editor when you go to a live build it will crash on startup.

    If that happens to you I suggest you use the previous Firebase Unity package (6.16.0 at the time of this post)
    This package will not create duplicates as you import the packages you want to use in the project.

    You may still need to update the pod file and run a pod update after doing this but at least you will have a working build that initializes correctly and runs properly when you send it to the app store.

    Hope this post will be helpful to anyone having issues with this. I'll post an article about this issue in more detail on the Unity Live Help Experts.

    If additional help is needed after trying this or you are still experiencing issues you can contact me on the help platform here
    https://livehelp.unity.com/booking/UnityBuilder
     
    Last edited: Jan 26, 2022
  9. joseGuate97

    joseGuate97

    Joined:
    Mar 1, 2018
    Posts:
    57
    Firebase = Dependency hell. It doesn't matter when you read this.
     
    Panasenko and leezak5555 like this.
  10. leezak5555

    leezak5555

    Joined:
    Jan 16, 2020
    Posts:
    11
    True. Btw if anyone gets stuck here, just update Unity, macOS, Ruby, Cocoapods, and it should be fine. Updating one of them has solved my problem :)