From 7cdc4b709a2147fa98a9bb56ff06a1dfcaa434a5 Mon Sep 17 00:00:00 2001 From: Andreas Dilger Date: Fri, 8 May 2020 17:28:39 -0600 Subject: [PATCH] LU-13225 utils: fix install path for bash-completion Fix the default install path for bash-completion if the package is not installed at build time. This avoids BASH_COMPLETION_DIR being badly formatted in the lustre.spec file. Fixes: dfb4afc24102 ("LU-13225 utils: bash completion for lfs and lctl") Test-Parameters: trivial Signed-off-by: Andreas Dilger Change-Id: Ie50071c4ff86f57bc9dd53409ae339da2a3ebbe5 Reviewed-on: https://review.whamcloud.com/38548 Tested-by: jenkins Tested-by: Maloo Reviewed-by: Jian Yu Reviewed-by: Ben Evans Reviewed-by: Oleg Drokin --- lustre.spec.in | 2 +- lustre/autoconf/lustre-core.m4 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lustre.spec.in b/lustre.spec.in index 8d15abf..24f18f0 100644 --- a/lustre.spec.in +++ b/lustre.spec.in @@ -601,7 +601,7 @@ fi %{_bindir}/lfs_migrate /sbin/mount.lustre /sbin/mount.lustre_tgt -%{_datadir}/bash-completion/completions/* +@BASH_COMPLETION_DIR@ %endif %if %{with manpages} diff --git a/lustre/autoconf/lustre-core.m4 b/lustre/autoconf/lustre-core.m4 index 446598f..4c8bef4 100644 --- a/lustre/autoconf/lustre-core.m4 +++ b/lustre/autoconf/lustre-core.m4 @@ -2736,7 +2736,7 @@ AC_ARG_WITH([bash-completion-dir], AS_IF([test "x$with_bash_completion_dir" = "xyes"], [ BASH_COMPLETION_DIR="`pkg-config --variable=completionsdir bash-completion`" AS_IF([test "x$BASH_COMPLETION_DIR" = "x"], [ - [BASH_COMPLETION_DIR="$datadir/bash-completion/completions"] + [BASH_COMPLETION_DIR="/usr/share/bash-completion/completions"] ]) ], [ BASH_COMPLETION_DIR="$with_bash_completion_dir" -- 1.8.3.1