Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib, stdenv, fetchurl, openssl }: 2 3stdenv.mkDerivation rec { 4 pname = "hashcash"; 5 version = "1.22"; 6 7 buildInputs = [ openssl ]; 8 9 src = fetchurl { 10 url = "http://www.hashcash.org/source/hashcash-${version}.tgz"; 11 sha256 = "15kqaimwb2y8wvzpn73021bvay9mz1gqqfc40gk4hj6f84nz34h1"; 12 }; 13 14 makeFlags = [ 15 "generic-openssl" 16 "LIBCRYPTO=-lcrypto" 17 ]; 18 19 installFlags = [ 20 "INSTALL_PATH=${placeholder "out"}/bin" 21 "MAN_INSTALL_PATH=${placeholder "out"}/share/man/man1" 22 "DOC_INSTALL_PATH=${placeholder "out"}/share/doc/hashcash-$(version)" 23 ]; 24 25 meta = with lib; { 26 description = "Proof-of-work algorithm used as spam and denial-of-service counter measure"; 27 homepage = "http://hashcash.org"; 28 license = licenses.gpl2; 29 maintainers = with maintainers; [ kisonecat ]; 30 }; 31}