Reputation: 951
I'm upgrading my iOS project to the new versions of the parse and Facebook SDKs because Swift 1.2 doesn't support older versions.
Now that I've upgraded I can't get rid of a linker error. I've added parse 1.7.1 and removed the import statement from my bridging header. With just parse the compiler did not complain.
But since I use facebook login, I also need to include the FacebookSDK. I've added the facebookSDK 4.0.1 and this is where the problem arises.
I know have 1 warning and 9 errors. Here are the errors
Undefined symbols for architecture x86_64:
"_FBTokenInformationExpirationDateKey", referenced from:
-[PFFacebookTokenCachingStrategy cacheTokenInformation:] in ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)
-[PFFacebookTokenCachingStrategy expirationDate] in ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)
-[PFFacebookTokenCachingStrategy setExpirationDate:] in ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)
"_FBTokenInformationTokenKey", referenced from:
-[PFFacebookTokenCachingStrategy accessToken] in ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)
-[PFFacebookTokenCachingStrategy setAccessToken:] in ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)
"_FBTokenInformationUserFBIDKey", referenced from:
-[PFFacebookTokenCachingStrategy facebookId] in ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)
-[PFFacebookTokenCachingStrategy setFacebookId:] in ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)
"_OBJC_CLASS_$_FBAppCall", referenced from:
objc-class-ref in ParseFacebookUtils(PFFacebookAuthenticationProvider.o)
"_OBJC_CLASS_$_FBRequest", referenced from:
objc-class-ref in ParseFacebookUtils(PFFacebookAuthenticationProvider.o)
"_OBJC_CLASS_$_FBSession", referenced from:
objc-class-ref in ParseFacebookUtils(PFFacebookAuthenticationProvider.o)
"_OBJC_CLASS_$_FBSessionTokenCachingStrategy", referenced from:
_OBJC_CLASS_$_PFFacebookTokenCachingStrategy in ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)
"_OBJC_METACLASS_$_FBSessionTokenCachingStrategy", referenced from:
_OBJC_METACLASS_$_PFFacebookTokenCachingStrategy in ParseFacebookUtils(PFFacebookTokenCachingStrategy.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I've tried things like adding the -ObjC
linker flag, removing and readding the SDK. Can't think of anything else.
Not sure what to do
Upvotes: 2
Views: 542
Reputation: 6526
I have the same problem. I upgraded to Xcode 6.3 and Swift 1.2. I was importing the Facebook 4.0.1 SDK for the first time with Parse. This is what I tried so far.
and added the PFFacebookUtilsV4 library
Then I added the import to my Bridging-Headrer
import FBSDKCoreKit/FBSDKCoreKit.h
import ParseFacebookUtilsV4/PFFacebookUtils.h
I got the same error above from your question.
I updated the Parse SDK and still couldn't find a solution. Tried to import the libraries in the AppDelegate.swift and still couldn't do it. Tried accessing the PFFacebookUtils but after adding the FBSDK, Xcode can't find this file.
Thank you for helping..
Upvotes: 1