ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

use custom built opencv along with cv_bridge

asked 2014-06-18 04:30:02 -0500

K Chen gravatar image

After updating to Hydro, the method mentioned in this answer does not work anymore, where I have to depend on cv_bridge to transfer sensor_msgs::Image to cv::Mat. The cmake will strike a warning:

  Cannot generate a safe runtime search path for target my_custom_node
  because there is a cycle in the constraint graph:
    dir 0 is [/usr/local/lib]
      dir 1 must precede it due to runtime library []
    dir 1 is [/opt/ros/hydro/lib]
      dir 0 must precede it due to runtime library []

And the built binary is indeed linking the /opt/ros/hydro/lib/ (checked with ldd).

So what is currently the right way to use custom built opencv, while I have dependency like cv_bride which depends on the opencv2 package?

Thanks for any suggestions.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2014-06-19 03:17:11 -0500

130s gravatar image

Did you try downloading cv_bridge source, modify package.xml and CMakeLists.txt to replace dependency with libopencv*.so?

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2014-06-18 04:30:02 -0500

Seen: 699 times

Last updated: Jun 18 '14