CMake Warning at /opt/projects/tensorrt-alpha/cmake/common-x86.cmake:90 (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. Call Stack (most recent call first): CMakeLists.txt:18 (include)
时间: 2023-11-30 18:04:28 浏览: 236
这是一个CMake的警告提示,意思是在CMAKE_MODULE_PATH中没有提供"Findopencv.cmake"文件,因此CMake无法找到"opencv"的包配置文件。解决方法是将"opencv"的安装路径添加到CMAKE_PREFIX_PATH中,或者设置"opencv_DIR"为包含"opencvConfig.cmake"或"opencv-config.cmake"文件的目录。如果"opencv"提供了单独的开发包或SDK,请确保已经安装。
相关问题
CMake Error at /opt/ros/melodic/share/catkin/cmake/catkin_package.cmake:116 (message)
引用<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [CMake Error at /opt/ros/melodic/share/catkin/cmake/catkin_package.cmake:116 (message):catkin_package](https://blog.csdn.net/qq_45950023/article/details/121816434)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"]
- *2* *3* [执行caktin_make时候,出现错误:CMake Error at /opt/ros/melodic/share/catkin/cmake/catkin_package....](https://blog.csdn.net/qq_33876441/article/details/115770990)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT0_1"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
CMake Error at /opt/ros/noetic/share/catkin/cmake/catkin_package.cmake:224 (message):
根据提供的引用内容,CMake在执行过程中遇到了一个错误。错误信息显示在执行`make cmake_check_build_system`命令时失败,具体错误原因是在`/opt/ros/noetic/share/catkin/cmake/catkin_package.cmake`文件的第224行发生了错误。
根据错误信息,可能的原因是在`/opt/ros/noetic/share/catkin/cmake/catkin_package.cmake`文件中找不到所需的包配置文件。这个包配置文件的名称应该是"geographic_msgsConfig.cmake"或"geographic_msgs-config.cmake"。
为了解决这个问题,你可以尝试以下几个步骤:
1. 确保你已经正确安装了"geographic_msgs"包。你可以使用以下命令来安装它:
```
sudo apt-get install ros-noetic-geographic-msgs
```
2. 如果你已经安装了"geographic_msgs"包,但仍然遇到这个错误,那么可能是因为包的配置文件没有正确安装。你可以尝试重新安装这个包,使用以下命令:
```
sudo apt-get --reinstall install ros-noetic-geographic-msgs
```
3. 如果以上步骤都没有解决问题,那么可能是因为你的CMake配置文件中没有正确设置"geographic_msgs"包的路径。你可以检查你的CMakeLists.txt文件,确保在其中正确设置了"geographic_msgs"包的路径。
请注意,以上步骤是基于提供的错误信息和常见的解决方法。如果问题仍然存在,可能需要进一步调查和排除其他可能的原因。