Package qtile

DoneSubmitted by Stephen Paul Weber.
Details
2 participants
  • Ludovic Courtès
  • Stephen Paul Weber
Owner
unassigned
Severity
normal
S
S
Stephen Paul Weber wrote on 18 Oct 2021 19:47
(address . guix-patches@gnu.org)
YW2zLtEO+q4GY4He@singpolyma-beefy.lan
qtile is an extensible tiling window manager written in Python. This patch
series packages it and some dependencies.
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEWeaCw+rzmiEMpzU00RwpEc5RnN4FAmFtsy4ACgkQ0RwpEc5R
nN6pbxAAsaYoIOfSstRkgHmAsuWkKVH/7n17BkoSgZLJrzjFFxp8VEzX952id/cv
WUZiwbyfaxDB9m+MY203UTkFxiseRMDqqDi3ycHUb9aZPvYwQsaH6PY+P3fgZSmF
mClOA9tSCavRob0ybG7fTVQgG6vRWpV4wmWfC4geWiTZ+C36Wp13z1jHOypmbWWt
3LhfdT02XABHC+HD2TCd9n4RO13ofu9ZtdF88WARk6Sa3fGhOtHc3OSFVYtM6xrl
yCqA/PIoGiDicRBetqmS/fqAGUZ0WKhIM5IxaPfM47piuYDSALxnCJ1GepAS7y57
PppD+0iDTvs/da5WLiarQQUKldjiULMX4Yz3aZnO5aOBvO9+Y9wPQ5LatYinffPA
QBpdU+XsRGgL3xRudDnmN+i1YWmLxjGhYAVprlLjPqHqzC+1D9v8QTWZP8sfgzFg
pEyEcMH7xUYQRZZsak5xhR8hPYBlRK9nE57B8TXg8ApdI6rPVIR1DPOt9XiDhiZa
S0EWzmV4FN5JQ7zUxQQsyoQPzxvwYCoq4RHDx+kNbjGN4C+qPVp6tImIGQ7vPSbs
46nSDdntNMejGFNekKVf5KUDRhl2bw00tUkHVeb8kBUlsAkzP02qvH38tlabNsS7
BDXhefTFFlYdIhrAd+lF+oSA23c2Gog0p0q1mGmbWHv7jGiJ1xA=
=4wiM
-----END PGP SIGNATURE-----


S
S
Stephen Paul Weber wrote on 18 Oct 2021 19:48
[PATCH 1/4] gnu: python-xcffib: Upgrade to 0.11.1.
(address . 51272@debbugs.gnu.org)(name . Stephen Paul Weber)(address . singpolyma@singpolyma.net)
20211018174833.90312-1-singpolyma@singpolyma.net
Required for qtile.

* gnu/packages/python-xyz.scm (python-xcffib): Upgrade to 0.11.1.
---
gnu/packages/python-xyz.scm | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)

