Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

namecoin: fix version parsing for nix-env, reduce with lib usage

+5 -6
+5 -6
pkgs/applications/blockchains/namecoin/default.nix
··· 1 { lib, stdenv, fetchFromGitHub, openssl, boost, libevent, autoreconfHook, db4, miniupnpc, eject, pkg-config, qt4, protobuf, qrencode, hexdump 2 , withGui }: 3 4 - with lib; 5 stdenv.mkDerivation rec { 6 - pname = "namecoin" + optionalString (!withGui) "d"; 7 - version = "nc22.0"; 8 9 src = fetchFromGitHub { 10 owner = "namecoin"; 11 repo = "namecoin-core"; 12 - rev = version; 13 sha256 = "sha256-Z3CLDe0c4IpFPPTie8yoh0kcuvGmiegSgl4ITNSDkgY="; 14 }; 15 ··· 26 db4 27 miniupnpc 28 eject 29 - ] ++ optionals withGui [ 30 qt4 31 protobuf 32 qrencode ··· 38 "--with-boost-libdir=${boost.out}/lib" 39 ]; 40 41 - meta = { 42 description = "Decentralized open source information registration and transfer system based on the Bitcoin cryptocurrency"; 43 homepage = "https://namecoin.org"; 44 license = licenses.mit;
··· 1 { lib, stdenv, fetchFromGitHub, openssl, boost, libevent, autoreconfHook, db4, miniupnpc, eject, pkg-config, qt4, protobuf, qrencode, hexdump 2 , withGui }: 3 4 stdenv.mkDerivation rec { 5 + pname = "namecoin" + lib.optionalString (!withGui) "d"; 6 + version = "22.0"; 7 8 src = fetchFromGitHub { 9 owner = "namecoin"; 10 repo = "namecoin-core"; 11 + rev = "nc${version}"; 12 sha256 = "sha256-Z3CLDe0c4IpFPPTie8yoh0kcuvGmiegSgl4ITNSDkgY="; 13 }; 14 ··· 25 db4 26 miniupnpc 27 eject 28 + ] ++ lib.optionals withGui [ 29 qt4 30 protobuf 31 qrencode ··· 37 "--with-boost-libdir=${boost.out}/lib" 38 ]; 39 40 + meta = with lib; { 41 description = "Decentralized open source information registration and transfer system based on the Bitcoin cryptocurrency"; 42 homepage = "https://namecoin.org"; 43 license = licenses.mit;