Commit 269506e
committed
ci: build libusb and hidraw backends as C++ on ubuntu
Issue #671 reported that libusb/hid.c failed to compile as C++ source;
PR #811 made it C++-clean. linux/hid.c already builds as C++. There is
no CI step that exercises the C++ compilation path, so a similar
regression could slip through unnoticed.
Add a step to the ubuntu-cmake job that compiles libusb/hid.c and
linux/hid.c with `g++ -xc++ -Wall -Wextra -Werror -Wformat-signedness`.
That matches the existing C build's warning set, except `-pedantic` is
omitted: libusb.h declares zero-size arrays and hidapi relies on
designated initialisers — both GNU extensions that g++ accepts in its
default mode but rejects under strict ISO C++.
Assisted-by: Claude:claude-opus-4.71 parent e8243e1 commit 269506e
1 file changed
Lines changed: 15 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
154 | 154 | | |
155 | 155 | | |
156 | 156 | | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
157 | 172 | | |
158 | 173 | | |
159 | 174 | | |
| |||
0 commit comments