iPhone:重复符号错误? [英] iPhone: Duplicate Symbol Error?
问题描述
当我按build + debug时出现此错误:
I got this error when i press build+debug:
ld: duplicate symbol .objc_class_name_BlogTableItemCell in /Users/fabian/Development/Workspaces/iphone_experiments/xcode_build_output/MausLog.build/Debug-iphonesimulator/MausLog.build/Objects-normal/i386/BlogTableItemCell-3733583914888A7B.o and /Users/fabian/Development/Workspaces/iphone_experiments/xcode_build_output/MausLog.build/Debug-iphonesimulator/MausLog.build/Objects-normal/i386/BlogTableItemCell-3733583914888A7B.o
collect2: ld returned 1 exit status
Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.2 failed with exit code 1
我不知道从哪里开始?
问题是什么?
推荐答案
看来你正在编译同一个BlogTableItemCell类二在代码的不同位置的时间。在下列情况下可能会发生这种情况。
It seems that you are compiling the same BlogTableItemCell class two times in different places of your code. This may happen in the following cases.
-
您已将同一类
实现放入两个不同的$ b $中b档;
You have put the same class implementation into two different files;
你实际上只有一个这个类的
实现,但是
你也在你的项目中链接一个框架
或包含
名称与您的名称完全相同的类的库。
You actually have just one implementation of this class, however you are also linking in your project a framework or library containing a class whose name is exactly the same of yours.
尝试在整体中查找预测你的课程并确保你的项目中只有一个副本可用。
Try finding in the whole project your class and make sure only one copy is available within your project.
这篇关于iPhone:重复符号错误?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!