Undefined reference error refers to missing declaration or the definition or both?
Compiler: GCC on Linux
Undefined reference error refers to missing declaration or the definition or both?
Compiler: GCC on Linux
While it is technically compiler specific, "undefined reference" almost always means - as the error message states - that the definition is missing. I don't know of any compiler that would complain of an "undefined reference" when an unDECLARED symbol is being referenced.
i had the same problem using the library with Qt.
the solution is to specify the path which leads to the -lblob
file in the .pro file:
LIBS += -L/user/local/lib \
-lblob
Usualy (if not always?) it's a linker error and it means missing definition. Compilation errors for missing declarations are similar to: "XXX was not declared in this scope."