2021-01-24 00:29:22 +00:00
|
|
|
{ lib
|
2020-07-08 14:19:32 +01:00
|
|
|
, buildPythonPackage
|
|
|
|
, isPy27
|
|
|
|
, fetchPypi
|
|
|
|
, substituteAll
|
|
|
|
, pkgs
|
2020-07-08 14:22:42 +01:00
|
|
|
, pytestCheckHook
|
2020-07-08 14:19:32 +01:00
|
|
|
}:
|
2020-04-24 00:20:06 +01:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "libevdev";
|
2020-07-06 16:17:19 +01:00
|
|
|
version = "0.9";
|
2020-04-24 00:20:06 +01:00
|
|
|
disabled = isPy27;
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-07-06 16:17:19 +01:00
|
|
|
sha256 = "17agnigmzscmdjqmrylg1lza03hwjhgxbpf4l705s6i7p7ndaqrs";
|
2020-04-24 00:20:06 +01:00
|
|
|
};
|
|
|
|
|
2020-07-08 14:19:32 +01:00
|
|
|
patches = [
|
|
|
|
(substituteAll {
|
|
|
|
src = ./fix-paths.patch;
|
2021-01-24 00:29:22 +00:00
|
|
|
libevdev = lib.getLib pkgs.libevdev;
|
2020-07-08 14:19:32 +01:00
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2020-07-08 14:22:42 +01:00
|
|
|
checkInputs = [ pytestCheckHook ];
|
2020-04-24 00:20:06 +01:00
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 00:20:06 +01:00
|
|
|
description = "Python wrapper around the libevdev C library";
|
|
|
|
homepage = "https://gitlab.freedesktop.org/libevdev/python-libevdev";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ nickhu ];
|
|
|
|
};
|
|
|
|
}
|