Created attachment 272413 [details] Full poudriere log for qt6-base compile failure Hello everyone, on a recent FreeBSD 16 CURRENT (version 1600019) qt6-base doers not compile with poudriere. The part of the log that is interesting : In file included from /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/forkfd_qt.c:16: /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd.c:162:39: warning: call to undeclared function 'ATOMIC_VAR_INIT'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] 162 | static ffd_atomic_int forkfd_status = FFD_ATOMIC_INIT(0); | ^ /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd_c11.h:54:37: note: expanded from macro 'FFD_ATOMIC_INIT' 54 | #define FFD_ATOMIC_INIT(val) ATOMIC_VAR_INIT(val) | ^ In file included from /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/forkfd_qt.c:16: /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd.c:162:39: error: initializer element is not a compile-time constant 162 | static ffd_atomic_int forkfd_status = FFD_ATOMIC_INIT(0); | ^~~~~~~~~~~~~~~~~~ /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd_c11.h:54:37: note: expanded from macro 'FFD_ATOMIC_INIT' 54 | #define FFD_ATOMIC_INIT(val) ATOMIC_VAR_INIT(val) | ^~~~~~~~~~~~~~~~~~~~ In file included from /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/forkfd_qt.c:16: In file included from /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd.c:930: /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd_freebsd.c:45:45: error: initializer element is not a compile-time constant 45 | static ffd_atomic_int system_forkfd_state = FFD_ATOMIC_INIT(1); | ^~~~~~~~~~~~~~~~~~ /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd_c11.h:54:37: note: expanded from macro 'FFD_ATOMIC_INIT' 54 | #define FFD_ATOMIC_INIT(val) ATOMIC_VAR_INIT(val) | ^~~~~~~~~~~~~~~~~~~~ 1 warning and 2 errors generated. unfortunately it block a lot of ports from building (mainly for KDE). This file does not seem to have changed upstream so it would seem a change on the FreeBSD side poses this problem, maybe linked to clang/llvm ?
It showed up last month: https://pkg-status.freebsd.org/beefy24/data/main-amd64-default/p0cd7b5a3f54a_sa4ed783cee2/logs/qt6-base-6.11.1.log
Created attachment 272569 [details] Patch for src/3rdparty/forkfd/forkfd.c ensuring atomic or stdatomic.h gets included in the end, depending on the language selected This is a crude and brute-force patch, but devel/qt6-base finally builds on a test system at work, FreeBSD 16.0-CURRENT #1345 main+local-n246954-cf07ca11e99b: Fri Jul 3 14:54:02 CEST 2026.
(In reply to Trond Endrestøl from comment #2) Maybe my patch isn't needed at all. I tried building devel/qt6-base on the same system as mentioned in the previous comment without my patch being accessible, and the build succeeded. If the build still fails on 16.0-CURRENT, then maybe update your live system and possibly the jail/snapshot used by Poudriere and Synth. qt6-base is configured as follows: $ make -C /usr/ports/devel/qt6-base showconfig ===> The following configuration options are available for qt6-base-6.11.1: CUPS=on: CUPS printing system support WAYLAND=on: Wayland (graphics) support X11=on: X11 (graphics) support ===> Use 'make config' to modify these settings
unfortunately even with your patch it still does not build with a FreeBSD 16.0-CURRENT at revision main-n286766-c27779e0a954 I still have : In file included from /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/forkfd_qt.c:16: /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd.c:170:39: warning: call to undeclared function 'ATOMIC_VAR_INIT'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] 170 | static ffd_atomic_int forkfd_status = FFD_ATOMIC_INIT(0); | ^ /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd_c11.h:54:37: note: expanded from macro 'FFD_ATOMIC_INIT' 54 | #define FFD_ATOMIC_INIT(val) ATOMIC_VAR_INIT(val) | ^ In file included from /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/forkfd_qt.c:16: /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd.c:170:39: error: initializer element is not a compile-time constant 170 | static ffd_atomic_int forkfd_status = FFD_ATOMIC_INIT(0); | ^~~~~~~~~~~~~~~~~~ /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd_c11.h:54:37: note: expanded from macro 'FFD_ATOMIC_INIT' 54 | #define FFD_ATOMIC_INIT(val) ATOMIC_VAR_INIT(val) | ^~~~~~~~~~~~~~~~~~~~ In file included from /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/forkfd_qt.c:16: In file included from /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd.c:938: /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd_freebsd.c:45:45: error: initializer element is not a compile-time constant 45 | static ffd_atomic_int system_forkfd_state = FFD_ATOMIC_INIT(1); | ^~~~~~~~~~~~~~~~~~ /wrkdirs/usr/ports/devel/qt6-base/work/qtbase-everywhere-src-6.11.1/src/corelib/io/../../3rdparty/forkfd/forkfd_c11.h:54:37: note: expanded from macro 'FFD_ATOMIC_INIT' 54 | #define FFD_ATOMIC_INIT(val) ATOMIC_VAR_INIT(val) | ^~~~~~~~~~~~~~~~~~~~ 1 warning and 2 errors generated.
Created attachment 272572 [details] Patch for src/3rdparty/forkfd/forkfd_c11.h trying to ensure ATOMIC_VAR_INIT is defined in the same way I could find in the standard header files on 16.0-CURRENT. Each bug seems to involve src/3rdparty/forkfd/forkfd_c11.h, so why not brute-force our way there.
I managed to compile with your second patch, thank you.