Skip to content
95 changes: 57 additions & 38 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,49 +16,68 @@ on discourse.

* ROS 2 jazzy
* The latest Rust compiler.
* Cargo extensions for colcon


## Build Instructions


1. Install `rust` and `colcon-cargo`.

**Method 1: Using a machine with ros2-jazzy installed**

```
# Install Rust (see https://rustup.rs/)
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

# Install required system packages
sudo apt install -y git libclang-dev python3-pip

# Install colcon plugins for Rust
sudo apt install python3-colcon-cargo
pip3 install --break-system-packages colcon-ros-cargo
```

**Method 2: Using a container**
We pre-build base containers with all the dependencies you can use `rocker`, `distrobox`, `podman` or
any other oci compliant tool to get a base dev environment. For the purposes of this set of instructions we use distrobox:
```
distrobox create --image ghcr.io/open-rmf/ros2_rust_base:jazzy -n ros2_rust_base
distrobox enter ros2_rust_base
```

2. **Import Workspace Dependencies**
Create a workspace and clone the repo:
```bash
mkdir -p rmf_ws/src
cd rmf_ws/src
git clone https://github.com/open-rmf/next_gen_prototype.git
cd ..
```

3. **Build the PR Packages**
Ensure you are at the workspace root inside the `jazzy` distrobox container, then build the relevant packages:
```bash
colcon build
```
### 1. Install `ROS 2`, `rust` and `colcon-cargo`.

<details>
<summary><b>Method 1: On your local system (click here)</b></summary>

> a. [Install ROS 2 Jazzy](https://docs.ros.org/en/jazzy/Installation/Ubuntu-Install-Debs.html). Make sure to [install the development tools](https://docs.ros.org/en/jazzy/Installation/Ubuntu-Install-Debs.html#install-development-tools-optional).
>
> b. Install `rust`:
> ```bash
> curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
> exec bash
> ```
>
> c. Install colcon extensions:
> ```bash
> # Install required system packages
> sudo apt install -y git libclang-dev python3-pip
>
> # Install colcon plugins for Rust
> sudo apt install python3-colcon-cargo
> pip3 install --break-system-packages colcon-ros-cargo
> cargo install cargo-ament-build
> ```
</details>

<details>
<summary><b>Method 2: Using a container (click here)</b></summary>

> We pre-build base containers with all the dependencies you can use `rocker`, `distrobox`, `podman` or any other oci compliant tool to get a base dev environment. For the purposes of this set of instructions we use distrobox:
> ```bash
> distrobox create --image ghcr.io/open-rmf/ros2_rust_base:jazzy -n ros2_rust_base
> distrobox enter ros2_rust_base
> ```
</details>

### 2. Import Workspace Dependencies
Create a workspace and clone the repo:
```bash
mkdir -p rmf_ws/src
cd rmf_ws/src
git clone https://github.com/open-rmf/next_gen_prototype.git
cd ..
```

### 3. Install ROS package dependencies
```bash
rosdep update
rosdep install --from-paths src --ignore-src --rosdistro jazzy -yr
```

### 4. Build the PR Packages
Ensure you are at the workspace root inside the `jazzy` distrobox container, then build the relevant packages:
```bash
source /opt/ros/jazzy/setup.bash
colcon build
```

## Running Automated Integration Tests
Verify core scenario coordination and robust following behavior:
Expand Down
1 change: 1 addition & 0 deletions path_server/rmf_path_server_demo/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
<buildtool_depend>ament_python</buildtool_depend>

<exec_depend>rclpy</exec_depend>
<exec_depend>ros2launch</exec_depend>
<exec_depend>ament_index_python</exec_depend>
<exec_depend>rmf_prototype_msgs</exec_depend>
<exec_depend>rmf_next_gen_reservation_msgs</exec_depend>
Expand Down
Loading