OpenCV compilation problem

News and discussion about development of the Debian OS itself

OpenCV compilation problem

Postby maikki » 2009-01-06 17:14

Hi folks

I try to build a project that needs to have included openCV header files. These files are store in /usr/include/opencv but the problem is that this direcotry is maybe not in my include directive.

sample of my file:

#include "opencv/cvaux.h"

but the cvaux.h has inside directive '#include <cv.h>' and it makes error that this cant be included.

How can I add /usr/include/opencv direcotry to be searched for including like I do when write '#include <iostream>'

help just to add this direcotry to be enabled for #include directive in c++
Posts: 4
Joined: 2008-10-27 16:23

Postby BioTube » 2009-01-07 00:44

First, you need to change the quotes to brackets.
Code: Select all
#include <opencv/cvaux.h>
Second, you'll need to tell g++ to link against the relevant libraries with the -l command.
Ludwig von Mises wrote:The elite should be supreme by virtue of persuasion, not by the assistance of firing squads.
User avatar
Posts: 7551
Joined: 2007-06-01 04:34

Return to Debian Development

Who is online

Users browsing this forum: No registered users and 1 guest