Xcode 6.1 上 x86_64 架构的未定义符号 [英] Undefined symbols for architecture x86_64 on Xcode 6.1

查看:26
本文介绍了Xcode 6.1 上 x86_64 架构的未定义符号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Xcode 在编译时突然向我抛出了这个错误:

All of a sudden Xcode threw me this error at compilation time:

Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_Format", referenced from:
 objc-class-ref in WOExerciseListViewController.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

经过一些研究,我可能了解到我使用的库与 64 位版本不兼容.但这很奇怪,因为我已经使用相同的库至少一个星期了,在那段时间没有遇到任何编译问题.这两个库只是由一堆类组成,当我从我的项目中删除它们时,我遇到了同样的问题.由于我自己从未创建过库,因此我不知道如何找到我正在使用的库是否与 64 位 (?)我还尝试对目标面板下的架构进行以下更改:

After doing some research, I may understand that a library I'm using is not compatible with 64 bit version. But this is very strange since I've been working with the same libraries for at least a week without having a single compilation problem during that time. The two libraries are just composed of a bunch of classes, and when I removed them from my project I got the same issue. Since I have never created libraries myself, I have no idea how I can find wether the ones I'm using are compatible with 64 bit (?) I also tried the following changes for architectures under the target panel :

  • 在架构中添加了 $(ARCHS_STANDARD_INCLUDING_64_BIT)
  • 仅构建活动架构 -> 设置为NO"
  • 对于有效架构" -> 设置为 arm64、armv7 和 armv7s
  • 删除了 DerivedData 文件夹及其内容,重新清理和构建

但是这些更改都不起作用.请问有人有这方面的线索吗?谢谢

But none of these changes work. Please, does someone have a clue on this? Thanks

推荐答案

显然,您的格式"类与问题有关.检查你对这个类的声明,特别是如果你在另一个类中做了它,你可能忘记了@implementation 或类似的东西.

Apparently, your class "Format" is involved in the problem. Check your declaration of this class, especially if you did it inside another class you probably forgot the @implementation or something similar.

这篇关于Xcode 6.1 上 x86_64 架构的未定义符号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