Ticket #1684: alfs_wgetsettings.patch
File alfs_wgetsettings.patch, 4.4 KB (added by , 15 years ago) |
---|
-
common/libs/func_validate_configs.sh
23 23 local -r BOOK_common="BOOK CUSTOM_TOOLS" 24 24 local -r BOOK_clfsX="ARCH TARGET" 25 25 local -r GENERAL_common="LUSER LGROUP LHOME BUILDDIR CLEAN GETPKG SRC_ARCHIVE \ 26 SERVER GETKERNEL RUNMAKE" 26 SERVER RETRYSRCDOWNLOAD RETRYDOWNLOADCNT DOWNLOADTIMEOUT \ 27 GETKERNEL RUNMAKE" 27 28 local -r BUILD_chroot="TEST BOMB_TEST STRIP" 28 29 local -r BUILD_common="FSTAB CONFIG TIMEZONE PAGE LANG INSTALL_LOG" 29 30 local -r ADVANCED_chroot="COMPARE RUN_ICA RUN_FARCE ITERATIONS OPTIMIZE" … … 135 136 GETKERNEL ) if [[ -z "$CONFIG" ]] && [[ -z "$BOOT_CONFIG" ]] ; then 136 137 [[ "$GETPKG" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" 137 138 fi ;; 138 COMPARE) [[ ! "$COMPARE" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 139 RUN_ICA) [[ "$COMPARE" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 140 RUN_FARCE) [[ "$COMPARE" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 141 ITERATIONS) [[ "$COMPARE" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 142 BOMB_TEST) [[ ! "$TEST" = "0" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 143 TARGET32) [[ -n "${TARGET32}" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 144 MIPS_LEVEL) [[ "${ARCH}" = "mips" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 145 SERVER) [[ "$GETPKG" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 139 COMPARE) [[ ! "$COMPARE" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 140 RUN_ICA) [[ "$COMPARE" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 141 RUN_FARCE) [[ "$COMPARE" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 142 ITERATIONS) [[ "$COMPARE" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 143 BOMB_TEST) [[ ! "$TEST" = "0" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 144 TARGET32) [[ -n "${TARGET32}" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 145 MIPS_LEVEL) [[ "${ARCH}" = "mips" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 146 SERVER) [[ "$GETPKG" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 147 RETRYSRCDOWNLOAD) [[ "$GETPKG" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 148 RETRYDOWNLOADCNT) [[ "$GETPKG" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 149 DOWNLOADTIMEOUT) [[ "$GETPKG" = "y" ]] && echo -e "`eval echo $PARAM_VALS`" ;; 146 150 147 151 # Envars that requires some validation 148 152 LUSER) echo -e "`eval echo $PARAM_VALS`" -
common/libs/func_download_pkgs
68 68 fromARCHIVE=0 69 69 # If the file does not exist yet in /sources download a fresh one 70 70 if [ ! -f $FILE ] ; then 71 if ! wget $URL1 && ! wget $URL2 ; then 71 if [[ "${RETRYSRCDOWNLOAD}" = "y" ]] ; then 72 WGETPARAM="--retry-connrefused" 73 fi 74 WGETPARAM+=" --tries ${RETRYDOWNLOADCNT}" 75 WGETPARAM+=" --tries ${DOWNLOADTIMEOUT}" 76 if ! wget $URL1 $WGETPARAM && ! wget $URL2 $WGETPARAM ; then 72 77 gs_wrt_message "$FILE not found in the SRC_ARCHIVE or on any server..SKIPPING" 73 78 continue 74 79 fi -
Config.in
746 746 # Any missing file will be downloaded and archived here, 747 747 # if the user has the right priviledges. 748 748 749 config RETRYSRCDOWNLOAD 750 bool "Retry on 'connection refused' failure" 751 default n 752 depends GETPKG 753 help 754 #-- Attempt to download a source package again if it fails 755 # with a 'connection refused' error. This can happen on 756 # servers that are overloaded. 757 758 config RETRYDOWNLOADCNT 759 int "Number of retry attempts on download failures" 760 default 20 761 depends GETPKG 762 help 763 #-- Number of times to retry download a failed download. 764 765 config DOWNLOADTIMEOUT 766 int "Download timeout (in seconds)" 767 default 30 768 depends GETPKG 769 help 770 #-- Number of seconds to wait for a download to start before 771 # timing out. 772 749 773 config SERVER 750 774 string "FTP mirror" 751 775 default "ftp://ftp.lfs-matrix.net"