5

I am trying to update my project to use CocoaPods 0.36.0's new use_frameworks! option. I am using Objective-C (not Swift) in Xcode 6.2 and the deployment target is 8.1.

Everything is building and linking correctly except for Google Analytics, for which I get linker errors:

Undefined symbols for architecture x86_64: "_OBJC_CLASS_$_GAI", referenced from: objc-class-ref in NPDAnalytics.o "_OBJC_CLASS_$_GAIDictionaryBuilder", referenced from: objc-class-ref in NPDAnalytics.o ld: symbol(s) not found for architecture x86_64

I have tried changing my old-style

#import <GoogleAnalytics_iOS_SDK/GAI.h>

to a module import:

@import GoogleAnalytics_iOS_SDK;

But that didn't help anything.

Is GAI just incompatible with CocoaPods' implementation of dynamic frameworks or is there some other trick to getting it to work?

roperklacks
  • 1,081
  • 11
  • 13

1 Answers1

0

I've successfully added this dependency by adding the platform limit with this instruction in the podspec of your private library to limit to iOS devices only :

Pod::Spec.new do |m|
    ...
    m.platform = :ios, "7.0"
cdescours
  • 6,004
  • 3
  • 24
  • 30