-
Notifications
You must be signed in to change notification settings - Fork 4
42 lines (38 loc) · 1.1 KB
/
dronecan_sitl.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
name: dronecan_sitl
on:
push:
branches:
- main
pull_request:
branches:
- '*'
jobs:
sitl:
strategy:
matrix:
include:
- os: ubuntu-24.04
- os: ubuntu-22.04
- os: ubuntu-20.04
runs-on: ${{ matrix.os }}
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Install dependencies
run: |
pip install -r requirements.txt
sudo apt-get install -y gcc-arm-none-eabi linux-modules-extra-$(uname -r)
- name: Setup GCC for Ubuntu 20.04
if: matrix.os == 'ubuntu-20.04'
run: |
sudo apt update
sudo apt install -y gcc-10 g++-10
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-10 100
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-10 100
- name: Build SITL DroneCAN
run: make sitl_dronecan
- name: Run SITL for 5 seconds
run: timeout 5s make run || res=$?; if [[ $res -ne 124 && $res -ne 0 ]]; then exit $res; fi