2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv
|
2018-10-29 13:50:45 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, six
|
2021-06-03 10:09:11 +00:00
|
|
|
, setuptools-scm
|
2019-03-14 04:58:01 +00:00
|
|
|
, xorg
|
|
|
|
, python
|
|
|
|
, mock
|
|
|
|
, nose
|
2020-11-24 15:29:28 +00:00
|
|
|
, util-linux
|
2018-10-29 13:50:45 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "xlib";
|
2021-01-06 22:29:01 +00:00
|
|
|
version = "0.29";
|
2018-10-29 13:50:45 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "python-xlib";
|
|
|
|
repo = "python-xlib";
|
2019-03-14 04:58:01 +00:00
|
|
|
rev = version;
|
2021-01-06 22:29:01 +00:00
|
|
|
sha256 = "sha256-zOG1QzRa5uN36Ngv8i5s3mq+VIoRzxFj5ltUbKdonJ0=";
|
2018-10-29 13:50:45 +00:00
|
|
|
};
|
|
|
|
|
2019-03-14 04:58:01 +00:00
|
|
|
checkPhase = ''
|
|
|
|
${python.interpreter} runtests.py
|
|
|
|
'';
|
2018-10-29 13:50:45 +00:00
|
|
|
|
2020-11-24 15:29:28 +00:00
|
|
|
checkInputs = [ mock nose util-linux /* mcookie */ xorg.xauth xorg.xorgserver /* xvfb */ ];
|
2021-06-03 10:09:11 +00:00
|
|
|
nativeBuildInputs = [ setuptools-scm ];
|
2019-03-14 04:58:01 +00:00
|
|
|
buildInputs = [ xorg.libX11 ];
|
|
|
|
propagatedBuildInputs = [ six ];
|
2018-10-29 13:50:45 +00:00
|
|
|
|
2019-04-23 02:49:34 +00:00
|
|
|
doCheck = !stdenv.isDarwin;
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2018-10-29 13:50:45 +00:00
|
|
|
description = "Fully functional X client library for Python programs";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "http://python-xlib.sourceforge.net/";
|
2018-10-29 13:50:45 +00:00
|
|
|
license = licenses.gpl2Plus;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|