opencv-config1
Script to get information about the installed version of opencv
Usage
opencv-config [--prefix
DIR]
[--version]
[--libs
[<extensions>]]
[{--cflags | --cxxflags}]
Overview
opencv-config is a tool that is used to configure and determine the compiler and linker flags that should be used to compile and link progams, libraries, and plugins that use OpenCV.
Options
-
--cflags -
Print the C compiler flags that are necessary to compile a program or library that uses OpenCV.
-
--cxxflags -
Print the C++ compiler flags that are necessary to compile a program or library that uses OpenCV.
-
--libs [<extensions>] -
Print the linker flags that are necessary to link a program that uses libcv. Optionally, add linker flags for the libhighgui, libcvcam and/or libcvaux OpenCV extensions by appending highgui, cvcam and/or cvaux.
-
--prefix=DIR -
If specified, use PREFIX instead of the installation prefix that libcv was built with when computing the output for the --cflags, --cxxflags and --libs options. This option must be specified before any of the --cflags, --cxxflags and --libs options.
-
--version -
Prints the currently installed version of libcv on standard output.
Examples
- gcc -o main.o $(opencv-config --cflags) -c main.c
-
is how you might use
opencv-configto compile a C source file for an executable program.
- gcc -o my_app $(opencv-config --libs) main.o util.o
-
is how you might use
opencv-configto link compiled objects into an executable program.
Releases
2 releases since Debian 3.1 (Sarge); the text changed 1 time.