Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ROS2 build step for LibRealSense #11100

Merged
merged 3 commits into from
Nov 17, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions .github/workflows/build-ROS2-package-CI.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: build_lrs_ROS2_package

on:
push:
branches: ['**']
pull_request:
branches: ['**']

jobs:

build_lrs_ros2_package:
runs-on: ubuntu-latest
strategy:
matrix:
ros_distribution:
- foxy
- galactic
- humble
- rolling

include:
# Foxy Fitzroy
- docker_image: ubuntu:focal
ros_distribution: foxy

# Galactic Geochelone
- docker_image: ubuntu:focal
ros_distribution: galactic

# Humble Hawksbill
- docker_image: ubuntu:jammy
ros_distribution: humble

# Rolling Ridley
- docker_image: ubuntu:jammy
ros_distribution: rolling

container:
image: ${{ matrix.docker_image }}
steps:

- name: setup ROS environment
uses: ros-tooling/setup-ros@v0.4
with:
required-ros-distributions: ${{ matrix.ros_distribution }}

- name: build librealsense ROS 2
uses: ros-tooling/action-ros-ci@v0.2
with:
target-ros2-distro: ${{ matrix.ros_distribution }}
skip-tests: true
colcon-defaults: | # We align the build flags to the librealsense2 ROS2 release build.
{
"build": {
"cmake-args": [
"-DBUILD_GRAPHICAL_EXAMPLES=OFF",
"-DBUILD_EXAMPLES=OFF"
]
}
}
10 changes: 5 additions & 5 deletions package.xml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?xml version="1.0"?>

<!-- This file is only used to enable the building librealsense2 -->
<!-- as a debian package for use with ROS (http://ros.org) -->
<!-- via catkin_make (which invokes cmake) -->
<!-- as a debian package for use with ROS 2 (http://ros.org) -->
<!-- via ament_cmake (which invokes cmake) -->

<package format="2">
<name>librealsense2</name>
<!-- The version tag needs to be updated with each new release of librealsense -->
<version>2.53.0</version>
<version>2.54.0</version>
<description>
Library for controlling and capturing data from the Intel(R) RealSense(TM) D400 devices.
</description>
Expand All @@ -20,7 +20,7 @@

<license>Apache License, Version 2.0</license>

<buildtool_depend>catkin</buildtool_depend>
<buildtool_depend>ament_cmake</buildtool_depend>
Nir-Az marked this conversation as resolved.
Show resolved Hide resolved

<build_depend>pkg-config</build_depend>

Expand All @@ -31,6 +31,6 @@
<build_depend>udev</build_depend>

<export>
<build_type>cmake</build_type>
<build_type>ament_cmake</build_type>
</export>
</package>