include/download.mk: Add download mirrors for tools from GNU Savannah (bug #15184)
authorJohn Crispin <john@openwrt.org>
Wed, 8 Oct 2014 08:01:39 +0000 (08:01 +0000)
committerJohn Crispin <john@openwrt.org>
Wed, 8 Oct 2014 08:01:39 +0000 (08:01 +0000)
I defined a new download method @SAVANNAH in include/download.mk and scripts/download.pl,
and converted quilt and qemu to use that method.

Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
SVN-Revision: 42840

include/download.mk
scripts/download.pl
tools/qemu/Makefile
tools/quilt/Makefile

index cc4ffb0cfb544131704d7d0ffca3f11c0d8ef33b..adaa2e6ac5ed9b05b7e832309d6de8ad3bea9fd7 100644 (file)
@@ -11,7 +11,7 @@ DOWNLOAD_RDEP=$(STAMP_PREPARED) $(HOST_STAMP_PREPARED)
 define dl_method
 $(strip \
   $(if $(2),$(2), \
-    $(if $(filter @GNOME/% @GNU/% @KERNEL/% @SF/% ftp://% http://% https://% file://%,$(1)),default, \
+    $(if $(filter @GNOME/% @GNU/% @KERNEL/% @SF/% @SAVANNAH/% ftp://% http://% https://% file://%,$(1)),default, \
       $(if $(filter git://%,$(1)),git, \
         $(if $(filter svn://%,$(1)),svn, \
           $(if $(filter cvs://%,$(1)),cvs, \
index d6a55b634c4ac58215433ac326dbc890ca06c05b..9603e708d12c89b83cc8d3ced3037a4a0dd78e91 100755 (executable)
@@ -157,6 +157,11 @@ foreach my $mirror (@ARGV) {
                push @mirrors, "ftp://ftp.belnet.be/mirror/ftp.gnu.org/gnu/$1";
                push @mirrors, "ftp://ftp.mirror.nl/pub/mirror/gnu/$1";
                push @mirrors, "http://mirror.switch.ch/ftp/mirror/gnu/$1";
+       } elsif ($mirror =~ /^\@SAVANNAH\/(.+)$/) {
+               push @mirrors, "http://download.savannah.gnu.org/releases/$1";
+               push @mirrors, "http://nongnu.uib.no/$1";
+               push @mirrors, "http://ftp.igh.cnrs.fr/pub/nongnu/$1";
+               push @mirrors, "http://download-mirror.savannah.gnu.org/releases/$1";
        } elsif ($mirror =~ /^\@KERNEL\/(.+)$/) {
                my @extra = ( $1 );
                if ($filename =~ /linux-\d+\.\d+(?:\.\d+)?-rc/) {
index 45d42d488329f4b0d0c4262683a356c73a68df4c..34440ee8535c4e8fc1c9cbcd6f99f3b1c2fc3f7d 100644 (file)
@@ -10,7 +10,7 @@ PKG_NAME:=qemu
 PKG_VERSION:=0.14.1
 PKG_RELEASE:=1
 
-PKG_SOURCE_URL:=http://download.savannah.gnu.org/releases/qemu/
+PKG_SOURCE_URL:=@SAVANNAH/qemu
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_MD5SUM:=b6c713a8db638e173af53a62d5178640
 
index bda0b9764ec633312dcfa57325766f4f1b56aef5..01b0bd298fa58c6586b54044366fd85574e77e11 100644 (file)
@@ -10,7 +10,7 @@ PKG_NAME:=quilt
 PKG_VERSION:=0.63
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=http://download.savannah.gnu.org/releases/$(PKG_NAME)
+PKG_SOURCE_URL:=@SAVANNAH/quilt
 PKG_MD5SUM:=c0ef4beb58a6fa72563b955e70624b6e
 
 include $(INCLUDE_DIR)/host-build.mk