[packages/rpm-build-tools] don't override GETURI when using wget
atler
atler at pld-linux.org
Thu Oct 29 13:03:06 CET 2020
commit 947500436acb28d51898eff42b7eb0a6b0159faa
Author: Jan Palus <atler at pld-linux.org>
Date: Thu Oct 29 12:30:52 2020 +0100
don't override GETURI when using wget
-O is not passed correctly when fetching second and subsequent sources
builder.sh | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
---
diff --git a/builder.sh b/builder.sh
index 04f7fe1..f138da9 100755
--- a/builder.sh
+++ b/builder.sh
@@ -271,15 +271,16 @@ download_axel() {
download_wget() {
local outfile=$1 url=$2 retval
- wget --help 2>&1 | grep -q -- ' --no-check-certificate ' && WGET_OPTS="$WGET_OPTS --no-check-certificate"
- wget --help 2>&1 | grep -q -- ' --inet ' && WGET_OPTS="$WGET_OPTS --inet"
- wget --help 2>&1 | grep -q -- ' --retry-connrefused ' && WGET_OPTS="$WGET_OPTS --retry-connrefused"
- wget --help 2>&1 | grep -q -- ' --no-iri ' && WGET_OPTS="$WGET_OPTS --no-iri"
- WGET_OPTS="$WGET_OPTS --user-agent=$USER_AGENT"
-
- GETURI="wget -c -nd -t$WGET_RETRIES $WGET_OPTS $IPOPT"
+ if [ -z "${WGET_OPTS_SET+x}" ]; then
+ wget --help 2>&1 | grep -q -- ' --no-check-certificate ' && WGET_OPTS="$WGET_OPTS --no-check-certificate"
+ wget --help 2>&1 | grep -q -- ' --inet ' && WGET_OPTS="$WGET_OPTS --inet"
+ wget --help 2>&1 | grep -q -- ' --retry-connrefused ' && WGET_OPTS="$WGET_OPTS --retry-connrefused"
+ wget --help 2>&1 | grep -q -- ' --no-iri ' && WGET_OPTS="$WGET_OPTS --no-iri"
+ WGET_OPTS="-c -nd -t$WGET_RETRIES $WGET_OPTS --user-agent=$USER_AGENT $IPOPT --passive-ftp"
+ WGET_OPTS_SET=1
+ fi
- ${GETURI} --passive-ftp -O "$outfile" "$url"
+ wget $WGET_OPTS -O "$outfile" "$url"
retval=$?
if [ $retval -ne 0 ]; then
if [ "`echo $url | grep -E 'ftp://'`" ]; then
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/rpm-build-tools.git/commitdiff/1d8d84a580565981baeefff8fb3677fd644aac9b
More information about the pld-cvs-commit
mailing list