1{ lib
2, fetchFromGitHub
3, buildPythonPackage
4, psutil
5, pygobject3
6, gtk3
7, gobject-introspection
8, xapps
9, polkit
10}:
11
12buildPythonPackage rec {
13 pname = "xapp";
14 version = "2.0.2";
15
16 src = fetchFromGitHub {
17 owner = "linuxmint";
18 repo = "python-xapp";
19 rev = version;
20 sha256 = "1zgh4k96i939w4scikajmlriayk1zg3md16f8fckjvqbphpxrysl";
21 };
22
23 propagatedBuildInputs = [
24 psutil
25 pygobject3
26 gtk3
27 gobject-introspection
28 xapps
29 polkit
30 ];
31
32 postPatch = ''
33 substituteInPlace "xapp/os.py" --replace "/usr/bin/pkexec" "${polkit}/bin/pkexec"
34 '';
35
36 doCheck = false;
37 pythonImportsCheck = [ "xapp" ];
38
39 meta = with lib; {
40 homepage = "https://github.com/linuxmint/python-xapp";
41 description = "Cross-desktop libraries and common resources for python";
42 license = licenses.lgpl2;
43 platforms = platforms.linux;
44 maintainers = [ maintainers.mkg20001 ];
45 };
46}