nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ lib, stdenv
2, buildPythonPackage
3, fetchFromGitHub
4, six
5, setuptools-scm
6, xorg
7, python
8, mock
9, nose
10, pytestCheckHook
11, util-linux
12}:
13
14buildPythonPackage rec {
15 pname = "xlib";
16 version = "0.31";
17
18 src = fetchFromGitHub {
19 owner = "python-xlib";
20 repo = "python-xlib";
21 rev = version;
22 sha256 = "155p9xhsk01z9vdml74h07svlqy6gljnx9c6qbydcr14lwghwn06";
23 };
24
25 nativeBuildInputs = [ setuptools-scm ];
26 buildInputs = [ xorg.libX11 ];
27 propagatedBuildInputs = [ six ];
28
29 doCheck = !stdenv.isDarwin;
30 checkInputs = [
31 pytestCheckHook
32 mock
33 nose
34 util-linux
35 xorg.xauth
36 xorg.xorgserver
37 ];
38
39 disabledTestPaths = [
40 # requires x session
41 "test/test_xlib_display.py"
42 ];
43
44 meta = with lib; {
45 description = "Fully functional X client library for Python programs";
46 homepage = "http://python-xlib.sourceforge.net/";
47 license = licenses.gpl2Plus;
48 };
49
50}