简体   繁体   中英

Apple mach-o linker error - MoPubSDK

I've added the MoPub iOS SDK to my rather simple project to allow advertisements from more than just iAd in the app.

When I run the app on the simulator all is fine - but when I attempt to send/copy the app to my iPhone I get 18 'Apple Mach-O Linker Error' error messages saying:

"_MillennialMediaAdObjectKey", referenced from:
  -[MPMillennialBannerCustomEvent adWasTapped:] in MPMillennialBannerCustomEvent.o
  -[MPMillennialBannerCustomEvent modalDidDismiss:] in MPMillennialBannerCustomEvent.o
"_MillennialMediaAdTypeKey", referenced from:
  -[MPMillennialInterstitialCustomEvent notificationIsRelevant:] in MPMillennialInterstitialCustomEvent.o
  -[MPMillennialInterstitialCustomEvent adWasTapped:] in MPMillennialInterstitialCustomEvent.o
"_OBJC_CLASS_$_MMAdView", referenced from:
  objc-class-ref in MPMillennialBannerCustomEvent.o
"_MillennialMediaAPIDKey", referenced from:
  -[MPMillennialInterstitialCustomEvent notificationIsRelevant:] in MPMillennialInterstitialCustomEvent.o
"_MillennialMediaAdModalDidDismiss", referenced from:
  -[MPMillennialInterstitialCustomEvent init] in MPMillennialInterstitialCustomEvent.o
  -[MPMillennialBannerCustomEvent init] in MPMillennialBannerCustomEvent.o
"_MillennialMediaAdModalWillAppear", referenced from:
  -[MPMillennialInterstitialCustomEvent init] in MPMillennialInterstitialCustomEvent.o
"_OBJC_CLASS_$_GADRequest", referenced from:
  objc-class-ref in MPGoogleAdMobInterstitialCustomEvent.o
  objc-class-ref in MPGoogleAdMobBannerCustomEvent.o
"_MillennialMediaAdWasTapped", referenced from:
  -[MPMillennialInterstitialCustomEvent init] in MPMillennialInterstitialCustomEvent.o
  -[MPMillennialBannerCustomEvent init] in MPMillennialBannerCustomEvent.o
"_OBJC_CLASS_$_GADInterstitial", referenced from:
  objc-class-ref in MPGoogleAdMobInterstitialCustomEvent.o
"_OBJC_CLASS_$_MMInterstitial", referenced from:
  objc-class-ref in MPMillennialInterstitialCustomEvent.o
"_OBJC_CLASS_$_GADBannerView", referenced from:
  objc-class-ref in MPGoogleAdMobBannerCustomEvent.o
"_MillennialMediaAdModalWillDismiss", referenced from:
  -[MPMillennialInterstitialCustomEvent init] in MPMillennialInterstitialCustomEvent.o
"_OBJC_CLASS_$_MMRequest", referenced from:
  objc-class-ref in MPMillennialInterstitialCustomEvent.o
  objc-class-ref in MPMillennialBannerCustomEvent.o
"_MillennialMediaAdTypeInterstitial", referenced from:
  -[MPMillennialInterstitialCustomEvent notificationIsRelevant:] in MPMillennialInterstitialCustomEvent.o
  -[MPMillennialInterstitialCustomEvent adWasTapped:] in MPMillennialInterstitialCustomEvent.o
"_MillennialMediaAdModalDidAppear", referenced from:
  -[MPMillennialInterstitialCustomEvent init] in MPMillennialInterstitialCustomEvent.o
"_kGADAdSizeBanner", referenced from:
  -[MPGoogleAdMobBannerCustomEvent frameForCustomEventInfo:] in MPGoogleAdMobBannerCustomEvent.o
"_CGSizeFromGADAdSize", referenced from:
  -[MPGoogleAdMobBannerCustomEvent frameForCustomEventInfo:] in MPGoogleAdMobBannerCustomEvent.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I followed the guide on the MoPub site exactly & have triple checked I have all of the MoPub SDK frameworks flagged as '-fno-objc-arc' & all of my .m files are blank in the 'Build Phases' --> 'Compile Sources group'.

I have done a search on here & most of the responses say to check my personal .m's are listed in the compile sources group section which they all are so any ideas on this are greatly appreciated!!!

Thanks

MoPub SDK当前不支持arm64体系结构。

MoPub Full SDK do not support arm64 architecture as user2820885 said. change the architecture and works fine.

From $(ARCHS_STANDARD) to armv7

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM