From b1016e3be80b1e610b84eba527c95bbb9c5971f4 Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Wed, 7 Feb 2024 15:06:13 +0100 Subject: [PATCH] build: workaround -Wno-calloc-transposed-args warning in systemd code Upstream systemd fixed this compiler warning. What really needs to be done, is re-importing the upstream code. In the meantime, suppress the warning that hits on GCC 14. This is a temporary workaround! See-also: https://github.com/systemd/systemd/commit/fdd84270df0062fad68783eea8b51a6ed87b67cd --- configure.ac | 1 + src/meson.build | 1 + 2 files changed, 2 insertions(+) diff --git a/configure.ac b/configure.ac index 9dc6d8199b..01a1dacf43 100644 --- a/configure.ac +++ b/configure.ac @@ -1159,6 +1159,7 @@ NM_COMPILER_WARNINGS(AM_CFLAGS, ${more_warnings_default}) for w in \ -Wno-nonnull-compare \ + -Wno-calloc-transposed-args \ ; do NM_COMPILER_WARNING_FLAG(LIBSYSTEMD_NM_CFLAGS, "$w") done diff --git a/src/meson.build b/src/meson.build index ceeee6a028..5d85dafc21 100644 --- a/src/meson.build +++ b/src/meson.build @@ -73,6 +73,7 @@ libnm_systemd_common_cflags = [ ] libnm_systemd_common_cflags += cc.get_supported_arguments([ '-Wno-nonnull-compare', + '-Wno-calloc-transposed-args', ]) ###############################################################################