2023-09-12 11:40:40 +02:00
|
|
|
{ lib
|
|
|
|
, argparse-addons
|
|
|
|
, bitstruct
|
2023-11-20 10:16:12 +01:00
|
|
|
, buildPythonPackage
|
2023-09-12 11:40:40 +02:00
|
|
|
, can
|
|
|
|
, crccheck
|
|
|
|
, diskcache
|
2023-11-20 10:16:12 +01:00
|
|
|
, fetchPypi
|
2023-09-12 11:40:40 +02:00
|
|
|
, matplotlib
|
|
|
|
, parameterized
|
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
2023-11-20 10:16:12 +01:00
|
|
|
, setuptools
|
|
|
|
, setuptools-scm
|
2023-09-12 11:40:40 +02:00
|
|
|
, textparser
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "cantools";
|
2024-03-08 02:39:26 +01:00
|
|
|
version = "39.4.5";
|
2023-11-16 09:11:29 +01:00
|
|
|
pyproject = true;
|
2023-09-12 11:40:40 +02:00
|
|
|
|
2023-11-16 09:12:02 +01:00
|
|
|
disabled = pythonOlder "3.8";
|
2023-09-12 11:40:40 +02:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2024-03-08 02:39:26 +01:00
|
|
|
hash = "sha256-WU8q6A3q24xrCOjhMi1C4lj0DULIDWiG2E4BQ/kLWiM=";
|
2023-09-12 11:40:40 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
2023-11-16 09:11:29 +01:00
|
|
|
setuptools
|
2023-11-20 10:16:12 +01:00
|
|
|
setuptools-scm
|
2023-09-12 11:40:40 +02:00
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
argparse-addons
|
|
|
|
bitstruct
|
|
|
|
can
|
|
|
|
crccheck
|
|
|
|
diskcache
|
|
|
|
textparser
|
|
|
|
];
|
|
|
|
|
2024-03-26 11:14:53 +01:00
|
|
|
passthru.optional-dependencies.plot = [
|
|
|
|
matplotlib
|
|
|
|
];
|
|
|
|
|
2023-09-12 11:40:40 +02:00
|
|
|
nativeCheckInputs = [
|
|
|
|
parameterized
|
|
|
|
pytestCheckHook
|
2024-03-26 11:14:53 +01:00
|
|
|
] ++ passthru.optional-dependencies.plot;
|
2023-09-12 11:40:40 +02:00
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"cantools"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
2023-11-16 09:11:29 +01:00
|
|
|
description = "Tools to work with CAN bus";
|
2024-03-19 03:14:51 +01:00
|
|
|
mainProgram = "cantools";
|
2023-09-12 11:40:40 +02:00
|
|
|
homepage = "https://github.com/cantools/cantools";
|
2023-11-16 09:11:29 +01:00
|
|
|
changelog = "https://github.com/cantools/cantools/releases/tag/${version}";
|
2023-09-12 11:40:40 +02:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ gray-heron ];
|
|
|
|
};
|
|
|
|
}
|