鱼香ROS社区
    • 版块
    • 最新
    • 未解决
    • 已解决
    • 群组
    • 注册
    • 登录
    紧急通知:禁止一切关于政治&VPN翻墙等话题,发现相关帖子会立马删除封号
    提问前必看的发帖注意事项: 社区问答规则(小鱼个人)更新 | 高质量帖子发布指南

    colcon build --packages-up-to fishbot_navigation2 失败

    已定时 已固定 已锁定 已移动
    ROS 2相关问题
    ros2 humble nav2教程中遇到的问题
    1
    1
    277
    正在加载更多帖子
    • 从旧到新
    • 从新到旧
    • 最多赞同
    回复
    • 在新帖中回复
    登录后回复
    此主题已被删除。只有拥有主题管理权限的用户可以查看。
    • 杜守钰杜
      杜守钰
      最后由 杜守钰 编辑

      --- stderr: nav2_velocity_smoother
      CMake Error at /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_cmake_gtest-extras.cmake:85 (add_subdirectory):
      add_subdirectory given source
      "/home/shouyu/ros2_humble/install/gtest_vendor/src/gtest_vendor" which is
      not an existing directory.
      Call Stack (most recent call first):
      /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest_executable.cmake:35 (_ament_cmake_gtest_find_gtest)
      /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest.cmake:68 (ament_add_gtest_executable)
      test/CMakeLists.txt:2 (ament_add_gtest)

      CMake Error at /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_cmake_gtest-extras.cmake:89 (set_target_properties):
      set_target_properties Can not find target to add properties to: gtest
      Call Stack (most recent call first):
      /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest_executable.cmake:35 (_ament_cmake_gtest_find_gtest)
      /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest.cmake:68 (ament_add_gtest_executable)
      test/CMakeLists.txt:2 (ament_add_gtest)

      
      CMake Error at /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_cmake_gtest-extras.cmake:91 (target_compile_options):
        Cannot specify compile options for target "gtest" which is not built by
        this project.
      Call Stack (most recent call first):
        /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest_executable.cmake:35 (_ament_cmake_gtest_find_gtest)
        /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest.cmake:68 (ament_add_gtest_executable)
        test/CMakeLists.txt:2 (ament_add_gtest)
      
      
      CMake Error at /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_cmake_gtest-extras.cmake:93 (target_include_directories):
        Cannot specify include directories for target "gtest" which is not built by
        this project.
      Call Stack (most recent call first):
        /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest_executable.cmake:35 (_ament_cmake_gtest_find_gtest)
        /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest.cmake:68 (ament_add_gtest_executable)
        test/CMakeLists.txt:2 (ament_add_gtest)
      
      
      CMake Error at /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_cmake_gtest-extras.cmake:94 (target_include_directories):
        Cannot specify include directories for target "gtest_main" which is not
        built by this project.
      Call Stack (most recent call first):
        /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest_executable.cmake:35 (_ament_cmake_gtest_find_gtest)
        /opt/ros/humble/share/ament_cmake_gtest/cmake/ament_add_gtest.cmake:68 (ament_add_gtest_executable)
        test/CMakeLists.txt:2 (ament_add_gtest)
      

      以上是我执行
      colcon build --packages-up-to fishbot_navigation2
      的报错。 有没有大佬能帮我看看为什麽?

      已经尝试的步骤

      1. sudo apt install ros-humble-gtest-vendor
      1 条回复 最后回复 回复 引用 0
      • 第一个帖子
        最后一个帖子
      皖ICP备16016415号-7
      Powered by NodeBB | 鱼香ROS