]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
meson: gate rfkill on linux/rfkill.h
authorThomas Weißschuh <thomas@t-8ch.de>
Wed, 22 Apr 2026 21:24:04 +0000 (23:24 +0200)
committerThomas Weißschuh <thomas@t-8ch.de>
Sun, 3 May 2026 14:30:31 +0000 (16:30 +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 124202ef032cd4189d62bf0a319462039198243a..659c2530a3497710d906b6ab93eb5407ffa9ebbc 100644 (file)
@@ -123,6 +123,7 @@ headers = '''
         linux/nsfs.h
         linux/mount.h
         linux/pr.h
+        linux/rfkill.h
         linux/securebits.h
         linux/tiocl.h
         linux/version.h
@@ -1552,7 +1553,9 @@ if opt and not is_disabler(exe)
   bashcompletions += ['ipcs']
 endif
 
-opt = get_option('build-rfkill').allowed()
+opt = get_option('build-rfkill') \
+      .require(conf.get('HAVE_LINUX_RFKILL_H').to_string() == '1') \
+      .allowed()
 exe = executable(
   'rfkill',
   rfkill_sources,