From 39c3d0585dd0415afe5bcf1e2fff0f37e94eedb9 Mon Sep 17 00:00:00 2001 From: TadeuBAS Date: Wed, 24 Aug 2022 11:18:39 -0300 Subject: [PATCH] build scripts: add quotes around some paths (#7949) * Update make_libsecp256k1.sh Avoid error when parent folder has spaces `./make_libsecp256k1.sh: line 31: cd: too many arguments` * Avoid error when parent folder has spaces, fix for make_libsecp256k1.sh, make_zbar.sh and make_libusb.sh Co-authored-by: ghost43 --- contrib/make_libsecp256k1.sh | 4 ++-- contrib/make_libusb.sh | 4 ++-- contrib/make_zbar.sh | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/contrib/make_libsecp256k1.sh b/contrib/make_libsecp256k1.sh index f1c1f1efa..275221049 100755 --- a/contrib/make_libsecp256k1.sh +++ b/contrib/make_libsecp256k1.sh @@ -20,7 +20,7 @@ set -e . $(dirname "$0")/build_tools_util.sh || (echo "Could not source build_tools_util.sh" && exit 1) -here=$(dirname $(realpath "$0" 2> /dev/null || grealpath "$0")) +here="$(dirname "$(realpath "$0" 2> /dev/null || grealpath "$0")")" CONTRIB="$here" PROJECT_ROOT="$CONTRIB/.." @@ -28,7 +28,7 @@ pkgname="secp256k1" info "Building $pkgname..." ( - cd $CONTRIB + cd "$CONTRIB" if [ ! -d secp256k1 ]; then git clone https://github.com/bitcoin-core/secp256k1.git fi diff --git a/contrib/make_libusb.sh b/contrib/make_libusb.sh index 6f4bcf4e7..dfa9671f4 100755 --- a/contrib/make_libusb.sh +++ b/contrib/make_libusb.sh @@ -7,7 +7,7 @@ set -e . $(dirname "$0")/build_tools_util.sh || (echo "Could not source build_tools_util.sh" && exit 1) -here=$(dirname $(realpath "$0" 2> /dev/null || grealpath "$0")) +here="$(dirname "$(realpath "$0" 2> /dev/null || grealpath "$0")")" CONTRIB="$here" PROJECT_ROOT="$CONTRIB/.." @@ -15,7 +15,7 @@ pkgname="libusb" info "Building $pkgname..." ( - cd $CONTRIB + cd "$CONTRIB" if [ ! -d libusb ]; then git clone https://github.com/libusb/libusb.git fi diff --git a/contrib/make_zbar.sh b/contrib/make_zbar.sh index de60c68ab..7546def65 100755 --- a/contrib/make_zbar.sh +++ b/contrib/make_zbar.sh @@ -16,7 +16,7 @@ set -e . $(dirname "$0")/build_tools_util.sh || (echo "Could not source build_tools_util.sh" && exit 1) -here=$(dirname $(realpath "$0" 2> /dev/null || grealpath "$0")) +here="$(dirname "$(realpath "$0" 2> /dev/null || grealpath "$0")")" CONTRIB="$here" PROJECT_ROOT="$CONTRIB/.." @@ -24,7 +24,7 @@ pkgname="zbar" info "Building $pkgname..." ( - cd $CONTRIB + cd "$CONTRIB" if [ ! -d zbar ]; then git clone https://github.com/mchehab/zbar.git fi