2022-04-27 09:35:20 +00:00
|
|
|
{ lib, buildPythonPackage, fetchPypi, python, cython }:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "fastbencode";
|
2022-09-09 14:08:57 +00:00
|
|
|
version = "0.0.11";
|
2022-04-27 09:35:20 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2022-09-09 14:08:57 +00:00
|
|
|
sha256 = "sha256-hMLS59/BlzK7aPoTWN5YgE77xEBBYpvYurUD98XqkDI=";
|
2022-04-27 09:35:20 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ cython ];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "fastbencode" ];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
${python.interpreter} -m unittest fastbencode.tests.test_suite
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Fast implementation of bencode";
|
|
|
|
homepage = "https://github.com/breezy-team/fastbencode";
|
2022-07-14 12:49:19 +00:00
|
|
|
license = licenses.gpl2Plus;
|
2022-04-27 09:35:20 +00:00
|
|
|
maintainers = [ maintainers.marsam ];
|
|
|
|
};
|
|
|
|
}
|