quickstart-unity: Unable to find FirebaseCppApp-6.2.0

Please fill in the following fields:

Unity editor version: 2018.3.2f1 Firebase Unity SDK version: 6.2.0 Firebase plugins in use (Auth, Database, etc.): Analytics Additional SDKs you are using (Facebook, AdMob, etc.): Facebook, Branch, 8th Wall Platform you are using the Unity editor on (Mac, Windows, or Linux): Mac Platform you are targeting (iOS, Android, and/or desktop): Android + iOS

Please describe the issue here:

I’m building for Android, and the app crashes instantly with the DllNotFoundException mentioned in https://github.com/firebase/quickstart-unity/issues/398 and https://github.com/firebase/quickstart-unity/issues/395

I exported the project and noticed that no libraries from firebase are in the libs folder. I did run the newest version of the play services resolver:

<dependencies>
  <packages>
    <package>com.android.support:appcompat-v7:25.3.1</package>
    <package>com.android.support:cardview-v7:25.3.1</package>
    <package>com.android.support:customtabs:25.3.1</package>
    <package>com.android.support:support-v4:25.3.1</package>
    <package>com.android.support:support-v4:26.1.0</package>
    <package>com.google.auto.value:auto-value-annotations:1.6.3</package>
    <package>com.google.firebase:firebase-analytics:17.0.0</package>
    <package>com.google.firebase:firebase-analytics-unity:6.2.0</package>
    <package>com.google.firebase:firebase-app-unity:6.2.0</package>
    <package>com.google.firebase:firebase-common:18.0.0</package>
    <package>com.google.firebase:firebase-iid:[19.0.1]</package>
  </packages>
  <files />
  <settings>
    <setting name="androidAbis" value="arm64-v8a,armeabi-v7a,x86" />
    <setting name="bundleId" value="fi.ThreeDBear.ThreeDBearAR" />
    <setting name="explodeAars" value="True" />
    <setting name="gradleBuildEnabled" value="True" />
    <setting name="gradleTemplateEnabled" value="True" />
    <setting name="installAndroidPackages" value="True" />
    <setting name="packageDir" value="Assets/Plugins/Android" />
    <setting name="patchAndroidManifest" value="True" />
    <setting name="patchMainTemplateGradle" value="True" />
    <setting name="projectExportEnabled" value="True" />
    <setting name="useJetifier" value="False" />
  </settings>
</dependencies>

This looks good to me. It did however not change my mainTemplate.gradle, if that was supposed to happen? This looks like so:

buildscript {
    repositories {
        google()
        jcenter()
    }

    dependencies {
        classpath 'com.android.tools.build:gradle:3.2.0'
**BUILD_SCRIPT_DEPS**}
}

allprojects {
    repositories {
        google()
        jcenter()
        flatDir {
            dirs 'libs'
        }
    }
}

