使用ShareKit ios的链接器错误

前端之家收集整理的这篇文章主要介绍了使用ShareKit ios的链接器错误前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我花了3天时间来搜索解决方案.我不知道该怎么做…我需要SDBeb图标的-ObjC标志(我也认为AFNetworking).我可以删除它,一切都很好用ShareKit,但不是很好用SDweb Image.
Undefined symbols for architecture i386:
  "_ABAddressBookCopyArrayOfAllPeople",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABAddressBookCreateWithOptions",referenced from:
      +[GPPAddressBook loadDeviceContactsWithHandler:] in GooglePlus(GPPAddressBook.o)
  "_ABAddressBookGetPersonCount",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABAddressBookRequestAccessWithCompletion",referenced from:
      +[GPPAddressBook loadDeviceContactsWithHandler:] in GooglePlus(GPPAddressBook.o)
  "_ABMultiValueCopyValueAtIndex",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABMultiValueGetCount",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABPersonCopyImageDataWithFormat",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABPersonHasImageData",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ABRecordCopyValue",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_ACAccountTypeIdentifierFacebook",referenced from:
      -[SHKiOSFacebook accountTypeIdentifier] in libShareKit.a(SHKiOSFacebook.o)
  "_ACAccountTypeIdentifierSinaWeibo",referenced from:
      -[SHKSinaWeibo accountTypeIdentifier] in libShareKit.a(SHKSinaWeibo.o)
  "_ACAccountTypeIdentifierTwitter",referenced from:
      -[SHKiOSTwitter accountTypeIdentifier] in libShareKit.a(SHKiOSTwitter.o)
  "_ACFacebookAppIdKey",referenced from:
      -[SHKiOSFacebook authorizationFormShow] in libShareKit.a(SHKiOSFacebook.o)
  "_ACFacebookAudienceEveryone",referenced from:
      -[SHKiOSFacebook authorizationFormShow] in libShareKit.a(SHKiOSFacebook.o)
  "_ACFacebookAudienceKey",referenced from:
      -[SHKiOSFacebook authorizationFormShow] in libShareKit.a(SHKiOSFacebook.o)
  "_ACFacebookPermissionsKey",referenced from:
      -[SHKiOSFacebook authorizationFormShow] in libShareKit.a(SHKiOSFacebook.o)
  "_AVURLAssetPreferPreciseDurationAndTimingKey",referenced from:
      -[SHKFile getDuration] in libShareKit.a(SHKFile.o)
  "_CMTimeGetSeconds",referenced from:
      -[SHKFile getDuration] in libShareKit.a(SHKFile.o)
  "_MPMoviePlayerThumbnailImageKey",referenced from:
      -[GPPMediaPreviewView thumbnailImageRequestDidFinish:] in GooglePlus(GPPMediaPreviewView.o)
  "_MPMoviePlayerThumbnailImageRequestDidFinishNotification",referenced from:
      -[GPPMediaPreviewView initWithFrame:mediaAttachment:] in GooglePlus(GPPMediaPreviewView.o)
      -[GPPMediaPreviewView thumbnailImageRequestDidFinish:] in GooglePlus(GPPMediaPreviewView.o)
  "_OBJC_CLASS_$_ACAccountStore",referenced from:
      objc-class-ref in libShareKit.a(SHKiOSFacebook.o)
      objc-class-ref in libShareKit.a(SHKiOSSharer.o)
  "_OBJC_CLASS_$_ALAssetsLibrary",referenced from:
      objc-class-ref in GooglePlus(NSData+GPPAdditions.o)
      objc-class-ref in GooglePlus(UIDevice+GPPAdditions.o)
      objc-class-ref in libShareKit.a(SHKPhotoAlbum.o)
  "_OBJC_CLASS_$_AVURLAsset",referenced from:
      objc-class-ref in libShareKit.a(SHKFile.o)
  "_OBJC_CLASS_$_CLLocationManager",referenced from:
      objc-class-ref in GooglePlus(UIDevice+GPPAdditions.o)
      objc-class-ref in libShareKit.a(SHKFoursquareV2VenuesForm.o)
      objc-class-ref in libShareKit.a(SHKFoursquareV2.o)
  "_OBJC_CLASS_$_CMMotionManager",referenced from:
      objc-class-ref in GooglePlus(GPPSpamSignal.o)
  "_OBJC_CLASS_$_MPMoviePlayerController",referenced from:
      objc-class-ref in GooglePlus(GPPMediaPreviewView.o)
  "_OBJC_CLASS_$_SKStoreProductViewController",referenced from:
      objc-class-ref in libShareKit.a(EvernoteSession.o)
  "_OBJC_CLASS_$_SLComposeViewController",referenced from:
      objc-class-ref in libShareKit.a(SHKiOSSharer.o)
      objc-class-ref in libShareKit.a(SHKSinaWeibo.o)
  "_OBJC_CLASS_$_SLRequest",referenced from:
      objc-class-ref in libShareKit.a(SHKiOSFacebook.o)
      objc-class-ref in libShareKit.a(SHKiOSTwitter.o)
  "_SKStoreProductParameterITunesItemIdentifier",referenced from:
      -[EvernoteSession installAppWithId:withViewController:] in libShareKit.a(EvernoteSession.o)
  "_SLServiceTypeFacebook",referenced from:
      -[SHKiOSFacebook serviceTypeIdentifier] in libShareKit.a(SHKiOSFacebook.o)
      -[SHKiOSFacebook sendFeed] in libShareKit.a(SHKiOSFacebook.o)
      -[SHKiOSFacebook sendPhoto] in libShareKit.a(SHKiOSFacebook.o)
      -[SHKiOSFacebook sendVideo] in libShareKit.a(SHKiOSFacebook.o)
      -[SHKiOSFacebook fetchUserInfo] in libShareKit.a(SHKiOSFacebook.o)
  "_SLServiceTypeSinaWeibo",referenced from:
      +[SHKSinaWeibo canShare] in libShareKit.a(SHKSinaWeibo.o)
      -[SHKSinaWeibo share] in libShareKit.a(SHKSinaWeibo.o)
  "_SLServiceTypeTwitter",referenced from:
      -[SHKiOSTwitter serviceTypeIdentifier] in libShareKit.a(SHKiOSTwitter.o)
      -[SHKiOSTwitter sendStatusViaTwitter:mimeType:filename:] in libShareKit.a(SHKiOSTwitter.o)
      -[SHKiOSTwitter sendDataViaYFrog:mimeType:filename:] in libShareKit.a(SHKiOSTwitter.o)
      -[SHKiOSTwitter fetchUserInfo] in libShareKit.a(SHKiOSTwitter.o)
      -[SHKiOSTwitter downloadAPIConfiguration] in libShareKit.a(SHKiOSTwitter.o)
      -[SHKiOSTwitter authorizationYFrogHeader] in libShareKit.a(SHKiOSTwitter.o)
  "_kABPersonEmailProperty",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_kABPersonFirstNameProperty",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_kABPersonLastNameProperty",referenced from:
      ___48+[GPPAddressBook loadDeviceContactsWithHandler:]_block_invoke in GooglePlus(GPPAddressBook.o)
  "_kCLLocationAccuracyBest",referenced from:
      -[SHKFoursquareV2VenuesForm startMonitoringLocation] in libShareKit.a(SHKFoursquareV2VenuesForm.o)
ld: symbol(s) not found for architecture i386
clang: error: linker command Failed with exit code 1 (use -v to see invocation)

解决方法

看起来你错过了不少框架.根据所提到的符号,添加下面的框架列表来解决链接错误,

> AddressBook.framework
> AVFoundation.framework
CoreMedia.framework
> MediaPlayer.framework
> Accounts.framework
> AssetsLibrary.framework
> CoreLocation.framework
> CoreMotion.framework
> StoreKit.framework
>社会框架

希望有帮助!

原文链接:https://www.f2er.com/iOS/329166.html

猜你在找的iOS相关文章