From fa3b708fc53971eb8a1f4ff329c1b4b0894942f3 Mon Sep 17 00:00:00 2001 From: milisbir Date: Sun, 31 Dec 2017 10:14:09 +0200 Subject: [PATCH] mpsd-busybox --- bin/mpsd | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/bin/mpsd b/bin/mpsd index 6c7dfd9fb..875dedde7 100755 --- a/bin/mpsd +++ b/bin/mpsd @@ -11,6 +11,15 @@ E_FOOTPRINT=7 # footprint check failure E_BUILD=8 # error while running 'derle()' E_INSTALL=9 # paket kurulum hatası (mps -k) +_gnuwget= `wget | head -n1 | grep "Busybox"` +if [ "${_gnuwget}x" == "x" ];then + wget_sertifika_ayar="--no-check-certificate" + wget_retry="--waitretry=3" +else + wget_sertifika_ayar="" + wget_retry="" +fi + info() { echo "=======> $1" } @@ -158,9 +167,9 @@ download_file() { downloads_file_with_curl $LOCAL_FILENAME $1 else LOCAL_FILENAME_PARTIAL="$LOCAL_FILENAME.partial" - DOWNLOAD_OPTS="--passive-ftp --no-directories --tries=3 --waitretry=3 \ + DOWNLOAD_OPTS="--passive-ftp --no-directories --tries=3 $wget_retry \ -O $LOCAL_FILENAME \ - --output-document=$LOCAL_FILENAME_PARTIAL --no-check-certificate" + --output-document=$LOCAL_FILENAME_PARTIAL $wget_sertifika_ayar" if [ -f "$LOCAL_FILENAME_PARTIAL" ]; then info "Kısmi indirme var,tamamlanmaya çalışılacak"