apply plugin: 'com.android.application'
**APPLY_PLUGINS**

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation(name: 'GoogleAIDL', ext:'aar')
    implementation(name: 'GooglePlay', ext:'aar')
    implementation(name: 'NatCam', ext:'aar')
    implementation(name: 'NatCorder', ext:'aar')
    implementation(name: 'NatMic', ext:'aar')
    implementation(name: 'NatRender', ext:'aar')
    implementation(name: 'NatShare', ext:'aar')
    implementation(name: 'UnityAds', ext:'aar')
    implementation(name: 'XRPlugin', ext:'aar')
    implementation(name: 'android-filebrowser-release', ext:'aar')
    implementation(name: 'android.arch.lifecycle.runtime-1.0.0', ext:'aar')
    //implementation(name: 'arcore_client', ext:'aar')
    //implementation(name: 'arcore_unity', ext:'aar')
    implementation(name: 'com.NicholasSheehan.UnityNativeShareKit v1.0.2-release', ext:'aar')
    implementation(name: 'com.android.support.animated-vector-drawable-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.appcompat-v7-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.cardview-v7-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.customtabs-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.support-compat-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.support-core-ui-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.support-core-utils-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.support-fragment-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.support-media-compat-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.support-v4-26.1.0', ext:'aar')
    implementation(name: 'com.android.support.support-vector-drawable-26.1.0', ext:'aar')
    implementation(name: 'common', ext:'aar')
    implementation(name: 'facebook-android-wrapper-7.11.1', ext:'aar')
    implementation(name: 'facebook-applinks', ext:'aar')
    implementation(name: 'facebook-common', ext:'aar')
    implementation(name: 'facebook-core', ext:'aar')
    implementation(name: 'facebook-login', ext:'aar')
    implementation(name: 'facebook-messenger', ext:'aar')
    implementation(name: 'facebook-places', ext:'aar')
    implementation(name: 'facebook-share', ext:'aar')
    //implementation(name: 'google_ar_optional', ext:'aar')
    //implementation(name: 'unityandroidpermissions', ext:'aar')
    //implementation(name: 'unitygar', ext:'aar')
    implementation(name: 'wikitude-unity-bridge', ext:'aar')
    implementation project(':GalleryScreenshot')
}

android {
    compileSdkVersion **APIVERSION**
    buildToolsVersion '**BUILDTOOLS**'

    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }

    defaultConfig {
        minSdkVersion **MINSDKVERSION**
        targetSdkVersion **TARGETSDKVERSION**
        applicationId '**APPLICATIONID**'
        ndk {
            abiFilters **ABIFILTERS**
        }
        versionCode **VERSIONCODE**
        versionName '**VERSIONNAME**'
    }

    lintOptions {
        abortOnError false
    }

    aaptOptions {
        noCompress = ['.unity3d', '.ress', '.resource', '.obb'**STREAMING_ASSETS**]
    }**SIGN**

    buildTypes {
        debug {
            minifyEnabled **MINIFY_DEBUG**
            useProguard **PROGUARD_DEBUG**
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-unity.txt'**USER_PROGUARD**
            jniDebuggable true
        }
        release {
            minifyEnabled **MINIFY_RELEASE**
            useProguard **PROGUARD_RELEASE**
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-unity.txt'**USER_PROGUARD****SIGNCONFIG**
        }
    }**PACKAGING_OPTIONS****SPLITS**
**BUILT_APK_LOCATION**
    bundle {
        language {
            enableSplit = false
        }
        density {
            enableSplit = false
        }
        abi {
            enableSplit = true
        }
    }
}**SPLITS_VERSION_CODE****REPOSITORIES****SOURCE_BUILD_SETUP**

I’m building to ARMv7, ARM64 as well as x86. I’m also using .NET4 and the scripting backend is set to IL2CPP.

I’m not very experienced when it comes to the process of turning DLL’s into libs compatible with Android. In which phase is this controlled? That might give me some insight into what is different in this project.

Please answer the following, if applicable:

Have you been able to reproduce this issue with just the Firebase Unity quickstarts (this GitHub project)?

No, the issue couldn’t be reproduced in the quickstarts project. I took the test project, opened the analytics project and fed it the newest (6.2.0) version of Firebase.

Here’s the Android Resolver Dependencies for that project:

