ch9344: 2.0 -> 0-unstable-2024-11-15 (#354536)
[NixPkgs.git] / pkgs / development / python-modules / fastbencode / default.nix
blob195491ec8ab665e8200dbc5bcb152e9003f8e037
2   lib,
3   buildPythonPackage,
4   cython,
5   fetchPypi,
6   python,
7   pythonOlder,
8   setuptools,
9 }:
11 buildPythonPackage rec {
12   pname = "fastbencode";
13   version = "0.3.1";
14   pyproject = true;
16   disabled = pythonOlder "3.8";
18   src = fetchPypi {
19     inherit pname version;
20     hash = "sha256-X+DLfRc2iRr2HSreQM6UiUHUbpCLFvU4P1XxJ4SNoZc=";
21   };
23   build-system = [ setuptools ];
25   nativeBuildInputs = [ cython ];
27   pythonImportsCheck = [ "fastbencode" ];
29   checkPhase = ''
30     ${python.interpreter} -m unittest fastbencode.tests.test_suite
31   '';
33   meta = with lib; {
34     description = "Fast implementation of bencode";
35     homepage = "https://github.com/breezy-team/fastbencode";
36     changelog = "https://github.com/breezy-team/fastbencode/releases/tag/v${version}";
37     license = licenses.gpl2Plus;
38     maintainers = [ ];
39   };