forked from gnuradio/gnuradio
-
Notifications
You must be signed in to change notification settings - Fork 0
221 lines (221 loc) · 7.02 KB
/
make-test.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
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
name: 'Make Test'
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
# We start with checking C++ formatting. No one gets free CPU cycles if they
# can't use clang-format.
check-formatting:
name: Check C++ Formatting
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v2
- uses: DoozyX/[email protected]
with:
source: '.'
exclude: './volk'
extensions: 'h,hpp,cpp,cc,cc.in'
clangFormatVersion: 14
check-python-formatting:
name: Check Python Formatting
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v2
- uses: quentinguidee/pep8-action@v1
with:
# -----------------------------------
# UPDATE tox.ini when making changes!
arguments: '--max-line-length=120 --ignore E265,E266,E275,E402,E501,E704,E712,E713,E714,E711,E721,E722,E741,W504,W605 --exclude *.yml.py'
# -----------------------------------
# Doxygen gets built separately. It has a lot of output and its own weirdness.
doxygen:
name: Doxygen
runs-on: ubuntu-latest # This can run on whatever
timeout-minutes: 15
container:
image: 'gnuradio/ci:ubuntu-20.04-3.9'
volumes:
- build_data:/build
steps:
- uses: actions/checkout@v2
name: Checkout Project
- name: CMake
run: 'cd /build && cmake ${GITHUB_WORKSPACE}'
- name: Make Docs
run: 'cd /build && make doxygen_target'
linux-docker:
# All of these shall depend on the formatting check (needs: check-formatting)
needs: [check-formatting, check-python-formatting]
runs-on: ubuntu-latest
# The GH default is 360 minutes (it's also the max as of Feb-2021). However
# we should fail sooner. The only reason to exceed this time is if a test
# hangs.
timeout-minutes: 120
strategy:
# Enabling fail-fast would kill all Dockers if one of them fails. We want
# maximum output.
fail-fast: false
matrix:
# For every distro we want to test here, add one key 'distro' with a
# descriptive name, and one key 'containerid' with the name of the
# container (i.e., what you want to docker-pull)
include:
- distro: 'Ubuntu 20.04'
containerid: 'gnuradio/ci:ubuntu-20.04-3.9'
cxxflags: -Werror
ctest_args: '-E ""'
# ldpath:
- distro: 'Ubuntu 22.04'
containerid: 'gnuradio/ci:ubuntu-22.04-3.9'
cxxflags: -Werror
ctest_args: '-E "qa_polar_..coder_(sc_)?systematic"'
# ldpath:
- distro: 'Ubuntu 24.04'
containerid: 'gnuradio/ci:ubuntu-24.04-3.10'
cxxflags: -Werror
- distro: 'Fedora 39 (with 0xFE memory initialization, GLIBCXX_ASSERTIONS)'
containerid: 'gnuradio/ci:fedora-39-3.10'
cxxflags: -Werror -ftrivial-auto-var-init=pattern -Wp,-D_GLIBCXX_ASSERTIONS
ctest_args: '-E ""'
ldpath: /usr/local/lib64/
- distro: 'Fedora 40 (clang)'
containerid: 'gnuradio/ci:fedora-40-3.10'
cxxflags: -Werror
cmakeflags: -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang
ctest_args: '-E ""'
ldpath: /usr/local/lib64
- distro: 'Debian 12'
containerid: 'gnuradio/ci:debian-12-3.10'
cxxflags: -Werror
ctest_args: '-E ""'
# ldpath:
- distro: 'Debian 11 (32-bit)'
containerid: 'gnuradio/ci:debian-i386-11-3.10'
containeroptions: '--platform linux/i386'
cxxflags: -Werror
ctest_args: '-E "qa_polar_..coder_(sc_)?systematic"'
# ldpath:
name: ${{ matrix.distro }}
container:
image: ${{ matrix.containerid }}
volumes:
- build_data:/build
options: --cpus 2 ${{ matrix.containeroptions }}
steps:
- uses: actions/checkout@v1
name: Checkout Project
- name: CMake
env:
CXXFLAGS: ${{ matrix.cxxflags }}
run: 'cd /build && cmake ${{ matrix.cmakeflags }} ${GITHUB_WORKSPACE} -DENABLE_DOXYGEN=OFF'
- name: Dump compile commands
run: 'cd /build && cat compile_commands.json'
- name: Make
run: 'cd /build && make -j2 -k'
- name: Make Test
env:
QT_QPA_PLATFORM: offscreen
run: 'cd /build && ctest --output-on-failure ${{ matrix.ctest_args }}'
- name: Make Install
run: |
cd /build
su -c "make install"
su -c "echo ${{matrix.ldpath}} >> /etc/ld.so.conf"
su -c ldconfig
- name: Test Python3
run: python3 -c "import gnuradio.blocks; print(gnuradio.blocks.complex_to_float())"
no-python:
# All of these shall depend on the formatting check (needs: check-formatting)
needs: [check-formatting, check-python-formatting]
runs-on: ubuntu-latest
# The GH default is 360 minutes (it's also the max as of Feb-2021). However
# we should fail sooner. The only reason to exceed this time is if a test
# hangs.
timeout-minutes: 120
name: C++ Only Build (Ubuntu 20.04)
container:
image: 'gnuradio/ci:ubuntu-20.04-3.9'
volumes:
- build_data:/build
options: --cpus 2
steps:
- uses: actions/checkout@v2
name: Checkout Project
- name: CMake
env:
CXXFLAGS: -Werror
run: 'cd /build && cmake ${GITHUB_WORKSPACE} -DENABLE_DOXYGEN=OFF -DENABLE_PYTHON=OFF'
- name: Make
run: 'cd /build && make -j2 -k'
- name: Make Test
run: 'cd /build && ctest --output-on-failure'
mingw64:
# All of these shall depend on the formatting check (needs: check-formatting)
needs: [check-formatting, check-python-formatting]
runs-on: windows-latest
name: MinGW-w64
defaults:
run:
shell: msys2 {0}
steps:
- name: Setup MSYS2
uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
install: >-
git
make
pacboy: >-
toolchain:p
cmake:p
ninja:p
boost:p
cppzmq:p
fftw:p
gsl:p
gsm:p
gtk3:p
jack2:p
libsndfile:p
libunwind:p
pango:p
portaudio:p
pybind11:p
python:p
python-click:p
python-gobject:p
python-jsonschema:p
python-mako:p
python-numpy:p
python-pip:p
python-pyqt5:p
python-pyzmq:p
python-yaml:p
qt5-base:p
qwt-qt5:p
SDL:p
soapysdr:p
spdlog:p
thrift:p
volk:p
- name: Checkout code
uses: actions/checkout@v4
- name: CMake
run: |
cmake -S . -B build \
-DCMAKE_INSTALL_PREFIX=${RUNNER_TEMP}/msys64/mingw64 \
-DENABLE_DOXYGEN=OFF
- name: Make
run: cmake --build build
- name: Make Install
run: cmake --install build
- name: Make Test
working-directory: ./build
run: ctest --output-on-failure