micro-ROS / micro-ROS/micro_ros_setup

micro_ros_agent installation issue on ROS 2 Humble Ubuntu 22.04

Open
#764 12 comments 4 reactions 0 assignees View on GitHub
Dominant language
Shell
Stars
509
Forks
183
Avg merge
22h 26m
Merged PRs (30d)
7

Description

## Issue template

- Hardware description: PC, Ubuntu 22.04
- RTOS: Ardupilot SITL
- Installation type: micro_ros_setup
- Version or commit hash: humble

#### Steps to reproduce the issue

Follow [First micro-ROS Application on Linux](https://micro.ros.org/docs/tutorials/core/first_application_linux/). When creating and building the micro-ROS agent

```
ros2 run micro_ros_setup create_agent_ws.sh
ros2 run micro_ros_setup build_agent.sh
```
I run into the following error:
```
stderr: micro_ros_agent
CMake Error at /opt/ros/humble/share/fastrtps/cmake/fastrtps-dynamic-targets.cmake:37 (message):
Some (but not all) targets in this export set were already defined.

Targets Defined: eProsima_atomic

Targets not yet defined: fastrtps

Call Stack (most recent call first):
/opt/ros/humble/share/fastrtps/cmake/fastrtps-config.cmake:60 (include)
CMakeLists.txt:37 (find_package)
```

#### Expected behavior

micro-ROS agent installation works as expected and I can use it for working with Ardupilot.

#### Actual behavior

```
stderr: micro_ros_agent
CMake Error at /opt/ros/humble/share/fastrtps/cmake/fastrtps-dynamic-targets.cmake:37 (message):
Some (but not all) targets in this export set were already defined.

Targets Defined: eProsima_atomic

Targets not yet defined: fastrtps

Call Stack (most recent call first):
/opt/ros/humble/share/fastrtps/cmake/fastrtps-config.cmake:60 (include)
CMakeLists.txt:37 (find_package)
```

#### Additional information

Installing Fast-DDS from source didn't fix the issue for me either

Contributor guide

Open the contributing guide

Research direction

Reproduce the failure with create_agent_ws.sh and build_agent.sh on Ubuntu 22.04 with ROS 2 Humble. Inspect CMakeLists.txt at the find_package call and the referenced fastrtps CMake configuration, using the reported target definitions as the starting point. Done means the micro-ROS agent workspace builds successfully and the agent can be run.

Written by the indexing model from the issue text.

Assessment

Tech stack
cmake, linux, shell, ubuntu
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.