From 4a56aac71ab83cf0848ed254d0e9d955f5835a17 Mon Sep 17 00:00:00 2001 From: Thanh Ha Date: Sat, 28 Jul 2018 18:09:08 -0400 Subject: [PATCH] Use eval so that $cmake_opts is properly parsed Without eval bash inserts single quotes and breaks parameters passed if they have quotes in the parameters. For example `-D CMAKE_CXX_FLAGS="-fPIC -std=gnu++11"` Issue: RELENG-1075 Change-Id: I77046a7edc0516f0ae28dd2b8cd2c8994ad5079e Signed-off-by: Thanh Ha --- shell/cmake-build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shell/cmake-build.sh b/shell/cmake-build.sh index a6a41e4c..2466c173 100644 --- a/shell/cmake-build.sh +++ b/shell/cmake-build.sh @@ -27,7 +27,7 @@ mkdir -p "$build_dir" cd "$build_dir" || exit # $cmake_opts needs to wordsplit to pass options. # shellcheck disable=SC2086 -cmake -DCMAKE_INSTALL_PREFIX="$INSTALL_PREFIX" $cmake_opts .. +eval cmake -DCMAKE_INSTALL_PREFIX="$INSTALL_PREFIX" $cmake_opts .. # $make_opts needs to wordsplit to pass options. # shellcheck disable=SC2086 make $make_opts -- 2.16.6