# cannot find opencv modules for cmake v3.28

**URL:** https://discourse.cmake.org/t/cannot-find-opencv-modules-for-cmake-v3-28/9555
**Category:** Usage
**Tags:** os:windows
**Created:** [December 5, 2023, 1:10am UTC](https://discourse.cmake.org/t/cannot-find-opencv-modules-for-cmake-v3-28/9555 "2023-12-05T01:10:26Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Sea\_Sea](https://discourse.cmake.org/user_avatar/discourse.cmake.org/sea_sea/32/4025_2.png) [@Sea\_Sea](https://discourse.cmake.org/u/Sea_Sea)
#### Post date: [December 5, 2023, 1:10am UTC](https://discourse.cmake.org/t/cannot-find-opencv-modules-for-cmake-v3-28/9555/1 "2023-12-05T01:10:26Z")

</div>

In the lastest cmake-modules, I cannt find the opencv.  
I remember it had been exist.

[https://cmake.org/cmake/help/v3.28/manual/cmake-modules.7.html](https://cmake.org/cmake/help/v3.28/manual/cmake-modules.7.html)

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.cmake.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.cmake.org/u/ben.boeckel)
#### Post date: [December 6, 2023, 12:55pm UTC](https://discourse.cmake.org/t/cannot-find-opencv-modules-for-cmake-v3-28/9555/2 "2023-12-06T12:55:02Z")

</div>

OpenCV is now provided by a config file installed by OpenCV’s installation itself. CMake’s `--debug-find` flag can be used to get more information when configuring. If things work with 3.27 and break with 3.28, that is another issue that would need to be investigated and details on your setup would be appreciated.

The easiest thing to do to try and make this work is to install OpenCV and then configure with `-DCMAKE_PREFIX_PATH=/path/to/opencv/install/prefix`.

---

<div class="post-metadata">

### Author: ![Sea\_Sea](https://discourse.cmake.org/user_avatar/discourse.cmake.org/sea_sea/32/4025_2.png) [@Sea\_Sea](https://discourse.cmake.org/u/Sea_Sea)
#### Post date: [December 7, 2023, 1:10am UTC](https://discourse.cmake.org/t/cannot-find-opencv-modules-for-cmake-v3-28/9555/3 "2023-12-07T01:10:01Z")

</div>

I can use the `find_package(OpenCV REQUIRED)` on windows system.  
I want to read the cmake document about opencv, but I cannot find the document on this lik.

[https://cmake.org/cmake/help/v3.28/manual/cmake-modules.7.html](https://cmake.org/cmake/help/v3.28/manual/cmake-modules.7.html)

---

<div class="post-metadata">

### Author: ![Angew](https://discourse.cmake.org/user_avatar/discourse.cmake.org/angew/32/229_2.png) [@Angew](https://discourse.cmake.org/u/Angew)
#### Post date: [December 8, 2023, 10:29am UTC](https://discourse.cmake.org/t/cannot-find-opencv-modules-for-cmake-v3-28/9555/4 "2023-12-08T10:29:26Z")

</div>

As Ben wrote, the file processed by `find_package(OpenCV)` (namely `OpenCVConfig.cmake` or `opencv-config.cmake`) is part of OpenCV, not of CMake. So you’ll have to look for it there. It may be part of its source, or it may be generated as part of OpenCV’s build or installation.
