package/libdill: fix build with gcc-15.x

Adding -std=gnu17 was recommended in upstream PR:
https://github.com/sustrik/libdill/issues/229#issuecomment-2865524080

Fixes:
https://autobuild.buildroot.net/results/1a5/1a5e9d7df6c83a921cae39b4dc4b601be4d18e36/

Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
Signed-off-by: Arnout Vandecappelle <arnout@rnout.be>
This commit is contained in:
Bernd Kuhls
2026-05-30 11:10:18 +02:00
committed by Arnout Vandecappelle
parent 5b9a32dc72
commit b2dda65134

View File

@@ -13,6 +13,13 @@ LIBDILL_INSTALL_STAGING = YES
LIBDILL_DEPENDENCIES = host-pkgconf
LIBDILL_AUTORECONF = YES
# gcc-15 defaults to -std=gnu23 which introduces build failures.
# We force "-std=gnu17" for gcc version supporting it. Earlier gcc
# versions will work, since they are using the older standard.
ifeq ($(BR2_TOOLCHAIN_GCC_AT_LEAST_8),y)
LIBDILL_CONF_ENV += CFLAGS="$(TARGET_CFLAGS) -std=gnu17"
endif
ifeq ($(BR2_TOOLCHAIN_HAS_THREADS),y)
LIBDILL_CONF_OPTS += --enable-threads
else