I want to implement AdMob functionality in current project. I am getting some issues to implement this technology. Could you please help me on this?
I am integrating AdMob in my iOS application first time. During this process when add AdMob SDK into app , following errors appears.
Undefined symbols for architecture i386:
"_OBJC_CLASS_$_CTTelephonyNetworkInfo", referenced from:
objc-class-ref in libGoogleAdMobAds.a(GADDevice.o)
"_OBJC_CLASS_$_SKStoreProductViewController", referenced from:
objc-class-ref in libGoogleAdMobAds.a(GADOpener.o)
"_SKStoreProductParameterITunesItemIdentifier", referenced from:
-[GADOpener openInAppStore:fallbackURLString(inlove) 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)
Follow Google AdMob guide
You have to import following frameworks -
AdSupport,
AudioToolbox,
AVFoundation,
CoreGraphics,
CoreTelephony,
MessageUI,
StoreKit,
SystemConfiguration
you have to import all of these frameworks in your app for AdMob integration
1) AudioTollbox.framework,
2) MediaPlayer.framework
3) MessageUI.framework,
4) SystemConfiguration.framework,
5) StoreKit Framework
6) CoreTelephony Framework
Related
I tried to include FBAudienceNetwork.framework because i want to display banner/interstitial ad unit in my app. But my app gave me several errors.
Error
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_CIContext", referenced from:
objc-class-ref in FBAudienceNetwork(FBAdUtility.o)
"_OBJC_CLASS_$_CIFilter", referenced from:
objc-class-ref in FBAudienceNetwork(FBAdBlurredImageView.o)
objc-class-ref in FBAudienceNetwork(FBAdUtility.o)
"_kCIInputImageKey", referenced from:
___65-[FBAdBlurredImageView sliceImage:withAspectRatioInfo:withBlock:] _block_invoke42 in FBAudienceNetwork(FBAdBlurredImageView.o)
+[FBAdUtility(FBAdViewUtility) blurImage:withRadius:] in FBAudienceNetwork(FBAdUtility.o)
"_OBJC_CLASS_$_EAGLContext", referenced from:
objc-class-ref in FBAudienceNetwork(FBAdUtility.o)
"_kCIContextWorkingColorSpace", referenced from:
+[FBAdUtility(FBAdViewUtility) blurImage:withRadius:] in FBAudienceNetwork(FBAdUtility.o)
"_kCIInputScaleKey", referenced from:
___65-[FBAdBlurredImageView sliceImage:withAspectRatioInfo:withBlock:] _block_invoke42 in FBAudienceNetwork(FBAdBlurredImageView.o)
"_OBJC_CLASS_$_CIImage", referenced from:
objc-class-ref in FBAudienceNetwork(FBAdBlurredImageView.o)
objc-class-ref in FBAudienceNetwork(FBAdUtility.o)
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Framework
- MediaPlayer
- CoreMedia
- SystemConfiguration
- CoreTelephony
- AVFoundation
- StoreKit
- CoreMotion
- AdSupport
- Foundation
- CoreGraphics
- UIKit
- libc++.dylib
- libz.dylib
Setting
Architecture : $(ARCHS_STANDARD_INCLUDING_64_BIT)
Deployment Target : 7.0
FBAudienceNetwork version : v4.1.0
Additionally,
Do I need to include Bolts.framework for using just Audience Network?
After including it, errors are gone.
So I wonder if Bolts.framework is needed.
(When I use FBAudienceNetwork v3.23, these error were not occurred)
I found out the solution.
I just changed my project setting.
Apple LLVM 6.0 - Language - Modules
: Enable Modules (C and Objective-C) => YES
I hope this will be helpful for developers to use facebook's audience network.
It seems that your FBAudienceNetwork v4.1.0 doesn't support armv7 architecture. If that library is static - use Lipo or another tool to create a library file (.a) which support this architecture too. If this library isn't static - just add armv7 in its project file (FBAudienceNetwork.xcodeProj > Build Settings > Architecture).
I have activated arm7 armv7 arm64 as valid architecture for 64 bit requirement by Apple recently but when I try to build the app in Xcode it throws me this error. I get a warning first for libchartboost.a not being found, I download the chartboost latest folder from their website but it does not have libchartboost.a so I am still using chartboost 3.2.1. But not sure if thats the issue since I get an error related to GameScene below. Am I missing a framework? Thanks for your help.
ld: warning: ignoring file /Users/Administrator/Documents/Software/libChartboost.a, missing required architecture arm64 in file /Users/Administrator/Documents/Software/libChartboost.a (3 slices)
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_GameScene", referenced from:
objc-class-ref in AlertLayer.o
objc-class-ref in GameLayer.o
objc-class-ref in levelpackMenuLayer.o
objc-class-ref in LevelSelectLayer.o
objc-class-ref in timetrialMenuLayer.o
objc-class-ref in IAPHelper.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Probably an old thread, but in such linker errors, following step works:
Link all the required frameworks along with Chartboost framework, such as Storekit, Webkit, AVFoundation, Foundation etc.
These are all the frameworks that are used by Chartboost framework to fetch and display ads in media formats (audio and video).
For latest details on how to fully integrate and what all frameworks are required, refer to this guide.
I am trying to display AppLovin sdk in my cocos2d project in Xcode and I'm currently unable to debug this Apple Mach-O error as described below.
Undefined symbols for architecture i386:
"_CMTimeGetSeconds", referenced from:
-[ALVideoViewController timeLeft] in libAppLovinSdk.a(ALVideoViewController.o)
-[ALVideoViewController percentViewed] in libAppLovinSdk.a(ALVideoViewController.o)
"_CMTimeMakeWithSeconds", referenced from:
-[ALVideoViewController createCountdownTimeObserver] in libAppLovinSdk.a(ALVideoViewController.o)
"_MPMoviePlayerPlaybackDidFinishNotification", referenced from:
___50-[ALInterstitialViewController prepareForVideoAd:]_block_invoke in libAppLovinSdk.a(ALInterstitialViewController.o)
"_MPMoviePlayerPlaybackDidFinishReasonUserInfoKey", referenced from:
___53-[ALInterstitialViewController moviePlayerDidFinish:]_block_invoke in libAppLovinSdk.a(ALInterstitialViewController.o)
"_MPMoviePlayerPlaybackStateDidChangeNotification", referenced from:
___50-[ALInterstitialViewController prepareForVideoAd:]_block_invoke in libAppLovinSdk.a(ALInterstitialViewController.o)
"_OBJC_CLASS_$_MPMoviePlayerController", referenced from:
objc-class-ref in libAppLovinSdk.a(ALInterstitialViewController.o)
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I went to build phases -> add other -> Selected libAppLovinSdk.a file from the finder displayed.
I also set the value of Build Active Architectures only to NO and removed arm64 from architectures. There is no i386 architecture.
You are missing the CoreMedia and MediaPlayer frameworks.
(I found this out by Googling for CMTimeGetSeconds and MPMoviePlayerPlaybackDidFinishNotification and seeing what section of the Apple docs got hits, however the CM and MP prefixes should be enough to tell you).
Xcode 5.1 (5B130a)
iOS 7.1
using CocoaPods
pod 'Google-AdMob-Ads-SDK'
compile failed with log:
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_SKStoreProductViewController", referenced from:
objc-class-ref in libGoogleAdMobAds.a(GADOpener.o)
"_SKStoreProductParameterITunesItemIdentifier", referenced from:
-[GADOpener openInAppStore:fallbackURLString:] in libGoogleAdMobAds.a(GADOpener.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Double check to make sure that the GAD library has been added in xcode linked frameworks and libraries.
The second thing to look at is the Storekit framework. These classes that are giving you an error are from the storekit. Check to ensure that it's added to your project
try to add CoreTelephony and CoreText in framework of project.
I am trying to integrate iAds in Admob mediation SDK for that purpose, I downloaded iAdListAdapter from Mediation website Download Link and added it into my xcode project but now when I try to compile the project it is giving following error:
Undefined symbols for architecture i386:
"_ADBannerContentSizeIdentifierLandscape", referenced from:
-[GADMAdapterIAd getBannerWithSize:] in libAdapterIAd.a(GADMAdapterIAd.o)
-[GADMAdapterIAd adjustADBannerToAdSize] in libAdapterIAd.a(GADMAdapterIAd.o)
"_ADBannerContentSizeIdentifierPortrait", referenced from:
-[GADMAdapterIAd getBannerWithSize:] in libAdapterIAd.a(GADMAdapterIAd.o)
-[GADMAdapterIAd adjustADBannerToAdSize] in libAdapterIAd.a(GADMAdapterIAd.o)
"_OBJC_CLASS_$_ADBannerView", referenced from:
objc-class-ref in libAdapterIAd.a(GADMAdapterIAd.o)
"_OBJC_CLASS_$_ADInterstitialAd", referenced from:
objc-class-ref in libAdapterIAd.a(GADMAdapterIAd.o)
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Please guide what am I doing wrong or what is the correct way of adding iAds to Mediation SDk by the way: I am using XCode 4.6 with min sdk 5.0
Any help is really appreciated!
Turned out that i needed to add iAd.Framework and remove -all_load Flag in the project, which solved the Problem.
For People who use auto linking please include "#import < iAd/iAd.h >" in any of your source files/