Compile error I can't figure out

Member
Posts: 215
Joined: 2008.06
Post: #1
Maybe it's just because it's late, but I keep getting the following error a LOT:

".objc_class_name_<CLASSNAME>", referenced from:
literal-pointer@__OBJC@__cls_refs@<CLASSNAME> in <CONTAININGFILE>.o
ld: symbol(s) not found
collect2: ld returned 1 exit status

What is going on? Thanks.

Mac users swear by their computers, PC users swear at their computers. ~Unknown

iSayz
Quote this message in a reply
Member
Posts: 254
Joined: 2005.10
Post: #2
Maybe you forgot to import the header? (#import CLASS_NAME.h)
Quote this message in a reply
Member
Posts: 215
Joined: 2008.06
Post: #3
Blacktiger Wrote:Maybe you forgot to import the header? (#import CLASS_NAME.h)

That's not the problem. Thanks though.

Mac users swear by their computers, PC users swear at their computers. ~Unknown

iSayz
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #4
You forgot to compile/link the source file/library/framework that contains the named class.
Quote this message in a reply
Member
Posts: 215
Joined: 2008.06
Post: #5
OneSadCookie Wrote:You forgot to compile/link the source file/library/framework that contains the named class.

...Most of the classes I'm having issues with have been dragged in from other projects. I did the "Copy Files Into Project Folder" option when I did that though. How do I fix it?

Mac users swear by their computers, PC users swear at their computers. ~Unknown

iSayz
Quote this message in a reply
Member
Posts: 254
Joined: 2005.10
Post: #6
In Xcode, expand 'Targets', then the target you are building. Look in each of the sections to see if everything looks correct. (Specifically, .m files should be in compile sources) If something is missing you can just drag it in to add it to your build.
Quote this message in a reply
Post Reply 

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  'Unidentified error' error in Xcode scgames 2 3,599 Jun 10, 2006 01:38 AM
Last Post: scgames