-
-
Notifications
You must be signed in to change notification settings - Fork 262
191 lines (185 loc) · 5.55 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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
name: build
on: [push, pull_request]
jobs:
client:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
compiler:
- {cc: gcc, cxx: g++}
- {cc: clang, cxx: clang++}
wayland_shell: [xdg-shell, libdecor]
build_type: [Release, Debug]
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install libdecor PPA
run: sudo add-apt-repository ppa:christianrauch/libdecoration
if: ${{ matrix.wayland_shell == 'libdecor' }}
- name: Install PipeWire repository
run: |
echo 'deb [trusted=yes] https://pipewire-ubuntu.quantum5.workers.dev ./' | sudo tee /etc/apt/sources.list.d/pipewire.list
- name: Update apt
run: |
sudo apt-get update
- name: Install client dependencies
run: |
sudo apt-get install \
binutils-dev \
libspice-protocol-dev nettle-dev \
libgl-dev libgles-dev \
libx11-dev libxss-dev libxi-dev libxinerama-dev libxcursor-dev libxpresent-dev \
libwayland-dev libxkbcommon-dev \
libsamplerate0-dev libpipewire-0.3-dev libpulse-dev \
$([ '${{ matrix.wayland_shell }}' = libdecor ] && echo 'libdecor-0-dev libdbus-1-dev') \
$([ '${{ matrix.compiler.cc }}' = clang ] && echo 'clang-tools')
sudo pip3 install pyenchant
- name: Configure client
env:
CC: /usr/bin/${{ matrix.compiler.cc }}
CXX: /usr/bin/${{ matrix.compiler.cxx }}
run: |
mkdir client/build
cd client/build
cmake \
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
-DCMAKE_LINKER:FILEPATH=/usr/bin/ld \
-DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
-DENABLE_LIBDECOR=${{ matrix.wayland_shell == 'libdecor' }} \
..
- name: Build client
run: |
cd client/build
make -j$(nproc)
- name: Checking help spelling
run: ./client/build/looking-glass-client --help | ./doc/lgspell.py
- name: Check GL function calls
if: matrix.compiler.cc == 'clang'
run: WAYLAND_SHELL='${{ matrix.wayland_shell }}' ./gl-check
module:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Build kernel module
run: |
cd module
make
host-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install PipeWire repository
run: |
echo 'deb [trusted=yes] https://pipewire-ubuntu.quantum5.workers.dev ./' | sudo tee /etc/apt/sources.list.d/pipewire.list
- name: Update apt
run: |
sudo apt-get update
- name: Install Linux host dependencies
run: |
sudo apt-get install binutils-dev libxcb-xfixes0-dev \
libpipewire-0.3-dev
- name: Configure Linux host
run: |
mkdir host/build
cd host/build
cmake ..
- name: Build Linux host
run: |
cd host/build
make -j$(nproc)
host-windows-cross:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Update apt
run: |
sudo apt-get update
- name: Install Windows host cross-compile dependencies
run: |
sudo apt-get install gcc-mingw-w64-x86-64 g++-mingw-w64-x86-64 nsis
- name: Configure Windows host for cross-compile
run: |
mkdir host/build
cd host/build
cmake -DCMAKE_TOOLCHAIN_FILE=../toolchain-mingw64.cmake ..
- name: Cross-compile Windows host
run: |
cd host/build
make -j$(nproc)
- name: Build Windows host installer
run: |
cd host/build
makensis platform/Windows/installer.nsi
- name: Build Windows host installer with IVSHMEM drivers
run: |
cd host/build
curl https://dl.quantum2.xyz/ivshmem.tar.gz | tar xz
makensis -DIVSHMEM platform/Windows/installer.nsi
host-windows-native:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Configure Windows host for native MinGW-w64
run: |
mkdir host\build
cd host\build
cmake -G "MinGW Makefiles" ..
- name: Build Windows host on native MinGW-w64
run: |
cd host\build
mingw32-make "-j$([Environment]::ProcessorCount)"
- name: Build Windows host installer
run: |
cd host\build
makensis -DBUILD_32BIT platform\Windows\installer.nsi
obs:
runs-on: ubuntu-latest
strategy:
matrix:
cc: [gcc, clang]
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Update apt
run: |
sudo apt-get update
- name: Install obs plugin dependencies
run: |
sudo apt-get install binutils-dev libobs-dev libgl1-mesa-dev
- name: Configure obs plugin
run: |
mkdir obs/build
cd obs/build
CC=/usr/bin/${{ matrix.cc }} cmake ..
- name: Build obs plugin
run: |
cd obs/build
make -j$(nproc)
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
with:
submodules: recursive
- name: Update apt
run: |
sudo apt-get update
- name: Install docs dependencies
run: |
sudo apt-get install python3-sphinx python3-sphinx-rtd-theme \
python3-sphinxcontrib.spelling
- name: Build docs
run: |
cd doc
make dirhtml SPHINXOPTS='-b spelling -W' -j$(nproc)