diff options
author | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-03-05 18:48:51 +0100 |
---|---|---|
committer | Wladimir J. van der Laan <laanwj@gmail.com> | 2018-03-05 18:49:19 +0100 |
commit | d77b4a7bcf23baf10c8a37d6a0f4b6ee2f0300b2 (patch) | |
tree | 8a6f4357e48b13f8ebef174778e92d6315b0fc38 | |
parent | cbc1fcf576cdf8e2701f37496a1946bd7870a6e9 (diff) | |
parent | 87c4320dfc8eff46f13851ab8a1651a84d2301da (diff) |
Merge #12527: gitian-build.sh: fix signProg being recognized as two parameters
87c4320df gitian-build.sh: fix signProg being recognized as two parameters (Ken Lee)
Pull request description:
On current build script, `gpg --detach-sign` will be recognized as two parameters of gsign
This PR fix it and can build successfully
Tree-SHA512: 32e2f9e8414658ea4145bcbccd9aaa3cdf61ea648ad9328246bad67957e11a8e496afec71cbd888f8d0d49bd7eaed35c971fe2dac43b80ee6e664b90ffd997a3
-rwxr-xr-x | contrib/gitian-build.sh | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/contrib/gitian-build.sh b/contrib/gitian-build.sh index d334c1642f..94d6a89c7b 100755 --- a/contrib/gitian-build.sh +++ b/contrib/gitian-build.sh @@ -77,7 +77,7 @@ while :; do -S|--signer) if [ -n "$2" ] then - SIGNER=$2 + SIGNER="$2" shift else echo 'Error: "--signer" requires a non-empty argument.' @@ -190,7 +190,7 @@ fi # Get signer if [[ -n "$1" ]] then - SIGNER=$1 + SIGNER="$1" shift fi @@ -203,7 +203,7 @@ then fi # Check that a signer is specified -if [[ $SIGNER == "" ]] +if [[ "$SIGNER" == "" ]] then echo "$scriptName: Missing signer." echo "Try $scriptName --help for more information" @@ -272,7 +272,7 @@ then echo "Compiling ${VERSION} Linux" echo "" ./bin/gbuild -j ${proc} -m ${mem} --commit bitcoin=${COMMIT} --url bitcoin=${url} ../bitcoin/contrib/gitian-descriptors/gitian-linux.yml - ./bin/gsign -p $signProg --signer $SIGNER --release ${VERSION}-linux --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-linux.yml + ./bin/gsign -p "$signProg" --signer "$SIGNER" --release ${VERSION}-linux --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-linux.yml mv build/out/bitcoin-*.tar.gz build/out/src/bitcoin-*.tar.gz ../bitcoin-binaries/${VERSION} fi # Windows @@ -282,7 +282,7 @@ then echo "Compiling ${VERSION} Windows" echo "" ./bin/gbuild -j ${proc} -m ${mem} --commit bitcoin=${COMMIT} --url bitcoin=${url} ../bitcoin/contrib/gitian-descriptors/gitian-win.yml - ./bin/gsign -p $signProg --signer $SIGNER --release ${VERSION}-win-unsigned --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-win.yml + ./bin/gsign -p "$signProg" --signer "$SIGNER" --release ${VERSION}-win-unsigned --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-win.yml mv build/out/bitcoin-*-win-unsigned.tar.gz inputs/bitcoin-win-unsigned.tar.gz mv build/out/bitcoin-*.zip build/out/bitcoin-*.exe ../bitcoin-binaries/${VERSION} fi @@ -293,7 +293,7 @@ then echo "Compiling ${VERSION} Mac OSX" echo "" ./bin/gbuild -j ${proc} -m ${mem} --commit bitcoin=${COMMIT} --url bitcoin=${url} ../bitcoin/contrib/gitian-descriptors/gitian-osx.yml - ./bin/gsign -p $signProg --signer $SIGNER --release ${VERSION}-osx-unsigned --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-osx.yml + ./bin/gsign -p "$signProg" --signer "$SIGNER" --release ${VERSION}-osx-unsigned --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-osx.yml mv build/out/bitcoin-*-osx-unsigned.tar.gz inputs/bitcoin-osx-unsigned.tar.gz mv build/out/bitcoin-*.tar.gz build/out/bitcoin-*.dmg ../bitcoin-binaries/${VERSION} fi @@ -306,9 +306,9 @@ then echo "Committing ${VERSION} Unsigned Sigs" echo "" pushd gitian.sigs - git add ${VERSION}-linux/${SIGNER} - git add ${VERSION}-win-unsigned/${SIGNER} - git add ${VERSION}-osx-unsigned/${SIGNER} + git add ${VERSION}-linux/"${SIGNER}" + git add ${VERSION}-win-unsigned/"${SIGNER}" + git add ${VERSION}-osx-unsigned/"${SIGNER}" git commit -a -m "Add ${VERSION} unsigned sigs for ${SIGNER}" popd fi @@ -358,7 +358,7 @@ then echo "Signing ${VERSION} Windows" echo "" ./bin/gbuild -i --commit signature=${COMMIT} ../bitcoin/contrib/gitian-descriptors/gitian-win-signer.yml - ./bin/gsign -p $signProg --signer $SIGNER --release ${VERSION}-win-signed --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-win-signer.yml + ./bin/gsign -p "$signProg" --signer "$SIGNER" --release ${VERSION}-win-signed --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-win-signer.yml mv build/out/bitcoin-*win64-setup.exe ../bitcoin-binaries/${VERSION} mv build/out/bitcoin-*win32-setup.exe ../bitcoin-binaries/${VERSION} fi @@ -369,7 +369,7 @@ then echo "Signing ${VERSION} Mac OSX" echo "" ./bin/gbuild -i --commit signature=${COMMIT} ../bitcoin/contrib/gitian-descriptors/gitian-osx-signer.yml - ./bin/gsign -p $signProg --signer $SIGNER --release ${VERSION}-osx-signed --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-osx-signer.yml + ./bin/gsign -p "$signProg" --signer "$SIGNER" --release ${VERSION}-osx-signed --destination ../gitian.sigs/ ../bitcoin/contrib/gitian-descriptors/gitian-osx-signer.yml mv build/out/bitcoin-osx-signed.dmg ../bitcoin-binaries/${VERSION}/bitcoin-${VERSION}-osx.dmg fi popd @@ -381,8 +381,8 @@ then echo "" echo "Committing ${VERSION} Signed Sigs" echo "" - git add ${VERSION}-win-signed/${SIGNER} - git add ${VERSION}-osx-signed/${SIGNER} + git add ${VERSION}-win-signed/"${SIGNER}" + git add ${VERSION}-osx-signed/"${SIGNER}" git commit -a -m "Add ${VERSION} signed binary sigs for ${SIGNER}" popd fi |