報錯信息:
-- Could not find the required component 'ddynamic_reconfigure'. The following CMake error indicates that you either need to install the package with the same name or change your environment so that it can be found.
CMake Error at /opt/ros/kinetic/share/catkin/cmake/catkinConfig.cmake:83 (find_package):
Could not find a package configuration file provided by
"ddynamic_reconfigure" with any of the following names:
ddynamic_reconfigureConfig.cmake
ddynamic_reconfigure-config.cmake
Add the installation prefix of "ddynamic_reconfigure" to CMAKE_PREFIX_PATH
or set "ddynamic_reconfigure_DIR" to a directory containing one of the
above files. If "ddynamic_reconfigure" provides a separate development
package or SDK, be sure it has been installed.
Call Stack (most recent call first):
realsense/realsense2_camera/CMakeLists.txt:8 (find_package)
-- Configuring incomplete, errors occurred!
See also "/home/bruce/catkin_ws/build/CMakeFiles/CMakeOutput.log".
See also "/home/bruce/catkin_ws/build/CMakeFiles/CMakeError.log".
Makefile:1536: recipe for target 'cmake_check_build_system' failed
make: *** [cmake_check_build_system] Error 1
Invoking "make cmake_check_build_system" failed
解決辦法:
下載ddynamic_reconfigure的package
鏈接https://github.com/pal-robotics/ddynamic_reconfigure/tree/kinetic-devel
解壓到catkin_ws/src空間,再使用catkin_make安裝,這樣在編譯realsense時就可以找到。
至此,問題解決!
參考鏈接:
https://blog.csdn.net/weixin_44580210/article/details/89789416
https://www.cnblogs.com/LoveBuzz/p/11568628.html