Add ROS_ROOT configuration for cross-compilation

Add ROS_ROOT argument to compose.yaml, update toolchain CMake to search
in ROS_ROOT, and modify final stage of Dockerfiles to copy to ROS_ROOT
instead of TARGET_SYSROOT. Also add support for ROS2 lyrical distro.
This commit is contained in:
EricX-Zhao
2026-05-11 10:28:33 +03:00
parent 6cd4227324
commit e276ce3a64
6 changed files with 536 additions and 2 deletions
+2
View File
@@ -32,9 +32,11 @@ services:
build:
context: .
dockerfile: ros2/${ROS_DISTRO}/ros_${ROS_DISTRO}.Dockerfile
# target: ros_builder
args:
ROS_DISTRO: ${ROS_DISTRO}
PLATFORM: ${PLATFORM}
ROS_ROOT: /opt/ros/${ROS_DISTRO}
CC_PLATFORM_IMAGE: ${PLATFORM}/cc-toolchain:latest
VENDOR_PACKAGES_IMAGE: ${PLATFORM}/cc-vendor-packages:latest
image: ${PLATFORM}/cc-ros-${ROS_DISTRO}:latest