Hello,
I've built a static library, to be linked in my iPhone apps. This library uses some global variables and functions, like in C. My problem is, when using for example:
extern
void do_stuff (const int a)
{
return a*a;
}
extern const int a_variable;
extern const int an_array[DEFINED_VALUE];
When I use this function, or access these variables, anywhere in my code, the compiler tells me
"_do_stuff" referenced from: -[Object testMethod] in tests.o
"_a_variable" referenced from: -[Object testMethod] in tests.o
"_an_array" referenced from: -[Object testMethod] in tests.o
Symbol(s) not found Collect2: Id returned 1 exit status
Has anyone ever faced this problem before? I know I'm doing something stupid, I'm missing some key Objective-C or C concept, but I can't really see what. So I was hoping someone could help me. Thanks in advance.