I've searched similar topics but didn't solved my problem. I've uninstalled opencv-3.2.0 from source using:
sudo make uninstall
and I want to install opencv-3.3.1 but before i do that i wanted to make sure the previous version in completely gone. so i ran:
pkg-config --modversion opencv
and it returns
3.2.0
how do i make the system forget about 3.2.0 version, and move on?
pkg-config
uses a bunch of .pc
files to find information about the installed packages. When using pkg-config
, it simply prints section of the relevant file.
These files are usually located in /usr/lib/pkgconfig
or /usr/local/lib/pkgconfig
. Additional paths can be specified using the PKG_CONFIG_PATH
environment variables.
My point is that pkg-config
has no idea about what libraries are installed or not. It simply outputs the content of the .pc
file.
Most likely what happened is that make uninstall
forgot about opencv.pc
.
You can more reliably check if you still have some of OpenCV installed by looking in your system. OpenCV should come with an include directory in /usr/include/opencv
or /usr/local/include/opencv
and some libraries /usr/lib/libopencv_*
or /usr/local/lib/libopencv_*
.