]> git.ipfire.org Git - thirdparty/kmod.git/commitdiff
meson: allow disabling the bash completion
authorEmil Velikov <emil.l.velikov@gmail.com>
Mon, 2 Sep 2024 17:58:35 +0000 (18:58 +0100)
committerLucas De Marchi <lucas.de.marchi@gmail.com>
Tue, 3 Sep 2024 01:13:54 +0000 (20:13 -0500)
For the cases where you don't want (or cannot) install it. For example,
I've seen similar requests from the Nix people.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/86
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
meson.build
meson_options.txt

index edfaa0d2b7996a6ad7e9ed0006bf026d544b699e..2e39e6c446245c99a8d63fc4e8127c3150afb368 100644 (file)
@@ -192,10 +192,12 @@ if bashcompletiondir == ''
   endif
 endif
 
-install_data(
-  files('shell-completion/bash/kmod'),
-  install_dir : bashcompletiondir,
-)
+if bashcompletiondir != 'no'
+  install_data(
+    files('shell-completion/bash/kmod'),
+    install_dir : bashcompletiondir,
+  )
+endif
 
 #-------------------------------------------------------------------------------
 # Compression support
index 0153d0b48599b4f477ab7d344dc4991f7064aa11..086fbb39f3069d023f7726b5bd2acab7ad136eeb 100644 (file)
@@ -15,7 +15,7 @@ option(
 option(
   'bashcompletiondir',
   type : 'string',
-  description : 'Bash completions directory.',
+  description : 'Bash completions directory. Use "no" to disable.',
 )
 
 # Compression options