-
Notifications
You must be signed in to change notification settings - Fork 9
53 lines (47 loc) · 1.44 KB
/
build_linux.yaml
File metadata and controls
53 lines (47 loc) · 1.44 KB
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
43
44
45
46
47
48
49
50
51
52
53
name: Linux Multi-Distro Build
on: [push, pull_request]
jobs:
linux-build:
runs-on: ubuntu-22.04
strategy:
matrix:
include:
- distro: ubuntu22.04
arch: x86_64
- distro: ubuntu20.04
arch: x86_64
- distro: debian-bookworm
arch: x86_64
- distro: fedora-latest
arch: x86_64
- distro: alpine-latest
arch: x86_64
- distro: centos-stream
arch: x86_64
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Build on ${{ matrix.distro }} (${{ matrix.arch }})
uses: uraimo/run-on-arch-action@v3
with:
distro: ${{ matrix.distro }}
arch: ${{ matrix.arch }}
githubToken: ${{ github.token }}
setup: |
sudo apt-get update || true
sudo yum check-update || true
sudo apk update || true
run: |
# Install build dependencies
if [ -f /etc/debian_version ]; then
sudo apt-get install -y build-essential
elif [ -f /etc/redhat-release ]; then
sudo yum install -y gcc-c++ make
elif [ -f /etc/alpine-release ]; then
sudo apk add build-base
fi
# Your build commands here
mkdir build
cd build
cmake ..
make -j$(nproc)