Build fails with GCC 14. This blocks GCC_DEFAULT update to GCC 14. =======================<phase: build >============================ ===== env: NO_DEPENDS=yes USER=root UID=0 GID=0 ===> Building for l2tpd-0.69_12 gcc14 -O2 -pipe -fcommon -fstack-protector-strong -Wl,-rpath=/usr/local/lib/gcc14 -fno-strict-aliasing -DDEBUG_PPPD -DDEBUG_CONTROL -DDEBUG_ENTROPY -Wall -DSANITY -DFREEBSD -DPREFIX=\"/usr/local\" -O -c l2tpd.c -o l2tpd.o In file included from l2tp.h:31, from l2tpd.c:40: misc.h:67:13: warning: conflicting types for built-in function 'log'; expected 'double(double)' [-Wbuiltin-declaration-mismatch] 67 | extern void log (int level, const char *fmt, ...); | ^~~ misc.h:1:1: note: 'log' is declared in header '<math.h>' +++ |+#include <math.h> 1 | /* l2tpd.c: In function 'start_pppd': l2tpd.c:274:11: warning: variable 'str' set but not used [-Wunused-but-set-variable] 274 | char *str; | ^~~ l2tpd.c: In function 'lac_hangup': l2tpd.c:651:17: error: implicit declaration of function 'kill' [-Wimplicit-function-declaration] 651 | kill (tmp->pppd, SIGTERM); | ^~~~ l2tpd.c: In function 'daemonize': l2tpd.c:986:11: warning: variable 'l' set but not used [-Wunused-but-set-variable] 986 | int i,l; | ^ misc.h: At top level: misc.h:71:20: warning: inline function 'swaps' declared but never defined 71 | extern inline void swaps (void *, int); | ^~~~~ *** Error code 1 Stop. make: stopped in /wrkdirs/usr/ports/net/l2tpd/work/l2tpd-0.69 *** Error code 1 Full log: https://pkg-status.freebsd.org/gohan04/data/140amd64-default-foo/2024-08-29_19h57m48s/logs/errors/l2tpd-0.69_12.log Useful link: https://gcc.gnu.org/gcc-14/porting_to.html
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=16c76a4ce238f99fe8839bb5e82f41bbbbaf520b commit 16c76a4ce238f99fe8839bb5e82f41bbbbaf520b Author: Lorenzo Salvadore <salvadore@FreeBSD.org> AuthorDate: 2024-09-05 14:39:05 +0000 Commit: Lorenzo Salvadore <salvadore@FreeBSD.org> CommitDate: 2024-09-05 15:08:27 +0000 net/l2tpd: Fix build with GCC 14 GCC 14 has transformed some warnings into errors: revert them to simple warnings. PR: 281243 Reported by: exp-run (antoine) net/l2tpd/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)