depot/third_party/nixpkgs/pkgs/development/python-modules/python-ipmi/default.nix
Default email fa5436e0a7 Project import generated by Copybara.
GitOrigin-RevId: e8057b67ebf307f01bdcc8fba94d94f75039d1f6
2024-06-05 17:53:02 +02:00

49 lines
970 B
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
future,
mock,
pytestCheckHook,
pythonOlder,
setuptools,
}:
buildPythonPackage rec {
pname = "python-ipmi";
version = "0.5.5";
pyproject = true;
disabled = pythonOlder "3.6";
src = fetchFromGitHub {
owner = "kontron";
repo = "python-ipmi";
rev = "refs/tags/${version}";
hash = "sha256-G5FcFHtyN8bXMjj/yfJgzcfmV1mxQ9lu3GM3XMeTWVU=";
};
postPatch = ''
substituteInPlace setup.py \
--replace-fail "version=version," "version='${version}',"
'';
nativeBuildInputs = [ setuptools ];
propagatedBuildInputs = [ future ];
nativeCheckInputs = [
mock
pytestCheckHook
];
pythonImportsCheck = [ "pyipmi" ];
meta = with lib; {
description = "Python IPMI Library";
mainProgram = "ipmitool.py";
homepage = "https://github.com/kontron/python-ipmi";
license = with licenses; [ lgpl2Plus ];
maintainers = with maintainers; [ fab ];
};
}