Skip to content

Commit ac59079

Browse files
committed
add humble CI
1 parent 87f274a commit ac59079

1 file changed

Lines changed: 69 additions & 0 deletions

File tree

.github/workflows/build_22_04.yaml

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
name: 'Ubuntu 22.04 + ROS Humble: Build '
2+
on:
3+
push:
4+
branches:
5+
- 'main'
6+
- 'feature/humble-ci'
7+
pull_request:
8+
branches:
9+
- '*'
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
config:
18+
- {name: 'Ubuntu 22.04 + ROS Humble: Build ', rosdistro: 'humble', container: 'osrf/ros:humble-desktop-full'}
19+
container: ${{ matrix.config.container }}
20+
steps:
21+
- uses: actions/checkout@v4
22+
23+
- name: Setup ccache
24+
shell: bash
25+
run: |
26+
apt update && apt install -y ccache
27+
export PATH="/usr/lib/ccache:$PATH"
28+
export CCACHE_DIR=$HOME/colcon_ws/ccache
29+
export CCACHE_STAMP=$(date +%Y-%m-%d_%H-%M-%S)
30+
echo "Updated PATH=$PATH"
31+
echo "Set CCACHE_DIR=$CCACHE_DIR"
32+
echo "Set CCACHE_STAMP=$CCACHE_STAMP"
33+
echo "CCACHE_DIR=$CCACHE_DIR" >> $GITHUB_ENV
34+
echo "CCACHE_STAMP=$CCACHE_STAMP" >> $GITHUB_ENV
35+
echo "PATH=$PATH" >> $GITHUB_ENV
36+
mkdir -p $CCACHE_DIR
37+
ccache --max-size=1G
38+
39+
- name: Cache ccache files
40+
uses: actions/cache@v4
41+
with:
42+
path: ${{ env.CCACHE_DIR }}
43+
key: ${{ matrix.config.name }}-ccache-${{ env.CCACHE_STAMP }}
44+
restore-keys: |
45+
${{ matrix.config.name }}-ccache-
46+
47+
- name: Install System Deps on Humble
48+
if: ${{ matrix.config.container == 'osrf/ros:humble-desktop-full' }}
49+
run: |
50+
sudo apt update
51+
sudo apt-get install -y python3-colcon-common-extensions python3-vcstool
52+
sudo apt-get install -y git build-essential cmake ninja-build \
53+
libeigen3-dev libgoogle-glog-dev libtbb-dev libyaml-cpp-dev
54+
chmod +x $GITHUB_WORKSPACE/docker/scripts/install_ceres.sh
55+
sudo $GITHUB_WORKSPACE/docker/scripts/install_ceres.sh
56+
57+
- name: Release Build Test
58+
env:
59+
DEBIAN_FRONTEND: noninteractive
60+
shell: bash
61+
run: |
62+
source /opt/ros/${{ matrix.config.rosdistro }}/setup.bash
63+
mkdir -p $HOME/colcon_ws/src
64+
cd $HOME/colcon_ws/src
65+
ln -s $GITHUB_WORKSPACE
66+
cd $HOME/colcon_ws
67+
colcon build \
68+
--packages-up-to bievr_lio_ros2 \
69+
--cmake-args -DCMAKE_BUILD_TYPE=RelWithDebInfo

0 commit comments

Comments
 (0)