python310Packages.rlp: adopt, cleanup
This commit is contained in:
parent
4c391ff1df
commit
fb38e46dc1
|
@ -1,31 +1,42 @@
|
|||
{ lib, fetchPypi, buildPythonPackage, pytest, hypothesis, eth-utils }:
|
||||
{ lib
|
||||
, fetchFromGitHub
|
||||
, buildPythonPackage
|
||||
, eth-utils
|
||||
, hypothesis
|
||||
, pytestCheckHook
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "rlp";
|
||||
version = "3.0.0";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "63b0465d2948cd9f01de449d7adfb92d207c1aef3982f20310f8009be4a507e8";
|
||||
src = fetchFromGitHub {
|
||||
owner = "ethereum";
|
||||
repo = "pyrlp";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-GRCq4FU38e08fREg5fweig5Y60jLT2k3Yj1Jk8OA6XY=";
|
||||
};
|
||||
|
||||
checkInputs = [ pytest hypothesis ];
|
||||
propagatedBuildInputs = [ eth-utils ];
|
||||
|
||||
# setuptools-markdown uses pypandoc which is broken at the moment
|
||||
preConfigure = ''
|
||||
substituteInPlace setup.py --replace \'setuptools-markdown\' ""
|
||||
substituteInPlace setup.py --replace "long_description_markdown_filename='README.md'," ""
|
||||
postPatch = ''
|
||||
substituteInPlace setup.py \
|
||||
--replace "'setuptools-markdown'" ""
|
||||
'';
|
||||
|
||||
checkPhase = ''
|
||||
pytest .
|
||||
'';
|
||||
propagatedBuildInputs = [
|
||||
eth-utils
|
||||
];
|
||||
|
||||
meta = {
|
||||
description = "A package for encoding and decoding data in and from Recursive Length Prefix notation";
|
||||
checkInputs = [
|
||||
hypothesis
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "rlp" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "RLP serialization library";
|
||||
homepage = "https://github.com/ethereum/pyrlp";
|
||||
license = lib.licenses.mit;
|
||||
maintainers = with lib.maintainers; [ gebner ];
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ SuperSandro2000 ];
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue