Hi all,

To begin, I'm not certain this is the proper place to start this question, but I believe this to be a linux-linker related error rather than a code based one. I've also searched far and wide for a solution online, but others have solved the problem simply include -lblob in the build which I have already done without success.

I'm using cvblobslib with openCV, and as per their instructions I've compiled their code to create libblob.a. I've copied this into /usr/local/lib and executed 'sudo ldconfig'. This should have registered the library.

Here are the relevent snippets from the make file:

LIB=-lblob -L/home/tc/opencv/release/lib -lopencv_core -lopencv_imgproc -lopencv_highgui
INC=-I/home/tc/opencv/release/include -I/home/tc/cvblobslib
CFLAGS=-Wall -Wno-unknown-pragmas
OBJECTS = (long list of .o files)

robot.o: $(OBJECTS)
    $(CC) $(INC) $(LIB) $(CFLAGS) $(OBJECTS) -o robot
(rest of directions to build individual objects)

The errors are:
undefined reference to 'CBlobResult::GetBlob(int)'
repeated for other functions inside cvblobslib.

Any advice as to where to proceed from here? How can I find out more about what the linker is doing? Did it successfully registered libblob.a, is it trying to use libblob.a in an unusual way?

Thanks in advance.

Edited by sblass92

5 Years
Discussion Span
Last Post by sblass92

Fixed the problem with an inelegant solution. I added the .cpp files to my own build directives instead of using the libblob.a provided.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.