I assume it is if I have not asked for a static library (I didn’t).
Edit: Yes I have compiled opencv with TBB option.
But this creates a small problem in deciding what libraries to add in a Makefile aimed for distributing this code to various systems with or without tbb. Shouldn’t perhaps be an entry to pkgconfig/opencv.pc so that the distributor just enquires said file on the various systems to have his code distributed?
Shouldn’t perhaps the key “Libs” in said file contain all additional library dependencies up to -ltbb?
I am not sure what usual practice is. In my system some pc files contain -lpthread for example.
Of course there’s the key Libs.private which contains -lm -lpthread etc. So perhaps -ltbb should have been added there if indeed opencv compilation was with TBB.
It’s the OpenCV library which depends on TBB, your executable doesn’t need to link to it. So if you don’t use TBB explicitly in your code, you don’t need to add TBB dependencies to your Makefile/CMakeLists/etc.
However if you redistribute the OpenCV with your code, you have to include the libraries OpenCV was linked to.
solved the problem. (dirs there contain libtbb and libopencv_*)
Regarding pkg-config: one of its roles is to tell me what libraries to
use, library paths, include paths etc. when compiling code I distribute
to other computers which have an OpenCV not necessarily configured as
mine. I don’t know how to use cmake to enquire these settings. And
frankly I try to keep as far away from cmake as possible, though that’s
personal taste.
So, what’s the best way to enquire these settings with cmake in a
foreign system?