This is one of those problems that is a bit vague and so difficult to pinpoint the cause. I'll try to keep it simple.
I've created a C class with a header like this:
C_Class.h
void do_something(void);
C_Class.c
void do_something(void)
{
}
Then I have a .mm file that was working perfectly fine until within one of its functions I added my C sub_routine which I created earlier:
#import "C_Class.h" // included in the .h file
// then in the .mm file
- (void)working_function{
.... some working code ......
do_something();
}
The problem is I get this error:
-[MyDotMMfile working_function] in MyDotMMfile.o
Symbol(s) not found
Collect2:ld returned 1 exit status
This questioned has been answered elsewhere, but the response doesn't seem relevant to my situation. I'm working in XCode and have stopped running my app, rebuilt it and still get the same error. Since I'm new to programming I have a feeling it has to do with how I'm calling my C functions.
Any help?
EDIT 1
If anyone is feeling so altruistic they may download the actually files here.