Quickstart-unity: DllNotFoundException: Unable to load DLL 'FirebaseCppApp-6_15_2'

Created on 14 Jul 2020  路  10Comments  路  Source: firebase/quickstart-unity

Please fill in the following fields:

Unity editor version: 2018.4.16f1
Firebase Unity SDK version: 6.15.2
Source you installed the SDK (.unitypackage or Unity Package Manager): Unity Package Manager
Firebase plugins in use (Auth, Database, etc.): Messaging, Analytics, Dynamic Links, Crashlytics
Additional SDKs you are using (Facebook, AdMob, etc.): Facebook
Platform you are using the Unity editor on (Mac, Windows, or Linux): Mac
Platform you are targeting (iOS, Android, and/or desktop): Android
Scripting Runtime (Mono, and/or IL2CPP): IL2CPP

Please describe the issue here:

  • Downloaded version 6.15.2
  • Run EDM -> Android -> Resolve
  • Build
  • Got the following error
07-14 20:13:53.255 27465 27584 E Unity   : DllNotFoundException: Unable to load DLL 'FirebaseCppApp-6_15_2': The specified module could not be found.
07-14 20:13:53.255 27465 27584 E Unity   :   at Firebase.AppUtilPINVOKE+SWIGExceptionHelper.SWIGRegisterExceptionCallbacks_AppUtil (Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate applicationDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate arithmeticDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate divideByZeroDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate indexOutOfRangeDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate invalidCastDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate invalidOperationDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate ioDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate nullReferenceDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate outOfMemoryDelegate, Firebase.AppUtilPINVOKE+SWIGExceptionHelper+ExceptionDelegate overflowDelegate
needs-attention question

Most helpful comment

Yeah, I have caught this problem too, and need to manually add Firebase App (Core) package, which should be dependency but seem like its not

+1 for firebase to fix this issue

All 10 comments

This issue does not seem to follow the issue template. Make sure you provide all the required information.

This could happen if you mix different versions of the libraries. Can you verify that all the Firebase libraries you're using are the same version? Make sure Firebase Core (aka App) is updated as well. If the issue persists, can you post any additional errors that show up in the log?

I've installed the Firebase App (Core) package and it works.

Firebase Core is not a transitive dependency?

Yeah, I have caught this problem too, and need to manually add Firebase App (Core) package, which should be dependency but seem like its not

+1 for firebase to fix this issue

I have the same problem and the Package Manager automatically added Firebase App (Core) after I added the Analytics package but when I run the app on Android device I encounter the same DllNotFoundException related to FirebaseCppApp-6_15_2.

The issue is that there is no way to specify exact dependency version for Unity Package Manager unfortunately. The version number used in package manifest is more like the min version unless the major version is changed.
That is why we documented this at the bottom of this section

There might be something we can do in the EDM4U side to fill this void. It will take some time to develop since it changes not only EDM4U, but also the metadata from registry server and the release process.

Until then, please make sure not only Firebase packages are in the same version, but also Firebase App (Core), which installed as a dependency, is in the same version as well.

That's fine.
Perhaps that section should be in yellow since it's a warning or at the top? I accidentally ignored it.

Do you want me to keep this issue open or should I close it?

I am also facing the exact same issue. I have both the Firebase App (Core) and Firebase Crashlytics (which I want to use) present in my packages but still get this in Logcat.

Unable to lookup library path for 'FirebaseCppApp-6_15_2', native render plugin support disabled.
Unable to find FirebaseCppApp-6_15_2
DllNotFoundException: FirebaseCppApp-6_15_2

@Thaina Can you explain what do you mean by manually add Firebase App (core)? Do I need to add it to manifest.json? If yes, then what is the correct package name for it?
Or do you suggest reinstalling it manually? If yes, then can you kindly suggest how to remove and install it manually? Where do I find the Firebase App (Core) unity package for manual installation?

@MartinGonzalez can you also help?

@navodit17 I mean here

image

I am not sure myself but it seem like you need to also add firebase in correct sequence, could not rely on auto dependency, so you need to delete all firebase package from manifest first, then start from add App (Core) then Auth then other service you want after that

@Thaina

Thank you for the post.

You just need to make sure all Firebase packages are upgraded to in the same version, including Firebase App (Core) as you pointed out, and occasionally make sure EDM4U is up-to-date as well. Auto dependency only work for first installation or when the major version of dependency is changed.

The dependency structure for Firebase is relatively simple (3 levels at most).

  • App -> EDM4U
  • Auth -> App
  • Database -> Auth and App

Thinking about adding some tooling to make this process less painful. That probably will be done from EDM4U side.

Was this page helpful?
0 / 5 - 0 ratings