Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FindOpenCV.cmake not found with cmake . #2

Open
richieej opened this issue Jan 13, 2024 · 1 comment
Open

FindOpenCV.cmake not found with cmake . #2

richieej opened this issue Jan 13, 2024 · 1 comment

Comments

@richieej
Copy link

Hi there,

I am trying to build shotdetection on my local machine. I am trying to run cmake . and I got this error:
CMake Error at CMakeLists.txt:8 (find_package):
By not providing "FindOpenCV.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "OpenCV", but
CMake did not find one.

Could not find a package configuration file provided by "OpenCV" with any
of the following names:

OpenCVConfig.cmake
opencv-config.cmake

Add the installation prefix of "OpenCV" to CMAKE_PREFIX_PATH or set
"OpenCV_DIR" to a directory containing one of the above files. If "OpenCV"
provides a separate development package or SDK, be sure it has been
installed.

I then copied a FindOpenCV.cmake file from https://github.com/opencv/opencv/blob/2f4e38c8313ff313de7c41141d56d945d91f47cf/cmake/OpenCVConfig.cmake
upon following instructions from
https://stackoverflow.com/questions/8711109/could-not-find-module-findopencv-cmake-error-in-configuration-process

This gives me this error:
CMake Warning at CMakeFiles/FindOpenCV.cmake:166 (message):
Found OpenCV Windows Pack but it has no binaries compatible with your
configuration.

You should manually point CMake variable OpenCV_DIR to your build of OpenCV
library.
Call Stack (most recent call first):
CMakeLists.txt:9 (find_package)

Could you please advise what to do?

Thank you.

@makarandtapaswi
Copy link
Collaborator

You can use ccmake (a nicer interface to cmake) and add the path to the OpenCV installation please. I think you need to point to the share directory where all libraries, etc. will be stored.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants