xcode编译错误总结

  1. No architectures to compile for(ONLY_ACTIVE_ARCH=YES   

       这种错误    修改building settings下 Build Active Architecture only 为NO便可。
  2. dyld: Symbol not found: _objc_setProperty_nonatomic    

      _objc_setProperty_nonatomic是ios6.0的新方法,三方库设置了Deployment Target 为6.0就会调用这2个新增的方法,为ios5中没有,咱们的项目是支持ios5的。因此报错。把lib的target设置为5.0以后,没有这个错误了ios

           若是你在使用新浪sdk,使用了libWeiboSDK_X64的库,若是在5.x上运行,也会报这个错,猜想这个版本的库时6.x如下的。换成那个不带_X64的库,没有问题。c++

    1. 在使用百度统计是,若是出现相似错误

      在buildPhases 下添加coreTelephoney.framework便可

      这个问题,花费了我2天的时间才找到,总觉得是自制的静态库的问题。

    2. no provisioning profile at path '/Users/user/Library/MobileDevice/Provisioning Profiles/XXXXX.XXX
       当报这种错误时,工程证书不正确,修改build setting下 的Provisioning Profile为正确的的项目证书便可
    3. malformed or corrupted AST file: iosXXX,相似的错误时,时xcode编译器的问题,清理下/Library/Developer/Xcode/DerivedData下的数据
      便可。
    4.  

      Assertion failure in -[UISectionRowData refreshWithSection:tableView:tableViewRowData:], /SourceCache/UIKit_Sim/UIKit-2903.23/UITableViewRowData.m:578xcode

      libc++abi.dylib: terminate_handler unexpectedly threw an exceptionapp

      这个错误的缘由是在计算tableview的高度是出错,ui

      对现实的图片UIImage计算高度,可是此时image为nil,作了200/image.size.height这个操做atom

      致使height += 200/image.size.height,这个计算后,height为NaN,以后报这个错误,code

       

       

      keychain错误:Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Couldn't add the Keychain Item.'orm

       

       KeyChain内部以kSecAttrAccount 与kSecAttrService做为惟一钥匙串标识,图片

      传送门 http://stackoverflow.com/questions/4891562/ios-keychain-services-only-specific-values-allowed-for-ksecattrgeneric-keyci

相关文章
相关标签/搜索