Toggle diff (33 lines)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index d7df77c577..6db446efac 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -7283,14 +7283,14 @@ any machine that can run Python.")
 (define-public python-xcffib
   (package
     (name "python-xcffib")
-    (version "0.6.0")
+    (version "0.11.1")
     (source
      (origin
       (method url-fetch)
       (uri (pypi-uri "xcffib" version))
       (sha256
        (base32
-        "04k91yxyb3pgc5lvxmivh8w71yjrap2g57yk3s73x4rm4nvjq51n"))))
+        "0nkglsm9nbhv238iagmmsjcz6lf1yfdvp5kmspphdj385vz9r50j"))))
     (build-system python-build-system)
     (inputs
      `(("libxcb" ,libxcb)))
@@ -7306,7 +7306,8 @@ any machine that can run Python.")
            (lambda* (#:key inputs #:allow-other-keys)
              (let ((libxcb (assoc-ref inputs "libxcb")))
                (substitute* '("xcffib/__init__.py")
-                 (("^soname = \"") (string-append "soname = \"" libxcb "/lib/")))
+                 (("soname = ctypes.util.find_library.*xcb.*")
+                  (string-append "soname = \"" libxcb "/lib/libxcb.so\"\n")))
                #t)))
          (add-after 'install 'install-doc
            (lambda* (#:key outputs #:allow-other-keys)
-- 
2.30.2
S
S
Stephen Paul Weber wrote on 18 Oct 2021 19:48
[PATCH 2/4] gnu: Add python-dbus-next.
(address . 51272@debbugs.gnu.org)(name . Stephen Paul Weber)(address . singpolyma@singpolyma.net)
20211018174833.90312-2-singpolyma@singpolyma.net
* gnu/packages/python-xyz.scm (python-debus-next): New variable.
---
gnu/packages/python-xyz.scm | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)

Toggle diff (38 lines)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 6db446efac..4135812f11 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -8839,6 +8839,31 @@ implementation of D-Bus.")
                               (package-inputs python-dbus)
                               equal?)))))
 
+(define-public python-dbus-next
+  (package
+    (name "python-dbus-next")
+    (version "0.2.3")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/altdesktop/python-dbus-next")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "1ahaz52kny1p9xxv6phvk4iq56rg8li390wywlxf2yslaij1188h"))))
+    (build-system python-build-system)
+    (native-inputs
+      `(("python-pytest" ,python-pytest)))
+    (home-page "https://github.com/altdesktop/python-dbus-next")
+    (synopsis "Zero-dependency DBus library for Python with asyncio support")
+    (description
+      "Python library for DBus that aims to be a fully featured high level
+library primarily geared towards integration of applications into desktop and
+mobile environments.")
+    (license license:expat)))
+
 (define-public python-notify2
   (package
     (name "python-notify2")
-- 
2.30.2
S
S
Stephen Paul Weber wrote on 18 Oct 2021 19:48
[PATCH 3/4] gnu: Add python-iwlib.
(address . 51272@debbugs.gnu.org)(name . Stephen Paul Weber)(address . singpolyma@singpolyma.net)
20211018174833.90312-3-singpolyma@singpolyma.net
* gnu/packages/python-xyz.scm (python-iwlib): New variable.
---
gnu/packages/python-xyz.scm | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)

Toggle diff (29 lines)
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 4135812f11..238e6d2b26 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -27467,3 +27467,22 @@ and powerful way to handle real-world data, featuring:
      "This package provides the @code{python-box} Python module.
 It implements advanced Python dictionaries with dot notation access.")
     (license license:expat)))
+
+(define-public python-iwlib
+  (package
+    (name "python-iwlib")
+    (version "1.7.0")
+    (source
+      (origin
+        (method url-fetch)
+        (uri (pypi-uri "iwlib" version))
+        (sha256
+          (base32 "18bd35wn7zclalpqbry42pf7bjrdggxkkw58mc0k1vkhg9czc1d8"))))
+    (build-system python-build-system)
+    (inputs
+      `(("wireless-tools" ,wireless-tools)))
+    (propagated-inputs `(("python-cffi" ,python-cffi)))
+    (home-page "https://github.com/nhoad/python-iwlib")
+    (synopsis "Python module to interface with iwlib")
+    (description "An interface to iw wireless tools.")
+    (license license:gpl2)))
-- 
2.30.2
S
S
Stephen Paul Weber wrote on 18 Oct 2021 19:48
[PATCH 4/4] gnu: Add qtile.
(address . 51272@debbugs.gnu.org)(name . Stephen Paul Weber)(address . singpolyma@singpolyma.net)
20211018174833.90312-4-singpolyma@singpolyma.net
* gnu/packages/wm.scm (qtile): New variable.
---
gnu/packages/wm.scm | 59 +++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 59 insertions(+)

Toggle diff (99 lines)
diff --git a/gnu/packages/wm.scm b/gnu/packages/wm.scm
index 891a7960d6..95d34e2a84 100644
--- a/gnu/packages/wm.scm
+++ b/gnu/packages/wm.scm
@@ -83,6 +83,7 @@
   #:use-module (gnu packages bison)
   #:use-module (gnu packages build-tools) ;for meson-0.55
   #:use-module (gnu packages calendar)
+  #:use-module (gnu packages check)
   #:use-module (gnu packages datastructures)
   #:use-module (gnu packages docbook)
   #:use-module (gnu packages documentation)
@@ -101,6 +102,7 @@
   #:use-module (gnu packages image)
   #:use-module (gnu packages imagemagick)
   #:use-module (gnu packages libevent)
+  #:use-module (gnu packages libffi)
   #:use-module (gnu packages linux)
   #:use-module (gnu packages lisp-xyz)
   #:use-module (gnu packages logging)
@@ -115,12 +117,15 @@
   #:use-module (gnu packages pretty-print)
   #:use-module (gnu packages pulseaudio)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages python-crypto)
