954,529 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Objective c undefined reference to objc class

i get an undefined reference to _objc_class_name_greeter error when I compile
When I remove the line
Greeter * Hi=[[greeter alloc] init];
it compiles and all but one option works any idea what's wrong with that line
Also the error is at .data+0xa4 and correction it actually happens during linking ?
Take note that I wrote this on my iPod touch and auto correct is on all the time

Celtrix
Junior Poster in Training
67 posts since Jan 2011
Reputation Points: 8
Solved Threads: 4
 

I have solved the general problem but not my specific problem I'm compiling on Linux so I have to invoke a few extra gcc options
Ex
gcc -o main main.m -lobjc -i /usr/include -L(I'll post this in a little while) -lgnu-base
Ill finish the whole thing in a sec

Celtrix
Junior Poster in Training
67 posts since Jan 2011
Reputation Points: 8
Solved Threads: 4
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: