Undefined symbols for architecture armv7: "_OBJC_METACLASS_$_ _OBJC_CLASS_$_ ld: symbol(s) not found

Undefined symbols for architecture armv7:
  "_OBJC_METACLASS_$_MWPhotoBrowser", referenced from:
      _OBJC_METACLASS_$ _** in **.o
      _OBJC_METACLASS_$_** in **.o
  "_OBJC_CLASS_$_MWPhotoBrowser", referenced from:
      _OBJC_CLASS_$_** in **.o
      _OBJC_CLASS_$_** in **.o
  "_OBJC_CLASS_$_MWPhoto", referenced from:
      objc-class-ref in **.o
      objc-class-ref in **.o
  "_OBJC_CLASS_$_MBProgressHUD", referenced from:
      objc-class-ref in BaseViewController.o
      objc-class-ref in MBProgressHUD+CustomHUD.o
      l_OBJC_$_CATEGORY_MBProgressHUD_$_CustomHUD in MBProgressHUD+CustomHUD.o
      objc-class-ref in **.o
      objc-class-ref in **.o
  "_OBJC_CLASS_$_Reachability", referenced from:
      objc-class-ref in Reachability+Ext.o
      l_OBJC_$_CATEGORY_Reachability_$_Ext in Reachability+Ext.o
      objc-class-ref in AppDelegate.o
      objc-class-ref in **.o
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)測試

 

一個測試無缺的項目我複製出來放到一個新的文件夾中,而後更新了下cocoapods 就出現這個問題.ui

路徑沒有設置絕對路徑,庫都是在文件夾中.檢查了沒有重複文件,重複導入.能夠說沒改任何設置.可是就是這麼一複製,就報錯了.spa

解決方案:日誌

Xcode直接clean應該是沒有刪掉項目索引之類的,我直接找到DerivedData,把裏面全部文件夾都給清理了,再編譯就行了
PS:
DerivedData
影響:可從新生成;會刪除build生成的項目索引、build輸出以及日誌。從新打開項目時會從新生成,大的項目會耗費一些時間。

路徑:~/Library/Developer/Xcode/DerivedData code

相關文章
相關標籤/搜索