librealsense2 camera.so: undefined symbol:ZN2cV3MatC1EV解决笔记记录

ROS使用手动编译的Opencv4.5.4在编译工作空间的时候

cd ~/catkin_ws
catkin_make 
catkin_make install

先参考的这个兄弟的办法虽然没解决但是提供了大方向感谢; 

realsenseD400系列相机报错:undefined symbol: _ZN2cv3MatC1EiiiRKNS_7Scalar_IdEE解决方案 

后解决办法参考

sudo apt install ros-noetic-ddynamic-reconfigure

No GPU usage on jetson xavier NX · Issue #2326 · IntelRealSense/realsense-ros · GitHub

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):   realsense-ros/realsense2_camera/CMakeLists.txt:13 (find_package) 

 

librealsense2 camera.so: undefined symbol:ZN2cV3MatC1EV解决笔记记录_第1张图片 

 librealsense2 camera.so: undefined symbol:ZN2cV3MatC1EV解决笔记记录_第2张图片

 

 

Camilochiang Maybe I found a solution try adding/modifying to CMakeLists in realsense2_camera. Now im testing this solution but it looks promising. (even work with -DFORCE_RSUSB_BACKEND:=false):

1 find_package( OpenCV REQUIRED )
2  include_directories(
include
${realsense2_INCLUDE_DIR}
${catkin_INCLUDE_DIRS}
${OpenCV_INCLUDE_DIRS}
)
3 target_link_libraries(${PROJECT_NAME}
${realsense2_LIBRARY}
${catkin_LIBRARIES}
${CMAKE_THREAD_LIBS_INIT}
${OpenCV_LIBRARIES}
)

 然后跳回catkin_make install再次安装,截至到目前,安装完成,测试一下: 

roslaunch realsense2_camera rs_rgbd.launch

 

 

你可能感兴趣的:(opencv,人工智能,计算机视觉)