I'm installing the Firebase Auth SDK manually, rather than using cocoapods, and I'm getting this weird error:
Undefined symbols for architecture x86_64:
"___gxx_personality_v0", referenced from:
+[FIRHash calculatedFingerprintForString:] in FirebaseCore(FIRHash_11b6df6535f55516149376a0824d22ab.o)
ld: symbol(s) not found for architecture x86_64
I installed all the resources the Auth framework depends on, so I'm not sure why this is happening. The documentation doesn't mention installing anything else. Any idea how to get this going?
The xcode build is not linking the C++ libraries.
Add the "-lc++" to Other Linker Flags
Related
In migrating my Fabric/Crashlytics SDK into FirebaseCrashlytics, I've decided to integrate cocoapods.
After adding FirebaseCrashlytics and FirebaseAnalytics into the Podfile, I am getting this error when I compile and I can't figure out why it is happening:
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_GSDK_GTMLogger", referenced from:
objc-class-ref in GoogleIPhoneUtilities(GIPReachability.o)
"_kFirebaseCloudMessagingErrorDomain", referenced from:
-[FIRMessaging(FIRApp) configureMessaging:] in FirebaseMessaging(FIRMessaging+FIRApp_ed2c92d2ac2b5969ab6c5684759ab5bd.o)
-[FIRMessaging(FIRApp) exitApp:withError:] in FirebaseMessaging(FIRMessaging+FIRApp_ed2c92d2ac2b5969ab6c5684759ab5bd.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
What am I missing?
EDIT: - I've fixed the second issue with FirebaseMessaging, for the life of me, I can't figure out why I'm having issues with this:
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_GSDK_GTMLogger", referenced from:
objc-class-ref in GoogleIPhoneUtilities(GIPReachability.o)
All of the Firebase Repos I'm using are currently now set up via Cocoapods.
It looks like the app is linking a very old copy of FirebaseMessaging and some of its dependencies with recent versions of Analytics and Crashlytics.
Since Firebase libraries share dependencies, it is not likely to work to mix incompatible versions or installation methods.
Something with linking... Looks like the wrong podfile configuration. Make sure that you add target pods to the needed App target correctly.
Building with Unity 2018.4.2 - Xcode 10.2 - Latest iOS Targets
Firebase Latest (6.1.1) for Unity with .Net 4
For Firebase We are using the following unity packages:
- FirebaseMessaging.unitypackage
- FirebaseAnalytics.unitypackage
Get the following Build Error in Xcode:
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_FIRDynamicLinks", referenced from:
objc-class-ref in libFirebaseCppApp.a(invites_receiver_internal_ios_aa7b75b2efc3269e88f1077e55250e5a.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
On another Machine same error however armv7 target:
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_FIRDynamicLinks", referenced from:
objc-class-ref in libFirebaseCppApp.a(invites_receiver_internal_ios_aa7b75b2efc3269e88f1077e55250e5a.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Tested Solutions (no solution yet):
Obj-C to frameworks (was already there)
Updated Cocoa Pods to Latest
Deleted Developer/Xcode/DerivedData
Updated Cocoa Pods and deleted caches
The strangest thing is this only started happening on Monday, previously was working, nothing else was changed, so this leads to believe this is Google changed something in their Cocoa pods library which is linking agains't another package which is not included now.
Problem does not occur in the same Android Variant of the Project.
Solution:
It now requires you to also include and install Firebase: DynamicLinks in order to compile for iOS.
FirebaseDynamicLinks.unitypackage
So install the following package into your unity project from the download of Firebase Unity.
I am attempting to build a project I did not write, and I keep reaching this error:
ld: warning: Auto-Linking supplied '/Users/my_user_name/Documents/FacebookSDK/FBSDKCoreKit.framework/FBSDKCoreKit', framework linker option at /Users/my_user_name/Documents/FacebookSDK/FBSDKCoreKit.framework/FBSDKCoreKit is not a dylib
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_FBSDKAppEvents", referenced from:
objc-class-ref in AppDelegate.o
"_OBJC_CLASS_$_FBSDKApplicationDelegate", referenced from:
objc-class-ref in AppDelegate.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
This is a new error since updating Parse and Bolts pods. Other solutions for Auto-Linking that I've seen on here have not been able to help, but since the update to Facebook SDK is new perhaps someone has already solved this issue.
It's because of the conflict between the reference of FB SDK located at /Users/my_user_name/Documents/ and the one in CocoaPods.
Originally I used FB SDK located at /Users/my_user_name/Documents/ as suggested in FB SDK Getting Started tutorial. Then switched to Cocoapods after I started using react-native.
The solution is to remove Facebook SDK references from your apps Frameworks folder in YourApp.xcodeproj. I have explained more at https://stackoverflow.com/a/36947791/556678.
Make sure you're using a current version of the FBSDK! Also make sure you followed THESE (new) instructions: https://parse.com/docs/ios/guide#users-facebook-users (because with the parse update different things must be done!).
If the problem persists, I suggest you build a new project (that follows the instructions in the previous link).
I just download new facebook ios sdk.
It reports error when build,
ld: warning: directory not found for option '-F"/Users/myname/cd-standard/apple/apple_ios/Projects/fotoshow_ios/my app/../../../../../../Documents/FacebookSDK"'
Undefined symbols for architecture i386:
"_OBJC_CLASS_$_FBSBJSON", referenced from:
objc-class-ref in FacebookController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
the prohect with former facebook ios sdk works well, I only install the new ios sdk using downloaded installer.
I also check and find out all frameworks needed are there, but it still reports error
your comment welcome
FBSBJSON was removed in v3.5 of the Facebook SDK (released April 18, 2013), but your FacebookController class is still referencing it. You should remove the reference in your FacebookController class, or if you're using some other SDK which wraps the Facebook SDK, you'll probably need to update that as well.
I have integrated GAI using the most recent cocoapods version.
When I build in the Debug config everything runs just fine.
However, as soon as I try to archive the Application the compiler fails with the following messages:
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_GAIDictionaryBuilder", referenced from:
objc-class-ref in libWLCore.a(WLTrackingHelper.o)
"_OBJC_CLASS_$_GAI", referenced from:
objc-class-ref in libWLCore.a(WLTrackingHelper.o)
"_kGAIScreenName", referenced from:
+[WLTrackingHelper trackView:] in libWLCore.a(WLTrackingHelper.o)
+[WLTrackingHelper resetView] in libWLCore.a(WLTrackingHelper.o)
"_kGAIAnonymizeIp", referenced from:
+[WLTrackingHelper prepareDefaultTracker:withAnonymization:withUnCaughtExceptions:withDebug:] in libWLCore.a(WLTrackingHelper.o)
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Since it works in Debug I tried to figure out where the difference in the configuration between Debug and Release lies.
I found out that the Other linker flags in Release are empty whereas in Debug contains the flag for GoogleAnalytics and other frameworks and libraries.
After adding the flags to the Release Configuration of Other linker flags I got
library not found for -lGoogleAnalyticsServices
After that, I added libPods and after that libPods-GoogleAnalytics to the Link Binary With Libraries section but the errors remained the same.
I invested almost 2 days into that problem, but I could not find any solution.
After some fiddling I found the solution by adding not the library generated by cocoa pods (libPods-GoogleAnalytics), but directly linking the libGoogleAnalyticsServices to my main project. Still, I think this is not the most elegant solution possible since the linker should know that the symbols he was missing were available already, as provided by cocoapods.
Please confirm you have added $(inherited) to Other Linker Flags (Build Settings) as in the below image. Add the same in Release also, otherwise the same error will pop up at the time of archiving.