Why don’t you use pkg-config to your favor?
g++ hello.c -o hello `pkg-config --cflags --libs opencv`
More Related Contents:
- openCV program compile error “libopencv_core.so.2.4: cannot open shared object file: No such file or directory” in ubuntu 12.04
- OpenCV 2.3 Compiling Issue – Undefined Refence – Ubuntu 11.10
- opencv library video play [closed]
- Transpose a 1D byte-wise array to a 2D array
- Extracting text OpenCV
- OpenCV with Network Cameras
- Convert Mat to Array/Vector in OpenCV
- How to efficiently display OpenCV video in Qt?
- Get 3D coordinates from 2D image pixel if extrinsic and intrinsic parameters are known
- Fill the holes in OpenCV [duplicate]
- Blending does not remove seams in OpenCV
- connected components in OpenCV
- Automatic perspective correction OpenCV
- OpenCv 2.3 C – How to isolate object inside image
- Square detection doesn’t find squares
- Convert RGB to Black & White in OpenCV
- Easiest way to rotate by 90 degrees an image using OpenCV?
- How to correctly use cv::triangulatePoints()
- Converting YUV into BGR or RGB in OpenCV
- OpenCV threshold with mask
- How do I install the OpenSSL libraries on Ubuntu?
- trying to use imread() and imshow() raises OpenCV Error: Assertion failed (size.width>0 && size.height>0)
- Why can’t I open avi video in openCV?
- using static libraries instead of dynamic libraries in opencv
- Convexity defects C++ OpenCv
- Aruco markers with openCv, get the 3d corner coordinates?
- Get a single line representation for multiple close by lines clustered together in opencv
- OpenCV GTK+2.x error – “Unspecified error (The function is not implemented…)”
- FileStorage for OpenCV Python API
- Displacement Map Filter in OpenCV