I have a .o file lib.o that was already compiled and contains functions f and g.
I have a .cpp file main.cpp that uses functions f and g.
How do I properly use f and g in main.cpp and how do I compile main.cpp with lib.o?
I tried g++ main.cpp lib.o -o main -lirc
but I get the error:
main.cpp:(.text+0x18c): undefined reference to `f(unsigned short)'
main.cpp:(.text+0x1a8): undefined reference to `g(unsigned short)'