user573014
user573014

Reputation: 725

OpenCV installlation error ubuntu

I am trying to install opencv2.2 and after I compile with make command , it build the libraries up to 80% but then fail and give me this error -->

../../lib/libopencv_highgui.so.2.2.0: undefined reference to `cvCreateCameraCapture_V4L(int)'
collect2: ld returned 1 exit status
make[2]: *** [bin/opencv_createsamples] Error 1
make[1]: *** [modules/haartraining/CMakeFiles/opencv_createsamples.dir/all] Error 2
make: *** [all] Error 2

Upvotes: 2

Views: 2897

Answers (2)

sarnold
sarnold

Reputation: 104050

The missing cvconfig.h header sounds like a show-stopper; if you absolutely must continue building from source, you should fix that problem first. (Well, there might be an even earlier problem, but missing a header file with such an important-sounding name is likely going to prevent a lot from working.)

But I'm curious why you're not using the standard Ubuntu OpenCV packages, which are already built and have explicit dependencies upon important packages.

If you run sudo apt-get install libcv2.1 libcv-dev libcvaux2.1 libcvaux-dev libhighgui2.1 libhighgui-dev opencv-doc, you'll get the libraries, headers, and documentation, installed without any effort to compile the libraries first. Add python-opencv to that command if you also want the Python bindings.

Upvotes: 1

jlengrand
jlengrand

Reputation: 12807

Check about your V4l/v4l2 drivers, there were problems on these some time ago. What do your configure report says? Copy/paste the message you got after you do the ./configure

Upvotes: 0

Related Questions