Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

you need backticks (`) around the pkg-config parts, not single quotes (').

the idea behind that is to run e.g. pkg-config opencv --cflags from the shell, and replace that with the outcome of it.

so, your cmdline should look like this:

g++ `pkg-config opencv --cflags` hello_opencv.cpp -o hello_opencv `pkg-config opencv --libs`

    ^- here         and  here -^