1{ lib
2, buildPythonPackage
3, isPy27
4, fetchPypi
5, substituteAll
6, pkgs
7, pytestCheckHook
8}:
9
10buildPythonPackage rec {
11 pname = "libevdev";
12 version = "0.11";
13 disabled = isPy27;
14
15 src = fetchPypi {
16 inherit pname version;
17 sha256 = "sha256-6coAak3ySIpgvZp0ABHulI2BkEviNk8BflYBaVCPVg8=";
18 };
19
20 patches = [
21 (substituteAll {
22 src = ./fix-paths.patch;
23 libevdev = lib.getLib pkgs.libevdev;
24 })
25 ];
26
27 checkInputs = [ pytestCheckHook ];
28
29 meta = with lib; {
30 description = "Python wrapper around the libevdev C library";
31 homepage = "https://gitlab.freedesktop.org/libevdev/python-libevdev";
32 license = licenses.mit;
33 maintainers = with maintainers; [ nickhu ];
34 };
35}