ROS Melodic笔记:catkin_make报错Invoking "make cmake_check_build_system" failed

catkin_make报错Invoking "make cmake_check_build_system" failed

按照官网的要求安装好了ROS Melodic(Ubuntu18.04.5),但是catkin_make命令一直报错。

image.png

网上虽然有很多catkin_make报错的解决办法,但是没有出现我这个报错信息的。

Invoking "make cmake_check_build_system" failed

还是需要从具体报错信息里面看,

CMake Error at /opt/ros/melodic/share/catkin/cmake/catkinConfig.cmake:83 (find_package):
  Could not find a package configuration file provided by "rospy" with any of
  the following names:

    rospyConfig.cmake
    rospy-config.cmake

  Add the installation prefix of "rospy" to CMAKE_PREFIX_PATH or set
  "rospy_DIR" to a directory containing one of the above files.  If "rospy"
  provides a separate development package or SDK, be sure it has been
  installed.

缺少rospy软件包。
网上有大佬针对提示缺少gazebo_ros_control功能包给出的解决方案是

sudo apt-get install ros-kinetic-gazebo-ros-control

依样画葫芦写了我的安装命令

sudo apt-get install ros-melodic-rospy
image.png

之后再运行catkin_make就没有报错信息了。

image.png

网上搜到的catkin_make报错类型五花八门,我也不清楚为什么同样的安装方式会出现不同软件包的缺失。自己解决问题的经验是要多看看自己电脑的详细报错信息,找到准确的缺失内容以后再去找方法。


参考:
https://blog.csdn.net/weixin_43262513/article/details/88087849?utm_medium=distribute.pc_relevant_bbs_down.none-task-blog-baidujs-2.nonecase&depth_1-utm_source=distribute.pc_relevant_bbs_down.none-task-blog-baidujs-2.nonecase

你可能感兴趣的:(ROS Melodic笔记:catkin_make报错Invoking "make cmake_check_build_system" failed)