Skip to content

Commit 5bfa0c6

Browse files
committed
Add CI verifying building on linux works
1 parent 9ba164d commit 5bfa0c6

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

.github/workflows/build.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
pull_request:
7+
branches: ["main"]
8+
9+
env:
10+
BUILD_TYPE: Release
11+
CEF_ARCHIVE: cef_binary_3.3578.1861.g1992780_linux64.tar.bz2
12+
CEF_ROOT: ${{ github.workspace }}/cef
13+
14+
jobs:
15+
build-on-ubuntu:
16+
runs-on: ubuntu-24.04
17+
18+
steps:
19+
- uses: actions/checkout@v4
20+
with:
21+
submodules: true
22+
23+
- name: Cache CEF
24+
id: cache-cef
25+
uses: actions/cache@v4
26+
with:
27+
path: cef.tar.bz2
28+
key: ${{ runner.os }}-cef-${{ env.CEF_ARCHIVE }}
29+
30+
- name: Download CEF
31+
if: steps.cache-cef.outputs.cache-hit != 'true'
32+
run: wget https://cef-builds.spotifycdn.com/${{ env.CEF_ARCHIVE }} -O cef.tar.bz2
33+
34+
- name: Extract CEF
35+
run: mkdir -p ${{ env.CEF_ROOT }} && tar -xjf cef.tar.bz2 -C ${{ env.CEF_ROOT }} --strip-components=1
36+
37+
- name: Install dependencies
38+
run: sudo apt-get update && sudo apt-get install -y libgit2-dev libopencv-dev qtbase5-dev qtscript5-dev qtmultimedia5-dev libqt5x11extras5-dev
39+
40+
- name: Configure CMake
41+
run: cmake -B ${{ github.workspace }}/build -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -DCEF_ROOT=${{ env.CEF_ROOT }}
42+
43+
- name: Build
44+
run: cmake --build ${{ github.workspace }}/build --config ${{ env.BUILD_TYPE }}

0 commit comments

Comments
 (0)