-
Notifications
You must be signed in to change notification settings - Fork 12
61 lines (59 loc) · 1.69 KB
/
build-on-linux.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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
name: Build on Linux
on:
push:
branches-ignore:
- dependabot/**
pull_request:
branches:
- master
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-18.04, ubuntu-20.04]
steps:
- uses: actions/checkout@v3
with:
submodules: 'recursive'
fetch-depth: 0
- name: Install dependencies
shell: bash
run: |
# Workaround: gcc >= 8.0 is required.
case $(lsb_release -cs) in
bionic)
sudo apt install -y --no-install-recommends \
gcc-8 g++-8 yasm nasm python3-venv python3-pip python3-setuptools pkg-config ;;
*)
sudo apt install -y --no-install-recommends \
gcc g++ yasm nasm python3-venv python3-pip python3-setuptools pkg-config ;;
esac
python3 -m venv venv
source venv/bin/activate
pip3 install wheel
pip3 install meson
pip3 install ninja
- name: configure
shell: bash
run: |
source venv/bin/activate
# Workaround: gcc >= 8.0 is required.
case $(lsb_release -cs) in
bionic)
export CC=gcc-8
export CXX=g++-8
# bionic's nasm is too old.
sed -i -e 's/-Denable_asm=true/-Denable_asm=false/g' scripts/build-deps.sh
;;
*) ;;
esac
bash scripts/reset-submodules.sh
bash scripts/apply-patches.sh
bash scripts/build-deps.sh
cmake -S . -B build
- name: make
shell: bash
run: |
source venv/bin/activate
env --chdir build make