Undefined symbols for architecture x86_64: "OBJC_CLASS$_xxx", referenced from: objc-class-ref in yyy.o
This generally means, you are calling "xxx" (it may be a framework or class) from the class "yyy". The compiler can not locate the "xxx" so this error occurs.
You need to add the missing files(in this case "xxx") by right click on your project folder in navigator window and tap on "Add files to "YourProjectName"" option.
A popup window will open your project files in Finder. There, you can see the missing files and just add them to your project. Don't forget to check the "Copy items if needed" box. Good luck!!
image.png我的解决办法是在程序中找到XXX文件然后找到对应的framework,添加到工程中,出现这种问题的原因很大可能是第三方库未引入,所以再引入一遍就ok啦!
参考链接:https://stackoverflow.com/questions/18408531/xcode-build-failure-undefined-symbols-for-architecture-x86-64
网友评论