Could not find a package configuration file provided by moveit
时间: 2023-10-21 13:21:32 浏览: 96
引用和中提到了找不到"moveit_core"和"moveit_commander"的包配置文件的错误。这通常是由于没有正确安装相关依赖包或者没有正确设置相应的环境变量所致。为了解决这个问题,你可以按照以下步骤进行操作:
1. 确保你已经正确安装了"moveit_core"和"moveit_commander"的相关依赖包。你可以使用以下命令进行安装:
sudo apt-get install ros-melodic-moveit-core
sudo apt-get install ros-melodic-moveit-commander
2. 如果你已经安装了相关依赖包但仍然出现错误,你可以尝试设置相应的环境变量。你可以在CMakeLists.txt文件中添加以下内容:
set(ENV{moveit_core_DIR} /opt/ros/melodic/share/moveit_core/cmake)
set(ENV{moveit_commander_DIR} /opt/ros/melodic/share/moveit_commander/cmake)
3. 确保你的工作空间已经重新编译,你可以使用以下命令进行编译:
catkin_make
或者
catkin build
通过以上步骤,你应该可以解决"moveit_core"和"moveit_commander"包配置文件找不到的问题。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* *3* [Could not find a package configuration file provided by “moveit_core“ with any ...](https://blog.csdn.net/m0_56451176/article/details/126368991)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
- *2* [Could not find a package configuration file provided by “moveit_commander](https://blog.csdn.net/ben_xiao_hai_123/article/details/122103534)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文