about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/xlib/default.nix
blob: 0852e4b13fc3dd7fd3c80655fbca3b735dae5a3b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
{
  lib,
  stdenv,
  buildPythonPackage,
  fetchFromGitHub,
  six,
  setuptools-scm,
  xorg,
  python,
  mock,
  nose,
  pytestCheckHook,
  util-linux,
}:

buildPythonPackage rec {
  pname = "xlib";
  version = "0.33";
  format = "setuptools";

  src = fetchFromGitHub {
    owner = "python-xlib";
    repo = "python-xlib";
    rev = "refs/tags/${version}";
    hash = "sha256-u06OWlMIOUzHOVS4hvm72jGgTSXWUqMvEQd8bTpFog0=";
  };

  nativeBuildInputs = [ setuptools-scm ];

  buildInputs = [ xorg.libX11 ];

  propagatedBuildInputs = [ six ];

  doCheck = !stdenv.isDarwin;

  nativeCheckInputs = [
    pytestCheckHook
    mock
    nose
    util-linux
    xorg.xauth
    xorg.xorgserver
  ];

  disabledTestPaths = [
    # requires x session
    "test/test_xlib_display.py"
  ];

  meta = with lib; {
    changelog = "https://github.com/python-xlib/python-xlib/releases/tag/${version}";
    description = "Fully functional X client library for Python programs";
    homepage = "https://github.com/python-xlib/python-xlib";
    license = licenses.lgpl21Plus;
    maintainers = with maintainers; [ ];
  };
}