]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
meson: gate wdctl on linux/watchdog.h
authorThomas Weißschuh <thomas@t-8ch.de>
Wed, 29 Apr 2026 11:53:59 +0000 (13:53 +0200)
committerThomas Weißschuh <thomas@t-8ch.de>
Tue, 12 May 2026 11:46:35 +0000 (13:46 +0200)
The target needs this header, encode this in the build system.

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
meson.build

index 1bf26d997d05a2784c08609b8b2a693451f2ac3f..d518a4aa94c536938f7467252652a63d410b2a44 100644 (file)
@@ -2069,7 +2069,9 @@ if opt and not is_disabler(exe)
   bashcompletions += ['chcpu']
 endif
 
-opt = get_option('build-wdctl').allowed()
+opt = get_option('build-wdctl') \
+      .require(conf.get('HAVE_LINUX_WATCHDOG_H').to_string() == '1') \
+      .allowed()
 exe = executable(
   'wdctl',
   wdctl_sources,