+  #:use-module (gnu packages python-xyz)
   #:use-module (gnu packages readline)
   #:use-module (gnu packages serialization)
   #:use-module (gnu packages sphinx)
   #:use-module (gnu packages suckless)
   #:use-module (gnu packages texinfo)
   #:use-module (gnu packages textutils)
+  #:use-module (gnu packages time)
   #:use-module (gnu packages video)
   #:use-module (gnu packages web)
   #:use-module (gnu packages xdisorg)
@@ -542,6 +547,60 @@ subscribe to events.")
 (define-public python2-i3-py
   (package-with-python2 python-i3-py))
 
+(define-public qtile
+  (package
+    (name "qtile")
+    (version "0.18.1")
+    (source
+      (origin
+        (method url-fetch)
+        (uri (pypi-uri "qtile" version))
+        (sha256
+          (base32 "14hb26xkza7brvkd4276j60mxd3zsas72ih6y0cq3j060izm1865"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:tests? #f ; Tests require Xvfb and writable temp/cache space
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch-paths
+           (lambda* (#:key inputs #:allow-other-keys)
+             (substitute* "libqtile/pangocffi.py"
+               (("^gobject = ffi.dlopen.*")
+                 (string-append "gobject = ffi.dlopen(\""
+                  (assoc-ref inputs "glib") "/lib/libgobject-2.0.so.0\")\n"))
+                (("^pango = ffi.dlopen.*")
+                 (string-append "pango = ffi.dlopen(\""
+                  (assoc-ref inputs "pango") "/lib/libpango-1.0.so.0\")\n"))
+                (("^pangocairo = ffi.dlopen.*")
+                 (string-append "pangocairo = ffi.dlopen(\""
+                  (assoc-ref inputs "pango") "/lib/libpangocairo-1.0.so.0\")\n"))))))))
+    (inputs
+      `(("glib" ,glib)
+        ("pango" ,pango)
+        ("pulseaudio" ,pulseaudio)))
+    (propagated-inputs
+      `(("python-cairocffi" ,python-cairocffi)
+        ("python-cffi" ,python-cffi)
+        ("python-dateutil" ,python-dateutil)
+        ("python-dbus-next" ,python-dbus-next)
+        ("python-iwlib" ,python-iwlib)
+        ("python-keyring" ,python-keyring)
+        ("python-mpd2" ,python-mpd2)
+        ("python-pyxdg" ,python-pyxdg)
+        ("python-xcffib" ,python-xcffib)))
+    (native-inputs
+      `(("pkg-config" ,pkg-config)
+        ("python-flake8" ,python-flake8)
+        ("python-pep8-naming" ,python-pep8-naming)
+        ("python-psutil" ,python-psutil)
+        ("python-pytest-cov" ,python-pytest-cov)
+        ("python-setuptools-scm" ,python-setuptools-scm)))
+    (home-page "http://qtile.org")
+    (synopsis "Hackable tiling window manager written and configured in Python")
+    (description "Qtile is simple, small, and extensible.  It's easy to write
+your own layouts, widgets, and built-in commands.")
+    (license license:expat)))
+
 (define-public quickswitch-i3
   (let ((commit "ed692b1e8f43b95bd907ced26238ce8ccb2ed28f")
         (revision "1")) ; Guix package revision
-- 
2.30.2
L
L
Ludovic Courtès wrote on 23 Nov 2021 09:59
Re: bug#51272: Package qtile
(name . Stephen Paul Weber)(address . singpolyma@singpolyma.net)(address . 51272-done@debbugs.gnu.org)
871r37l02a.fsf_-_@gnu.org
Hi Stephen,

Stephen Paul Weber <singpolyma@singpolyma.net> skribis:

Toggle quote (4 lines)
> Required for qtile.
>
> * gnu/packages/python-xyz.scm (python-xcffib): Upgrade to 0.11.1.

[...]

Toggle quote (2 lines)
> * gnu/packages/python-xyz.scm (python-debus-next): New variable.

[...]

Toggle quote (2 lines)
> * gnu/packages/python-xyz.scm (python-iwlib): New variable.

[...]

Toggle quote (2 lines)
> * gnu/packages/wm.scm (qtile): New variable.

I tweaked descriptions as per
and applied them.

Thanks,
Ludo’.
Closed
?
Your comment

This issue is archived.

To comment on this conversation send email to 51272@debbugs.gnu.org