Are there Firebase Frameworks specifically built for tvOS like https://firebase.google.com/download/ios? Right now, I am trying to use Firebase without CocoaPods. I have been successfully linking Crashlytics and Fabric frameworks without issue. When I attempt to link Firebase, I get the following error...
ld: in FirebaseAnalytics/FirebaseCore.framework/FirebaseCore(FIRAnalyticsConfiguration.o), building for tvOS, but linking in object file (FirebaseAnalytics/FirebaseCore.framework/FirebaseCore(FIRAnalyticsConfiguration.o)) built for iOS, file 'Firebase/ios/FirebaseAnalytics/FirebaseCore.framework/FirebaseCore' for architecture arm64
Firebase does not publish pre-built binaries for tvOS.
Details about tvOS support at https://github.com/firebase/firebase-ios-sdk#tvos-macos-and-catalyst
Follow the open issue at https://github.com/firebase/firebase-ios-sdk/issues/4550
Update March 2020: The Firebase zip distribution includes tvOS slices since the 7.4.0 release. See https://github.com/firebase/firebase-ios-sdk/releases/tag/7.8.1 for the current version.
Related
I tried setting up Firebase Crashlytics to my React Native project.
I received the following error when I was building the project after I added the build phase script.
Script I added from the firebase guide (can be found here) :
Error:
MY-APP-ABC/SourcePackages/checkouts/firebase-ios-sdk/Crashlytics/run:
No such file or directory
When I look in the folder of MY-APP-ABC, I don't see the SourcePackages folder anywhere.
If you installed firebase using cocoa pods use:
"${PODS_ROOT}/FirebaseCrashlytics/run"
If you installed firebase using Swift Package Manager use:
"${BUILD_DIR%/Build/*}/SourcePackages/checkouts/firebase-ios-sdk/Crashlytics/run"
I have an SDK that uses C++ code. The SDK exports 4 different modules in a maven repo that I publish on either a local maven repo or on GitHub packages.
The apps that consume the SDK should be able to use Firebase Crashlytics and get reports of crashes in the native code as well.
The first problem I have is that I need to provide to the Firebase plugin the folders unstrippedNativeLibsDir and strippedNativeLibsDir:
firebaseCrashlytics {
nativeSymbolUploadEnabled true
unstrippedNativeLibsDir "???"
strippedNativeLibsDir "???"
}
If I go to the project where I build the SDK I can see: build/intermediates/merged_native_libs/release and build/intermediates/stripped_native_libs.
Are these the unstripped and stripped folder respectively?
Is there any documentation about what exactly those folders are supposed to contain?
Anyway if I configure the app firebaseCrashlytics to point to these folders I still need to fix another issue.
I get:
Crashlytics could not find NDK build tasks on which to depend. You many need to manually enforce task dependencies
It looks like since I'm building the libs that use the NDK in another project, then the Firebase plugin does not work.
What am I supposed to do?
Is it possible to get the Crashlytics NDK working even if I build the libraries independently with a separate project?
The only way I made it work was to build the libraries along with the app. The libraries were in separate repos anyway but I included them as sub-repositories in the app.
In this way, you solve the issue of not finding NDK build tasks on which to depend.
I know this is not the answer though
I am updating a small application for iOS 12+. I updated the CocoaPod list to use the latest Firebase tools but I am unable to compile because GoogleDataTransport has a file that still references a deprecated method:
Line 129: [NSKeyedArchiver archiveRootObject:self toFile:[GDTCORStorage archivePath]];
It seems the pod is already up to date so I'm not sure how I'm supposed to get around this. Has anyone had the same problem?
Update to at least Xcode 10.1.
Recent versions of Firebase run into this issue with earlier versions of Xcode.
Here's the solution that worked for my case
Xcode 12.5 version
clean derived data
re-open project
update the platform ios target to iOS 12 in a pod file
run pod install
re-launch your project
The reason for depricate errors is because firebase SDK set iOS 12 as the minimum target requirement, but in my pod file, I put iOS13.
We are going to use Firebase C++ SDK for multiple projects, but we are not using cocoapods so we are manually downloading the Firebase SDKs as pointed out in the documentation from here:
https://firebase.google.com/docs/ios/setup#frameworks
https://firebase.google.com/docs/cpp/setup#available_libraries
The Firebase readme file from the downloaded C++ SDK (readme.md) states the following:
Important: Each version of the Firebase C++ SDK supports a specific version of the Firebase iOS SDK. Please ensure that you reference the Cocoapod versions listed above.
The download link from the documentation doesn't have multiple links for each version.
Edit: modified text and images with correct versions
Is there a place where we can download specific versions of the SKDs?
How can we make sure that the download versions are compatible with each other?
Just downloaded both sdks and from the readme:
- C++ SDK is version 5.6.1 and requires Firebase/Core Cocoapod (5.20.0)
- Objective-C SDK has Firebase version 5.20.2
The Objective-C library is a bigger version then requirement of the C++ one (5.20.2 > 5.20.0) but is this property enough to assure compatibility?
See below images for readmes:
readme.md - C++ SDK
README.md - Objective-C SDK
First off it seems that Google forgot to make a branch for the iOS version 5.20.2 (on git currently only this exists: https://github.com/firebase/firebase-ios-sdk/tree/release-5.20.0 )
Considering that only the last number was incremented, let's assume there aren't big changes between the two versions, so we can check 5.20.0.
Your issue is that in the C++ SDK's readme for the iOS part they don't specify exactly the obj-c counterparts but the pods version. You can use the pods files though to check if the versions correspond.
For example we can check "Firebase Auth": in the C++ SDK says that it uses the 5.20.0 pod for ios, which is this one: https://github.com/firebase/firebase-ios-sdk/blob/release-5.20.0/FirebaseAuth.podspec
FirebaseAuth.podspec
We can see in the file that the version of Firebase Auth for the obj-c 5.20.0 SDK is 5.4.2, as it is in your readme.
You can do the same for all necessary services to make sure the compatibility is maintained.
I have no idea unfortunately if you can check this in an automatic way.
My build.gradle is:
// for facebook account kit
compile 'com.facebook.android:account-kit-sdk:4.+'
// for google firebase database
compile 'com.google.firebase:firebase-database:9.6.0'
// for google firebase cloud messaging
compile 'com.google.firebase:firebase-messaging:9.6.0'
After rebuild project,a error happens.
Error:(74, 27) error: Cannot access AbstractSafeParcelable
Cannot find
com.google.android.gms.common.internal.safeparcel.AbstractSafeParcelable class
==============================================
Resolution:
The reason is that after rebuilding the project, gradle download the latest version of "account-kit-sdk" to 4.25.0, the new version changes some about gms, so make some conflicts with firebase messaging,
So I downgrade the account-kit-sdk version, change import version from "account-kit-sdk:4.+" to "account-kit-sdk:4.24.0"
Then the issue has been resolved.
But I think it is not the best resolution about this problem.
Welcome friends add some new ways to resolve this issue.
Thanks.
Version 4.25.0 of com.facebook.android:account-kit-sdk has a dependency on com.google.android.gms:play-services-auth-api-phone:11.0.1 that is not present in version 4.24.0. com.google.android.gms:play-services-auth-api-phone adds many transitive dependencies on other com.google.android.gms modules, including base, basement, tasks, auth, and auth-base.
The Firebase libraries also have transitive dependencies on numerous com.google.android.gms modules. If the version numbers of all of the Firebase and Play Services modules in a build are not the same, problems such as this one occur.
A simple solution is to use version 11.0.1 of all Firebase and Play Services libraries you list in your gradle dependencies:
// for google firebase database
compile 'com.google.firebase:firebase-database:11.0.1'
// for google firebase cloud messaging
compile 'com.google.firebase:firebase-messaging:11.0.1'
You should also specify a fixed version number for the Facebook library to make your build predictable and repeatable:
compile 'com.facebook.android:account-kit-sdk:4.25.0'
The risk of specifying the version as "4.+" is that when a new version is released that has transitive dependencies on a new version of the Play Services libraries, the new Facebook lib version will be automatically used and your build will break again.
To debug problems like this one, you can open the Gradle window in Android Studio and double-click on :app -> Tasks -> android -> androidDependencies to generate a dependency tree. The tree can then be examined to find version mismatches.