Skip to content

Commit

Permalink
Compile generate_parameter_library on rhel9
Browse files Browse the repository at this point in the history
  • Loading branch information
christophfroehlich committed Jan 23, 2024
1 parent 689c10b commit b344814
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 0 deletions.
39 changes: 39 additions & 0 deletions Dockerfile.rhel9
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ RUN dnf install \
make \
langpacks-en \
git \
wget \
-y --refresh
RUN dnf config-manager --set-enabled crb

Expand All @@ -21,6 +22,44 @@ python3-colcon-common-extensions
RUN rosdep init
RUN pip3 install vcstool colcon-mixin colcon-coveragepy-result colcon-lcov-result

# install cmake 3.23.5
RUN \
cd && \
wget https://github.com/Kitware/CMake/releases/download/v3.23.5/cmake-3.23.5-linux-x86_64.tar.gz && \
cd /usr && \
tar --strip-components=1 -xzf ~/cmake-3.23.5-linux-x86_64.tar.gz && \
rm ~/cmake-3.23.5-linux-x86_64.tar.gz

# install additional dependencies
# TODO where does the mix of python3.9 and python3.11 come from?
RUN \
cd && \
wget https://bootstrap.pypa.io/get-pip.py && \
python3.11 get-pip.py && rm get-pip.py && \
python3.11 -m pip install catkin-pkg

# setup colcon mixin and metadata
RUN colcon mixin add default \
https://raw.githubusercontent.com/colcon/colcon-mixin-repository/master/index.yaml && \
colcon mixin update && \
colcon metadata add default \
https://raw.githubusercontent.com/colcon/colcon-metadata-repository/master/index.yaml && \
colcon metadata update

ENV ROS2_WS /opt/ros2_ws
RUN mkdir -p $ROS2_WS/src
WORKDIR $ROS2_WS
ADD ros-controls.repos .
RUN vcs import src < ros-controls.repos && \
source /opt/ros/$ROS_DISTRO/setup.sh && \
rosdep update --rosdistro $ROS_DISTRO && \
rosdep install -iyr --from-path src || true && \
colcon build \
--mixin release build-testing-off \
--cmake-args --no-warn-unused-cli \
--packages-up-to generate_parameter_library && \
rm -rf log src build

# set up sourcing of ros
COPY ./ros_entrypoint.sh /
ENTRYPOINT [ "/ros_entrypoint.sh" ]
Expand Down
9 changes: 9 additions & 0 deletions ros-controls.repos
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
repositories:
rsl:
type: git
url: https://github.com/PickNikRobotics/RSL.git
version: main
generate_parameter_library:
type: git
url: https://github.com/PickNikRobotics/generate_parameter_library.git
version: main

0 comments on commit b344814

Please sign in to comment.