From d551062ec4cf33b73df4e0d38671cbe6ca03abc5 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 6 Aug 2003 09:35:05 +0000 Subject: * Scan for wget and use the full path in fetchurl.sh. * Use nix-hash (not md5sum) in fetchurl.sh. --- corepkgs/fetchurl/fetchurl.sh.in | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 corepkgs/fetchurl/fetchurl.sh.in (limited to 'corepkgs/fetchurl/fetchurl.sh.in') diff --git a/corepkgs/fetchurl/fetchurl.sh.in b/corepkgs/fetchurl/fetchurl.sh.in new file mode 100644 index 000000000000..dc92c7ee50d8 --- /dev/null +++ b/corepkgs/fetchurl/fetchurl.sh.in @@ -0,0 +1,10 @@ +#! /bin/sh + +echo "downloading $url into $out..." +@wget@ "$url" -O "$out" || exit 1 + +actual=$(@bindir@/nix-hash --flat $out) +if ! test "$actual" == "$md5"; then + echo "hash is $actual, expected $md5" + exit 1 +fi -- cgit 1.4.1