[tracker/wip/hadess/fix-build-bash-completion] Fix meson error when bash completion is disabled



commit d7e582c8fb7809acf20641e95cc3a7b017eba00a
Author: Bastien Nocera <hadess hadess net>
Date:   Wed Feb 26 23:46:52 2020 +0100

    Fix meson error when bash completion is disabled
    
    Passing -Dbash_completion=false would error out as the
    bash_completion_dir variable is never set.
    
    meson.build:310:0: ERROR: Unknown variable "bash_completion_dir".
    
    Fixes: d318ebeb5d4f984c61373b492d86ca50fbfd71dc
    
    Closes: #187

 meson.build | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
---
diff --git a/meson.build b/meson.build
index a8e1c4cfd..2226fb930 100644
--- a/meson.build
+++ b/meson.build
@@ -318,7 +318,13 @@ summary = [
   '    Build with SQLite FTS support:          @0@ (built-in FTS: @1@)'.format(
      get_option('fts'), sqlite3_has_builtin_fts5),
   '    Build with Stemming support:            ' + have_libstemmer.to_string(),
-  '    Bash completion support:                ' + bash_completion_dir,
 ]
 
+if get_option('bash_completion')
+  summary += [
+    '    Bash completion support:                ' + bash_completion_dir,
+  ]
+endif
+
+
 message('\n'.join(summary))


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]