From f4c8cc1293db50731b750279d5956fb4578c2942 Mon Sep 17 00:00:00 2001 From: Kiefer Chang Date: Tue, 3 Dec 2019 14:03:21 +0800 Subject: [PATCH] vstart: fix error when getting CMake variables with the same prefix The function fails to work when there are multiple variables starts with the same prefix. e.g. - WITH_RBD - WITH_RBD_RGW Fixes: https://tracker.ceph.com/issues/43095 Signed-off-by: Kiefer Chang --- src/vstart.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vstart.sh b/src/vstart.sh index a2a4e35f4c0..7de78b75c23 100755 --- a/src/vstart.sh +++ b/src/vstart.sh @@ -47,7 +47,7 @@ fi get_cmake_variable() { local variable=$1 - grep "$variable" CMakeCache.txt | cut -d "=" -f 2 + grep "${variable}:" CMakeCache.txt | cut -d "=" -f 2 } # for running out of the CMake build directory -- 2.39.5