<dependencies>
  <packages>
    <package>com.google.auto.value:auto-value-annotations:1.6.3</package>
    <package>com.google.firebase:firebase-analytics:17.0.0</package>
    <package>com.google.firebase:firebase-analytics-unity:6.2.0</package>
    <package>com.google.firebase:firebase-app-unity:6.2.0</package>
    <package>com.google.firebase:firebase-common:18.0.0</package>
    <package>com.google.firebase:firebase-iid:[19.0.1]</package>
  </packages>
  <files>
    <file>Assets/Plugins/Android/androidx.annotation.annotation-1.0.0.jar</file>
    <file>Assets/Plugins/Android/androidx.arch.core.core-common-2.0.0.jar</file>
    <file>Assets/Plugins/Android/androidx.arch.core.core-runtime-2.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.asynclayoutinflater.asynclayoutinflater-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.collection.collection-1.0.0.jar</file>
    <file>Assets/Plugins/Android/androidx.coordinatorlayout.coordinatorlayout-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.core.core-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.cursoradapter.cursoradapter-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.customview.customview-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.documentfile.documentfile-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.drawerlayout.drawerlayout-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.fragment.fragment-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.interpolator.interpolator-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.legacy.legacy-support-core-ui-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.legacy.legacy-support-core-utils-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.lifecycle.lifecycle-common-2.0.0.jar</file>
    <file>Assets/Plugins/Android/androidx.lifecycle.lifecycle-livedata-2.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.lifecycle.lifecycle-livedata-core-2.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.lifecycle.lifecycle-runtime-2.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.lifecycle.lifecycle-viewmodel-2.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.loader.loader-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.localbroadcastmanager.localbroadcastmanager-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.print.print-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.slidingpanelayout.slidingpanelayout-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.swiperefreshlayout.swiperefreshlayout-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.versionedparcelable.versionedparcelable-1.0.0.aar</file>
    <file>Assets/Plugins/Android/androidx.viewpager.viewpager-1.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-ads-identifier-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-base-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-basement-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-measurement-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-measurement-api-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-measurement-base-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-measurement-impl-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-measurement-sdk-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-measurement-sdk-api-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-stats-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.android.gms.play-services-tasks-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.auto.value.auto-value-annotations-1.6.3.jar</file>
    <file>Assets/Plugins/Android/com.google.firebase.firebase-analytics-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.firebase.firebase-analytics-unity-6.2.0.aar</file>
    <file>Assets/Plugins/Android/com.google.firebase.firebase-app-unity-6.2.0.aar</file>
    <file>Assets/Plugins/Android/com.google.firebase.firebase-common-18.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.firebase.firebase-iid-19.0.1.aar</file>
    <file>Assets/Plugins/Android/com.google.firebase.firebase-iid-interop-17.0.0.aar</file>
    <file>Assets/Plugins/Android/com.google.firebase.firebase-measurement-connector-18.0.0.aar</file>
  </files>
  <settings>
    <setting name="androidAbis" value="armeabi-v7a,x86" />
    <setting name="bundleId" value="com.google.firebase.unity.analytics.testapp" />
    <setting name="explodeAars" value="True" />
    <setting name="gradleBuildEnabled" value="True" />
    <setting name="gradleTemplateEnabled" value="False" />
    <setting name="installAndroidPackages" value="True" />
    <setting name="packageDir" value="Assets/Plugins/Android" />
    <setting name="patchAndroidManifest" value="True" />
    <setting name="patchMainTemplateGradle" value="True" />
    <setting name="projectExportEnabled" value="True" />
    <setting name="useJetifier" value="True" />
  </settings>
</dependencies>

Running the resolver in this project actually gives me a bunch of com.google.firebase .aars in my Plugins/Android folder. I’ll try copying them over to my own project and see if that works for now, but it would be nice if the resolver worked in my own project as well!

I already spent hours and hours (every build takes 30 minutes) trying to resolve the issue, so any insight is very appreciated!

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 3
  • Comments: 15 (2 by maintainers)

Most upvoted comments

The problem was fixed:https://firebase.google.com/support/release-notes/unity Download new firebase plugin version

We do not use Analytics, so no idea on that front but for the parse SDK you need the special one for .net4x, I just got it from a higher Firebase SDK.

Yep, had to downgrade to 5.2.1 where it even works with IL2CPP. I guess this issue should get some priority due to the fact that the googles play store will enforce 64bit binaries by the 1st of August.

I noticed that the universal APK had the .so files only for it’s arm-v7a build, could it be that something is not correctly resolved with IL2CPP and ABI splitting?