This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Linker complains Undefined Symbol

Hi,

I have a c program that looks like bellow. In my main.c file, I have included:
#include "test.h"
main(){ test_init();
}

in my test.h file, I have a declaration
static void test_init();

in my test.c file, I have a definition
void test_init() { return 1;
}

When I do compile, I see:
compiling test.c...
compiling main.c...
linking...
.\out\test.axf: Error: L6218E: Undefined symbol test_init(referred from main.o).

I've both declared and defined the function. But still see this error, any thoughts?