b450903751
GitOrigin-RevId: 74a1793c659d09d7cf738005308b1f86c90cb59b
31 lines
1,020 B
Nix
31 lines
1,020 B
Nix
{ stdenv, lib, buildPythonPackage, isPy3k, fetchFromGitHub, openssl }:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "bitcoinlib";
|
|
version = "0.11.2";
|
|
|
|
disabled = !isPy3k;
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "petertodd";
|
|
repo = "python-bitcoinlib";
|
|
rev = "refs/tags/python-bitcoinlib-v${version}";
|
|
sha256 = "sha256-/VgCTN010W/Svdrs0mGA8W1YZnyTHhcaWJKgP/c8CN8=";
|
|
};
|
|
|
|
postPatch = ''
|
|
substituteInPlace bitcoin/core/key.py --replace \
|
|
"ctypes.util.find_library('ssl') or 'libeay32'" \
|
|
"'${lib.getLib openssl}/lib/libssl${stdenv.hostPlatform.extensions.sharedLibrary}'"
|
|
'';
|
|
|
|
pythonImportsCheck = [ "bitcoin" "bitcoin.core.key" ];
|
|
|
|
meta = with lib; {
|
|
homepage = "https://github.com/petertodd/python-bitcoinlib";
|
|
description = "Easy interface to the Bitcoin data structures and protocol";
|
|
changelog = "https://github.com/petertodd/python-bitcoinlib/raw/${src.rev}/release-notes.md";
|
|
license = with licenses; [ lgpl3Plus ];
|
|
maintainers = with maintainers; [ jb55 ];
|
|
};
|
|
}
|