From 95c1e6241fab0a26085830371ba39fc94777dd48 Mon Sep 17 00:00:00 2001 From: Steve McIntyre Date: Tue, 8 Apr 2014 18:15:22 +0100 Subject: [PATCH] Add more calls to grab_file --- tools/boot/wheezy/boot-x86 | 12 ++++++++++++ tools/wheezy/installtools.sh | 2 ++ 2 files changed, 14 insertions(+) diff --git a/tools/boot/wheezy/boot-x86 b/tools/boot/wheezy/boot-x86 index 61341acd..8f0e576d 100644 --- a/tools/boot/wheezy/boot-x86 +++ b/tools/boot/wheezy/boot-x86 @@ -85,12 +85,14 @@ for image in $BOOT_IMAGES; do dir=$(dirname $image) mkdir -p $dir if [ -n "$LOCAL" -a -f "${LOCALDEBS:-$MIRROR}/dists/$DI_DIST/local/installer-$ARCH/current/images/$image" ]; then + grab_file "${LOCALDEBS:-$MIRROR}/dists/$DI_DIST/local/installer-$ARCH/current/images/$image" cp "${LOCALDEBS:-$MIRROR}/dists/$DI_DIST/local/installer-$ARCH/current/images/$image" "$image" elif [ ! "$DI_WWW_HOME" ];then if [ ! "$DI_DIR" ];then DI_DIR="$MIRROR/dists/$DI_DIST/main/installer-$ARCH/current/images" fi # echo "Copying images from $DI_DIR" + grab_file "$DI_DIR/$image" cp "$DI_DIR/$image" "$image" else wget "$DI_WWW_HOME/$image" -O "$image" @@ -104,11 +106,13 @@ for image in $DISK_IMAGES $EXTRA_DISK_IMAGES; do dir=$(dirname $image) mkdir -p $dir if [ -n "$LOCAL" -a -f "${LOCALDEBS:-$MIRROR}/dists/$DI_DIST/local/installer-$ARCH/current/images/$image" ]; then + grab_file "${LOCALDEBS:-$MIRROR}/dists/$DI_DIST/local/installer-$ARCH/current/images/$image" cp "${LOCALDEBS:-$MIRROR}/dists/$DI_DIST/local/installer-$ARCH/current/images/$image" "$image" elif [ ! "$DI_WWW_HOME" ];then if [ ! "$DI_DIR" ];then DI_DIR="$MIRROR/dists/$DI_DIST/main/installer-$ARCH/current/images" fi + grab_file "$DI_DIR/$image" cp "$DI_DIR/$image" "$image" || true else wget "$DI_WWW_HOME/$image" -O "$image" || rm -f "$image" @@ -123,10 +127,16 @@ if [ "$NN" = "1" ]; then if [ -e "$disk" ]; then dir=$(dirname $disk) mkdir -p $CDDIR/$INSTALLDIR/$dir + grab_file $disk cp -lf $disk $CDDIR/$INSTALLDIR/$dir fi done + grab_file indices/md5sums.gz + if [ -e $MIRROR/indices/md5sums.gz ] ; then + zcat $MIRROR/indices/md5sums.gz | awk '/ tools/ {print $2}' | xargs grab_file + fi + if [ -e "$MIRROR/tools" ] && \ [ ! -e $CDDIR/tools ] && \ [ "$OMIT_DOC_TOOLS" != "1" ] ; then @@ -148,6 +158,7 @@ extra_image () { if [ ! "$DI_DIR" ] ; then DI_DIR="$MIRROR/dists/$DI_DIST/main/installer-$ARCH/current/images" fi + grab_file "$DI_DIR/cdrom/$image" cp "$DI_DIR/cdrom/$image" $CDDIR/$INSTALLDIR/"$image" else wget "$DI_WWW_HOME/cdrom/$image" -O $CDDIR/$INSTALLDIR/"$image" @@ -196,6 +207,7 @@ if [ -z "$SYSLINUXDEB" ]; then echo "ERROR: syslinux package is required" >&2 exit 1 fi +grab_file $SYSLINUXDEB (dpkg --fsys-tarfile "$MIRROR/$SYSLINUXDEB" | \ tar xf - -C $CDDIR/../syslinux ./usr/lib) diff --git a/tools/wheezy/installtools.sh b/tools/wheezy/installtools.sh index ba54c6ec..b5032e8a 100755 --- a/tools/wheezy/installtools.sh +++ b/tools/wheezy/installtools.sh @@ -28,6 +28,8 @@ if [ "$OMIT_MANUAL" != 1 ]; then INSTALLGUIDE=$(zcat $MIRROR/dists/$CODENAME/main/binary-$ARCH//Packages.gz | \ sed -n "s/Filename: \(pool\/main\/i\/installation-guide\/installation-guide-$ARCH.*deb\)$/\1/p") + grab_file $INSTALLGUIDE + if [ -f "$MIRROR/$INSTALLGUIDE" ]; then rm -rf $MANTDIR # Extract documentation from package