- Home /
iOS build linking errors
I'm trying to build my project for iOS but I'm getting following errors:
"_OBJC_CLASS_$_GSDK_GTMSessionFetcher", referenced from:
objc-class-ref in GoogleSignIn(GIDSignIn.o)
objc-class-ref in GoogleSignIn(GIDRuntimeConfigFetcher.o)
objc-class-ref in gpg(GPGClearcutLogger.o)
"_OBJC_CLASS_$_GSDK_GTMOAuth2Keychain", referenced from:
objc-class-ref in GoogleSignIn(GIDSignIn.o)
"_OBJC_CLASS_$_GSDK_GTMOAuth2SignIn", referenced from:
objc-class-ref in GoogleSignIn(GIDAuthentication.o)
objc-class-ref in GoogleSignIn(GIDSignIn.o)
"_OBJC_CLASS_$_GSDK_OpenInChromeController", referenced from:
objc-class-ref in GoogleSignIn(GIDSignIn.o)
"_OBJC_CLASS_$_GSDK_GTMOAuth2ViewControllerTouch", referenced from:
objc-class-ref in GoogleSignIn(GIDSignIn.o)
"_OBJC_CLASS_$_GSDK_GTMSessionFetcherService", referenced from:
objc-class-ref in GoogleSignIn(GIDSignIn.o)
objc-class-ref in gpg(GIPNetworkImage.o)
"_GSDK_NSClassFromString", referenced from:
l011 in GoogleSignIn(GIDSignIn.o)
l059 in GoogleSignIn(GIDSignIn.o)
"_OBJC_CLASS_$_GSDK_GTMOAuth2Authentication", referenced from:
objc-class-ref in GoogleSignIn(GIDAuthentication.o)
objc-class-ref in GoogleSignIn(GIDSignIn.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I have tried following things :
Added googleSingin frame work and google open source framework.
made sure all bundles are added in Copy bundle resources
$(inherited) is present in header search paths , framework search paths and library search paths
Enable Bit code is set to "No"
In other linker flags I added flag -ObjC
I'm not able to figure what is it that I'm missing out. Any help regarding this is appreciated.
Thank you.
Answer by 5c4r3cr0w · May 23, 2016 at 02:40 PM
I finally figured it out. I have Gooogle mobile ads plugin and google play game plugins both. I didn't installed cocoa pods and I was adding all frameworks in Xcode. installing cocoa pods did the job :)
I have the same problem as you had.
How did you install the pods? I dont even know what they are, but i guess i need them.
Cheers!
Open ter$$anonymous$$al and fire command : sudo gem install cocoapods
I have CocoaPods installed. Though Unity hasn't generated a .xcworkspace
file, how did installing CocoaPods fix your problem?
Well, latest documents says you don't need pods if you are targeting iOS 7 or higher. You need to have google mobile ads SD$$anonymous$$. Here .
And in order to make .xcworkspace file there should be a pod executable. Can you confirm this there is pod file in your project and it's getting executed in postProcess build?
I'm targeting iOS 9, because some post suggested that.
This is my first ever time with xCode and I'm not too sure of a lot of things. I can confirm that there is a podfile (titled 'Podfile', no extension). I had once tried adding some pods to this file. I can post the Unity generated version of this Podfile that I'm currently using.
How do I check if it is getting executed in postProcess build?