23

I'm adding admob to my project, but I get this error:

Undefined symbols for architecture i386:

 "_OBJC_CLASS_$_EKEvent", referenced from:
      objc-class-ref in libGoogleAdMobAds.a(GADOpener.o)
  "_OBJC_CLASS_$_EKEventEditViewController", referenced from:
      objc-class-ref in libGoogleAdMobAds.a(GADOpener.o)
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I have added:

StoreKit
AudioToolbox
MessageUI
SystemConfiguration
CoreGraphics
AdSupport

And also use -ObjC link flags..

What is the problem?

Thanks!

PSP
  • 196
  • 1
  • 14
user3745888
  • 6,143
  • 15
  • 48
  • 97

7 Answers7

55

I just upgraded from Google Admob SDK 6.11 to 6.12 and these same errors popped up.

In the project navigator click on your project properties in the top and make sure the correct target is selected. Go to the Build Phases tab and scroll to Link Binaries With Libraries. Add both EventKit.framework and EventKitUI.framework to this list.

As always, Clean and Build your project. The errors should go away.

GMBrian
  • 917
  • 1
  • 10
  • 16
  • 2
    Damn I spent way more time then I should have trying to figure out why this wasn't working! Thanks! – Nathan Sep 23 '14 at 16:33
  • 2
    @Jackson I had the same problem. Adding CoreTelephony Framework solved my problem. You can see all required frameworks on this link https://developers.google.com/mobile-ads-sdk/docs/dfp/ios/quick-start – barisemreefe Sep 24 '14 at 08:22
  • Dude, thanks, I wish I've seen this before... lost some time with this, thanks! – Badjano Oct 03 '14 at 04:31
  • aagghhh... I feel stupid... I had even done a visual one-by-one confirmation that I had every depended framework linked, when I updated from 6.4 to 6.12 today. I saw EventKitUI missing, but ignored it. Then lost half an hour trying to figure out why a symbol wasn't found for i386.. duh.. Thanks GMBrain. :) – Tom Pace Nov 04 '14 at 02:19
  • works great. google needs to update their manual. https://developers.google.com/mobile-ads-sdk/docs/admob/ios/quick-start – Piyush-Ask Any Difference Nov 26 '14 at 20:37
10

Please check that you have added all those libraries

  • AdSupport
  • AudioToolbox
  • AVFoundation
  • CoreGraphics
  • CoreTelephony
  • EventKit
  • EventKitUI
  • MessageUI
  • StoreKit
  • SystemConfiguration
Aemgtz
  • 113
  • 6
  • Works for me! Getting this error by adding admob, error is away after adding these libraries and clean/run project. – basti12354 Sep 26 '14 at 23:01
1

I found out, If you are using swift package manager for version 9.0 and above you are also need add JavaScriptCore.framework dependencyenter image description here

0

I solve this adding EvenKit framework. In SdkiOS 6.12 adMob is necessary this for solve my errors.

user3745888
  • 6,143
  • 15
  • 48
  • 97
0

I had this issue and for me it was missing MessageUI.framework.

This is the most current list of frameworks you need to include for AdMob: (July 2016)

AdSupport.framework,
EventKit.framework,
EventKitUI.framework,
CoreTelephony.framework,
StoreKit.framework,
MessageUI.framework
Deyan Vitanov
  • 695
  • 5
  • 18
0

June 5, 2017

For Google Mobile Ads SDK version 7.20.0 the following frameworks are required.

  • GLKit
  • CoreTelephony
  • CoreMedia
  • CoreVideo
  • MessageUI
  • CFNetwork
  • MobileCoreServices
Ehtesham Hasan
  • 4,133
  • 2
  • 23
  • 31
0

in y case it was all about:

GoogleMobileAdsMediationTestSuite

I removed this pod and project build again.

Sajjad Sarkoobi
  • 827
  • 8
  • 18