about summary refs log tree commit diff
path: root/pkgs/build-support
diff options
context:
space:
mode:
authorFrederik Rietdijk <fridh@fridh.nl>2019-07-13 09:45:40 +0200
committerFrederik Rietdijk <fridh@fridh.nl>2019-07-13 09:45:40 +0200
commit54065ae20d6c91cab54aa706d6e819baf673b80c (patch)
tree4b2efeafb2b34de1153ccfb5cf01387842c86143 /pkgs/build-support
parent22cb7f25f2f939a5e38f5e0c0920a743c37a9480 (diff)
parent7803ff314c707ee11a6d8d1c9ac4cde70737d22e (diff)
downloadnixlib-54065ae20d6c91cab54aa706d6e819baf673b80c.tar
nixlib-54065ae20d6c91cab54aa706d6e819baf673b80c.tar.gz
nixlib-54065ae20d6c91cab54aa706d6e819baf673b80c.tar.bz2
nixlib-54065ae20d6c91cab54aa706d6e819baf673b80c.tar.lz
nixlib-54065ae20d6c91cab54aa706d6e819baf673b80c.tar.xz
nixlib-54065ae20d6c91cab54aa706d6e819baf673b80c.tar.zst
nixlib-54065ae20d6c91cab54aa706d6e819baf673b80c.zip
Merge master into staging-next
Diffstat (limited to 'pkgs/build-support')
-rw-r--r--pkgs/build-support/fetchurl/default.nix10
-rw-r--r--pkgs/build-support/fetchurl/mirrors.nix9
2 files changed, 12 insertions, 7 deletions
diff --git a/pkgs/build-support/fetchurl/default.nix b/pkgs/build-support/fetchurl/default.nix
index 3ce90cbeab3a..6300587a7d15 100644
--- a/pkgs/build-support/fetchurl/default.nix
+++ b/pkgs/build-support/fetchurl/default.nix
@@ -49,8 +49,11 @@ in
   # first element of `urls').
   name ? ""
 
-  # Different ways of specifying the hash.
-, outputHash ? ""
+, # SRI hash.
+  hash ? ""
+
+, # Legacy ways of specifying the hash.
+  outputHash ? ""
 , outputHashAlgo ? ""
 , md5 ? ""
 , sha1 ? ""
@@ -103,7 +106,8 @@ let
     else throw "fetchurl requires either `url` or `urls` to be set";
 
   hash_ =
-    if md5 != "" then throw "fetchurl does not support md5 anymore, please use sha256 or sha512"
+    if hash != "" then { outputHashAlgo = null; outputHash = hash; }
+    else if md5 != "" then throw "fetchurl does not support md5 anymore, please use sha256 or sha512"
     else if (outputHash != "" && outputHashAlgo != "") then { inherit outputHashAlgo outputHash; }
     else if sha512 != "" then { outputHashAlgo = "sha512"; outputHash = sha512; }
     else if sha256 != "" then { outputHashAlgo = "sha256"; outputHash = sha256; }
diff --git a/pkgs/build-support/fetchurl/mirrors.nix b/pkgs/build-support/fetchurl/mirrors.nix
index d9e44afb68df..f2336db8852b 100644
--- a/pkgs/build-support/fetchurl/mirrors.nix
+++ b/pkgs/build-support/fetchurl/mirrors.nix
@@ -409,9 +409,10 @@ rec {
 
   # Alsa Project
   alsa = [
-     ftp://ftp.alsa-project.org/pub/
-     http://alsa.cybermirror.org/
-     http://www.mirrorservice.org/sites/ftp.alsa-project.org/pub/
-     http://alsa.mirror.fr/
+    https://www.alsa-project.org/files/pub/
+    ftp://ftp.alsa-project.org/pub/
+    http://alsa.cybermirror.org/
+    http://www.mirrorservice.org/sites/ftp.alsa-project.org/pub/
+    http://alsa.mirror.fr/
   ];
 }