From f57185db953670d6e4f334b7ad2dc79a96d703c4 Mon Sep 17 00:00:00 2001 From: Robin Gloster Date: Mon, 13 Mar 2017 13:31:44 +0100 Subject: fetch-*: remove md5 support fixes #4491 --- pkgs/build-support/fetchdarcs/default.nix | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'pkgs/build-support/fetchdarcs') diff --git a/pkgs/build-support/fetchdarcs/default.nix b/pkgs/build-support/fetchdarcs/default.nix index 3c2e0524eea5c..2644a20d0a531 100644 --- a/pkgs/build-support/fetchdarcs/default.nix +++ b/pkgs/build-support/fetchdarcs/default.nix @@ -1,13 +1,16 @@ {stdenv, darcs, nix}: {url, rev ? null, context ? null, md5 ? "", sha256 ? ""}: +if md5 != "" then + throw "fetchdarcs does not support md5 anymore, please use sha256" +else stdenv.mkDerivation { name = "fetchdarcs"; builder = ./builder.sh; buildInputs = [darcs]; - outputHashAlgo = if sha256 == "" then "md5" else "sha256"; + outputHashAlgo = "sha256"; outputHashMode = "recursive"; - outputHash = if sha256 == "" then md5 else sha256; - + outputHash = sha256; + inherit url rev context; } -- cgit 1.4.1