转载此篇文章,做一个记录
通常解决方法为在项目中添加相应的类库:
选中项目 -> Build Phases -> Link Binary With Libraries -> 点击+ -> 搜索合适的库 -> 点击Add -> 重新编译
如果是自己编写的时候使用到一些相关类,除了添加框架之外,还应该包含一下头文件,例如:
#import "QuartzCore/QuartzCore.h"
备注:一般_k开头只是常量的意思,跟无k开头是一样的
如果缺少一些基本的变量,很可能是缺少Foundation.framework或者AVFoundation.framework(最近在手动集成高德地图时发现的问题,官方文档和demo中都没有介绍到),如:
_objc_autoreleasePoolPush
_objc_msgSend
_objc_retain
_objc_release
_UI开头——UIKit.framework,如:
_UIApplicationMain
_UIResponder
_UIViewController
_CA和_kCA开头——QuartzCore.framework,如:
_CATransform3DMakeScale
_CAKeyframeAnimation
_CAAnimationGroup
_CAMediaTimingFunction
_kCAFillModeForwards
_kCAMediaTimingFunctionEaseIn
_SSL开头——Security.framwork,如:
_SSLRead
_SSLClose
_SSLWrite
_SSLGetBufferedReadSize
_SSLSetIOFuncs
_CF和_kCF开头——CFNetwork.framework,如:
_kCFStreamNetworkServiceType
_kCFStreamPropertySSLSettings
_kCFStreamSSLIsServer
_kCFStreamSSLLevel
_kCFStreamSSLPeerName
_CT和_kCT开头——CoreText.framework
_CTFontCreateWithName
_CTLineGetGlyphRuns
_CTRunGetAttributes
_CTFontGetSize
_kCTFontAttributeName
_SC开头——SystemConfiguration.framework
_SCNetworkReachabilitySetCallback
_SCNetworkReachabilityScheduleWithRunLoop
_SCNetworkReachabilityCreateWithName
_SCNetworkReachabilityGetFlags
_SCNetworkReachabilityCreateWithAddress
_UI和_kUI——MobileCoreServices.framework
_UTTypeCreatePreferredIdentifierForTag
_UTTypeCopyPreferredTagWithClass
_kUTTagClassMIMEType
_AL——AssetsLibrary.framework
ALAsset
转载至:http://blog.csdn.net/sirodeng/article/details/9413163