-
Notifications
You must be signed in to change notification settings - Fork 5
72 lines (66 loc) · 1.49 KB
/
build.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
62
63
64
65
66
67
68
69
70
71
72
name: Build
on:
push:
branches:
- '*'
tags:
- '[0-9]*'
pull_request:
branches:
- '*'
defaults:
run:
shell: bash
env:
build_type: Release
jobs:
linux:
name: Linux
runs-on: ubuntu-latest
strategy:
matrix:
config:
- { name: "GCC", cc: gcc, cxx: g++ }
- { name: "clang", cc: clang, cxx: clang++ }
env:
cc: ${{ matrix.config.cc }}
cxx: ${{ matrix.config.cxx }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Checkout Qtilitools
uses: actions/checkout@v3
with:
repository: qtilities/qtilitools
path: qtilitools
- name: Update Packages
run: sudo apt-get update
- name: Install Dependencies
run: |
packages=(
qtbase5-dev
qttools5-dev
)
sudo apt-get install ${packages[@]}
- name: Build and install Qtilitools
working-directory: ${{ github.workspace }}/qtilitools
run: |
options=(
-D CMAKE_INSTALL_PREFIX="/usr"
-D CMAKE_BUILD_TYPE=${{ env.build_type }}
-B build
)
cmake ${options[@]}
sudo cmake --install build
- name: Configure
run: |
options=(
-D CMAKE_INSTALL_PREFIX="/usr"
-D CMAKE_BUILD_TYPE=${{ env.build_type }}
-B build
)
cmake ${options[@]}
- name: Build
run: cmake --build build --config ${{ env.build_type }}