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

Project ‘cv_bridge‘ specifies ‘/usr/include/opencv‘ as an include dir, which is not found #389

Open
cjl19721 opened this issue May 9, 2021 · 2 comments

Comments

@cjl19721
Copy link

cjl19721 commented May 9, 2021

When I compile iai_Kinect v2, this error appears.The following is the error log.

CMake Error at /opt/ros/melodic/share/cv_bridge/cmake/cv_bridgeConfig.cmake:113 (message):
Project 'cv_bridge' specifies '/usr/include/opencv' as an include dir,
which is not found. It does neither exist as an absolute directory nor in
'${{prefix}}//usr/include/opencv'. Check the issue tracker
'https://github.com/ros-perception/vision_opencv/issues' and consider
creating a ticket if the problem has not been reported yet.
Call Stack (most recent call first):
/opt/ros/melodic/share/catkin/cmake/catkinConfig.cmake:76 (find_package)
iai_kinect2/kinect2_bridge/CMakeLists.txt:24 (find_package)

-- Configuring incomplete, errors occurred!
See also "/home/q/test_ws/build/CMakeFiles/CMakeOutput.log".
See also "/home/q/test_ws/build/CMakeFiles/CMakeError.log".
Makefile:320: recipe for target 'cmake_check_build_system' failed
make: *** [cmake_check_build_system] Error 1
Invoking "make cmake_check_build_system" failed

@sienuc
Copy link

sienuc commented May 14, 2021

cd /usr/include/
sudo ln -s opencv4/ opencv (replace "4" with your version)

Had the same issue, the above fixed my compiler needs.
Be ware of compatibility with yours, you may need to delete the link afterwards to not break other cmake runs that use/expect other versions of opencv.

"Problem" is the static / hardcoded libraries in cv_bridge cmake file.

@cjl19721
Copy link
Author

cjl19721 commented May 16, 2021 via email

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