2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pythonOlder,
|
|
|
|
bitarray,
|
|
|
|
setuptools,
|
2024-07-27 06:49:29 +00:00
|
|
|
pytest-benchmark,
|
|
|
|
pytestCheckHook,
|
2021-08-05 21:33:18 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "bitstring";
|
2024-07-27 06:49:29 +00:00
|
|
|
version = "4.2.3";
|
2024-01-02 11:29:13 +00:00
|
|
|
pyproject = true;
|
2022-12-17 10:02:37 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-08-05 21:33:18 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "scott-griffiths";
|
|
|
|
repo = pname;
|
2023-11-16 04:20:00 +00:00
|
|
|
rev = "refs/tags/bitstring-${version}";
|
2024-07-27 06:49:29 +00:00
|
|
|
hash = "sha256-m2LZdUWOMxzr/biZhD1nWagab8PohHTcr+U1di0nkrU=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
build-system = [ setuptools ];
|
2022-09-09 14:08:57 +00:00
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
dependencies = [ bitarray ];
|
2023-11-16 04:20:00 +00:00
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
nativeCheckInputs = [
|
|
|
|
pytest-benchmark
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
pytestFlagsArray = [
|
|
|
|
"--benchmark-disable"
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTestPaths = [
|
|
|
|
"tests/test_bits.py"
|
|
|
|
"tests/test_fp8.py"
|
|
|
|
"tests/test_mxfp.py"
|
|
|
|
];
|
2022-09-09 14:08:57 +00:00
|
|
|
|
2021-08-05 21:33:18 +00:00
|
|
|
pythonImportsCheck = [ "bitstring" ];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Module for binary data manipulation";
|
|
|
|
homepage = "https://github.com/scott-griffiths/bitstring";
|
|
|
|
license = licenses.mit;
|
|
|
|
platforms = platforms.unix;
|
|
|
|
maintainers = with maintainers; [ bjornfor ];
|
|
|
|
};
|
|
|
|
}
|