nixpkgs/pkgs/development/python-modules/keyutils/default.nix
Alyssa Ross 858f0e8ed9 python3.pkgs.keyutils: fix cross
When cross-compiling, tests aren't run, and check inputs aren't
available.  But pytest-runner was a setup requirement, so keyutils
would fail to build without it, even though we weren't running the
tests.  To fix that, drop the pytest-runner setup requirement.
2021-11-21 13:51:23 +00:00

28 lines
756 B
Nix

{ lib, buildPythonPackage, fetchFromGitHub, keyutils, pytest-runner, pytest }:
buildPythonPackage rec {
pname = "keyutils";
version = "0.6";
# github version comes bundled with tests
src = fetchFromGitHub {
owner = "sassoftware";
repo = "python-keyutils";
rev = version;
sha256 = "0pfqfr5xqgsqkxzrmj8xl2glyl4nbq0irs0k6ik7iy3gd3mxf5g1";
};
postPatch = ''
substituteInPlace setup.py --replace '"pytest-runner"' ""
'';
buildInputs = [ keyutils ];
checkInputs = [ pytest pytest-runner ];
meta = {
description = "A set of python bindings for keyutils";
homepage = "https://github.com/sassoftware/python-keyutils";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ primeos ];
};
}