alex-courtis / way-displays

way-displays: Auto Manage Your Wayland Displays
MIT License
241 stars 12 forks source link

1.5.1 fails to build with Clang due to -Werror #37

Closed jbeich closed 2 years ago

jbeich commented 2 years ago

Regressed by 231282c66d39

$ cc --version
FreeBSD clang version 13.0.0 (git@github.com:llvm/llvm-project.git llvmorg-13.0.0-0-gd7b669b3a303)
Target: x86_64-unknown-freebsd14.0
Thread model: posix
InstalledDir: /usr/bin

$ gmake CC=cc CXX=c++
wayland-scanner client-header pro/wlr-output-management-unstable-v1.xml pro/wlr-output-management-unstable-v1.h
cc -pedantic -Wall -Wextra -Werror -Wno-unused-parameter -O3 -std=gnu17 -Wold-style-definition -Wstrict-prototypes -I/usr/local/include/libepoll-shim  -I/usr/local/include  -I/usr/local/include -I/usr/local/include/libepoll-shim  -I/usr/local/include  -I/usr/local/include  -I/usr/local/include  -Iinc -Ipro -D_GNU_SOURCE -DVERSION=\""1.5.2-SNAPSHOT"\"  -c -o src/client.o src/client.c
In file included from src/client.c:9:
inc/log.h:36:88: error: token pasting of ',' and __VA_ARGS__ is a GNU extension [-Werror,-Wgnu-zero-variadic-macro-arguments]
#define log_error(__format, ...) log_efl_(ERROR, 0, (char*)__FILE__, __LINE__, __format, ##__VA_ARGS__)
                                                                                       ^
1 error generated.
gmake: *** [<builtin>: src/client.o] Error 1
alex-courtis commented 2 years ago

Thanks @jbeich

Reverted. Released 1.5.2.

I'll re-express those changes as functions at a later date.