gnu: linux-libre 5.19: Update to 5.19.14.
[jackhill/guix/guix.git] / gnu / packages / display-managers.scm
CommitLineData
4aa0891c 1;;; GNU Guix --- Functional package management for GNU
822efdff 2;;; Copyright © 2013 Joshua Grant <tadni@riseup.net>
b7bbb77c 3;;; Copyright © 2014, 2018, 2022 Ludovic Courtès <ludo@gnu.org>
06ed5982 4;;; Copyright © 2014 Andreas Enge <andreas@enge.fr>
4606f3a3
RW
5;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net>
6;;; Copyright © 2017 Sou Bunnbu <iyzsong@gmail.com>
58f0a19c 7;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com>
3b522de7 8;;; Copyright © 2017, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
373c5dfa 9;;; Copyright © 2020 L p R n d n <guix@lprndn.info>
21064f09 10;;; Copyright © 2020 Fredrik Salomonsson <plattfot@gmail.com>
c729a063 11;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
fc03a1a3 12;;; Copyright © 2021 Zheng Junjie <873216071@qq.com>
f8836774 13;;; Copyright © 2021 Efraim Flashner <efraim@flashner.co.il>
d124f94d 14;;; Copyright © 2021 Petr Hodina <phodina@protonmail.com>
26876b66 15;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
4aa0891c
JG
16;;;
17;;; This file is part of GNU Guix.
18;;;
19;;; GNU Guix is free software; you can redistribute it and/or modify it
20;;; under the terms of the GNU General Public License as published by
21;;; the Free Software Foundation; either version 3 of the License, or (at
22;;; your option) any later version.
23;;;
24;;; GNU Guix is distributed in the hope that it will be useful, but
25;;; WITHOUT ANY WARRANTY; without even the implied warranty of
26;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
27;;; GNU General Public License for more details.
28;;;
29;;; You should have received a copy of the GNU General Public License
30;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
31
5fd66a37 32(define-module (gnu packages display-managers)
99c53e22 33 #:use-module ((guix licenses) #:prefix license:)
4aa0891c
JG
34 #:use-module (guix packages)
35 #:use-module (guix download)
21064f09 36 #:use-module (guix git-download)
4aa0891c 37 #:use-module (guix build-system cmake)
2f57e34b 38 #:use-module (guix build-system qt)
4606f3a3 39 #:use-module (guix build-system gnu)
9376411f 40 #:use-module (guix build-system glib-or-gtk)
21064f09 41 #:use-module (guix build-system trivial)
4aa0891c 42 #:use-module (guix packages)
4606f3a3 43 #:use-module (guix utils)
f8836774 44 #:use-module (guix gexp)
16686a90 45 #:use-module (gnu packages)
26876b66 46 #:use-module (gnu packages autotools)
15791fa5 47 #:use-module (gnu packages admin)
26876b66 48 #:use-module (gnu packages base)
2227bb2a 49 #:use-module (gnu packages bash)
901385ca
DC
50 #:use-module (gnu packages fontutils)
51 #:use-module (gnu packages freedesktop)
4aa0891c 52 #:use-module (gnu packages gl)
901385ca 53 #:use-module (gnu packages glib)
4606f3a3
RW
54 #:use-module (gnu packages gnome)
55 #:use-module (gnu packages gnupg)
c0326ebc 56 #:use-module (gnu packages gtk)
0d23e9cd 57 #:use-module (gnu packages guile)
e55354b8 58 #:use-module (gnu packages image)
901385ca
DC
59 #:use-module (gnu packages kde-frameworks)
60 #:use-module (gnu packages linux)
4aa0891c 61 #:use-module (gnu packages pkg-config)
4606f3a3 62 #:use-module (gnu packages python)
901385ca
DC
63 #:use-module (gnu packages qt)
64 #:use-module (gnu packages xdisorg)
c0326ebc 65 #:use-module (gnu packages xfce)
901385ca
DC
66 #:use-module (gnu packages xorg))
67
15791fa5
DC
68(define-public sddm
69 (package
70 (name "sddm")
c729a063 71 (version "0.19.0")
15791fa5
DC
72 (source (origin
73 (method url-fetch)
74 (uri (string-append
75 "https://github.com/sddm/sddm"
76 "/releases/download/v" version "/"
bd6d0eba 77 "sddm-" version ".tar.xz"))
15791fa5
DC
78 (sha256
79 (base32
c729a063 80 "0hcdysw8ibr66vk8i7v56l0v5ijvhlq67v4460mc2xf2910g2m72"))))
2f57e34b 81 (build-system qt-build-system)
15791fa5 82 (native-inputs
eef8e2ec 83 (list extra-cmake-modules pkg-config qttools-5))
15791fa5 84 (inputs
8394619b
LC
85 (list elogind
86 glib
87 libxcb
88 libxkbcommon
89 linux-pam
90 qtbase-5
735d340a 91 qtdeclarative-5
8394619b
LC
92 ;; Some user-defined themes use QtQuick components internally. Adding
93 ;; QtQuick & co. here; they end up in QML2_IMPORT_PATH thanks to
94 ;; 'wrap-qt-program'.
95 qtgraphicaleffects
65e5e85d 96 qtquickcontrols-5
1130fc59 97 qtquickcontrols2-5
1ef04fb2 98 qtsvg-5
8394619b
LC
99 shadow
100 wayland))
15791fa5
DC
101 (arguments
102 `(#:configure-flags
f8836774
EF
103 ,#~(list
104 ;; This option currently does nothing, but will presumably be enabled
105 ;; if/when <https://github.com/sddm/sddm/pull/616> is merged.
106 "-DENABLE_WAYLAND=ON"
107 "-DENABLE_PAM=ON"
108 ;; Both flags are required for elogind support.
109 "-DNO_SYSTEMD=ON" "-DUSE_ELOGIND=ON"
110 "-DCONFIG_FILE=/etc/sddm.conf"
111 ;; Set path to /etc/login.defs.
112 ;; An alternative would be to use -DUID_MIN and -DUID_MAX.
113 (string-append "-DLOGIN_DEFS_PATH="
3081fc68 114 #$(this-package-input "shadow")
f8836774
EF
115 "/etc/login.defs")
116 (string-append "-DQT_IMPORTS_DIR="
117 #$output "/lib/qt5/qml")
118 (string-append "-DCMAKE_INSTALL_SYSCONFDIR="
119 #$output "/etc"))
15791fa5 120 #:phases
214bfb2c 121 (modify-phases %standard-phases
fa9f5222
MB
122 (add-after 'unpack 'embed-loginctl-reference
123 (lambda _
124 (substitute* "CMakeLists.txt"
125 (("/usr/bin/loginctl") (which "loginctl")))
2f57e34b 126 #t)))))
15791fa5
DC
127 (synopsis "QML based X11 and Wayland display manager")
128 (description "SDDM is a display manager for X11 and Wayland aiming to be
129fast, simple and beautiful. SDDM is themeable and puts no restrictions on the
130user interface design. It uses QtQuick which gives the designer the ability to
131create smooth, animated user interfaces.")
132 (home-page "https://github.com/sddm/sddm")
133 ;; QML files are MIT licensed and images are CC BY 3.0.
134 (license (list license:gpl2+ license:expat license:cc-by3.0))))
135
21064f09
FS
136(define-public guix-simplyblack-sddm-theme
137 (package
138 (name "guix-simplyblack-sddm-theme")
139 (version "0.1")
140 (source (origin
141 (method git-fetch)
142 (uri (git-reference
143 (url "https://github.com/plattfot/guix-simplyblack-sddm")
144 (commit version)))
145 (file-name (git-file-name name version))
146 (sha256
147 (base32 "1fwny6b0xpjs8ad2b16pyxd27gf0sr0nillmhc2h5k0q7dva21vi"))))
148 (build-system trivial-build-system)
149 (arguments
150 `(#:modules ((guix build utils))
151 #:builder
152 (begin
153 (use-modules (guix build utils))
154 (let* ((out (assoc-ref %outputs "out"))
155 (sddm-themes (string-append out "/share/sddm/themes")))
156 (mkdir-p sddm-themes)
157 (copy-recursively (assoc-ref %build-inputs "source")
158 (string-append sddm-themes "/guix-simplyblack-sddm"))))))
159 (home-page "https://github.com/plattfot/guix-simplyblack-sddm")
160 (synopsis "Guix based theme for SDDM")
161 (description
162 "This package provides a simple theme for SDDM, black background with
163Guix's logo. Based on Arch linux's archlinux-simplyblack theme.")
164 ;; Theme under cc-by-sa3.0, guix logo under license:cc-by-sa4.0
165 (license (list license:cc-by-sa3.0 license:cc-by-sa4.0))))
166
fc03a1a3
ZJ
167(define-public chili-sddm-theme
168 (package
169 (name "chili-sddm-theme")
170 (version "0.1.5")
171 (source (origin
172 (method git-fetch)
173 (uri (git-reference
174 (url "https://github.com/MarianArlt/sddm-chili")
175 (commit version)))
176 (file-name (git-file-name name version))
177 (sha256
178 (base32
179 "036fxsa7m8ymmp3p40z671z163y6fcsa9a641lrxdrw225ssq5f3"))))
180 (build-system trivial-build-system)
181 (arguments
182 `(#:modules ((guix build utils))
183 #:builder
184 (begin
185 (use-modules (guix build utils))
186 (let* ((out (assoc-ref %outputs "out"))
187 (sddm-themes (string-append out "/share/sddm/themes")))
188 (mkdir-p sddm-themes)
189 (copy-recursively (assoc-ref %build-inputs "source")
190 (string-append sddm-themes "/chili"))))))
191 (home-page "https://github.com/MarianArlt/sddm-chili")
192 (synopsis "Chili theme for SDDM")
193 (description "Chili reduces all the clutter and leaves you with a clean,
194easy to use, login interface with a modern yet classy touch.")
195 (license license:gpl3+)))
196
d124f94d
PH
197(define-public sugar-dark-sddm-theme
198 (package
199 (name "sugar-dark-sddm-theme")
200 (version "1.2")
201 (source (origin
202 (method git-fetch)
203 (uri (git-reference
204 (url "https://github.com/MarianArlt/sddm-sugar-dark")
205 (commit (string-append "v" version))))
206 (file-name (git-file-name name version))
207 (sha256
208 (base32
209 "0gx0am7vq1ywaw2rm1p015x90b75ccqxnb1sz3wy8yjl27v82yhb"))))
210 (build-system trivial-build-system)
211 (arguments
212 `(#:modules ((guix build utils))
213 #:builder
214 (begin
215 (use-modules (guix build utils))
216 (let* ((out (assoc-ref %outputs "out"))
217 (sddm-themes (string-append out "/share/sddm/themes")))
218 (mkdir-p sddm-themes)
219 (copy-recursively (assoc-ref %build-inputs "source")
220 (string-append sddm-themes "/chili"))))))
221 (home-page "https://github.com/MarianArlt/sddm-sugar-dark")
222 (synopsis "Sugar dark theme for SDDM")
223 (description "Sugar is extremely customizable and so sweet it will
224probably cause you diabetes just from looking at it. Sweeten the login
225experience for your users, your family and yourself")
226 (license license:gpl3+)))
227
b850fe6e
PH
228(define-public sugar-light-sddm-theme
229 (package
230 (name "sugar-light-sddm-theme")
231 (version "1.0")
232 (source (origin
233 (method git-fetch)
234 (uri (git-reference
235 (url "https://github.com/MarianArlt/sddm-sugar-light")
236 (commit (string-append "v" version))))
237 (file-name (git-file-name name version))
238 (sha256
239 (base32
240 "1sfd5bi5jcfz3hmvvr3smalywixa70g5j96qgx1220mp6rqf886k"))))
241 (build-system trivial-build-system)
242 (arguments
243 `(#:modules ((guix build utils))
244 #:builder
245 (begin
246 (use-modules (guix build utils))
247 (let* ((out (assoc-ref %outputs "out"))
248 (sddm-themes (string-append out "/share/sddm/themes")))
249 (mkdir-p sddm-themes)
250 (copy-recursively (assoc-ref %build-inputs "source")
251 (string-append sddm-themes "/chili"))))))
252 (home-page "https://github.com/MarianArlt/sddm-sugar-light")
253 (synopsis "Sugar light theme for SDDM")
254 (description "Sugar is extremely customizable and so sweet it will
255probably cause you diabetes just from looking at it. Sweeten the login
256experience for your users, your family and yourself")
257 (license license:gpl3+)))
258
4606f3a3 259(define-public lightdm
a8f53d54
MC
260 (package
261 (name "lightdm")
262 (version "1.32.0")
263 (source (origin
264 (method git-fetch)
265 (uri (git-reference
266 (url "https://github.com/canonical/lightdm")
267 (commit version)))
268 (file-name (git-file-name name version))
269 (sha256
270 (base32
da3c784c 271 "1wr60c946p8jz9kb8zi4cd8d4mkcy7infbvlfzwajiglc22nblxn"))
a4fd1840 272 (patches (search-patches "lightdm-arguments-ordering.patch"
b096b939
MC
273 "lightdm-vncserver-check.patch"
274 "lightdm-vnc-color-depth.patch"))))
a8f53d54
MC
275 (build-system gnu-build-system)
276 (arguments
277 '(#:parallel-tests? #f ; fails when run in parallel
278 #:configure-flags
279 (list "--localstatedir=/var"
280 "--enable-gtk-doc"
281 ;; Otherwise the test suite fails on such a warning.
282 "CFLAGS=-Wno-error=missing-prototypes")
283 #:phases
284 (modify-phases %standard-phases
285 (add-after 'unpack 'fix-paths
286 (lambda* (#:key inputs #:allow-other-keys)
287 (substitute* "src/shared-data-manager.c"
288 (("/bin/rm")
289 (search-input-file inputs "bin/rm")))
290 (substitute* '("data/users.conf"
291 "common/user-list.c")
292 (("/bin/false")
293 (search-input-file inputs "bin/false"))
294 (("/usr/sbin/nologin")
295 (search-input-file inputs "sbin/nologin")))
296 (substitute* "src/seat.c"
297 (("/bin/sh")
298 (search-input-file inputs "bin/sh")))))
299 (add-before 'check 'pre-check
300 (lambda _
301 (wrap-program "tests/src/test-python-greeter"
302 `("GUIX_PYTHONPATH" ":" prefix (,(getenv "GUIX_PYTHONPATH")))
303 `("GI_TYPELIB_PATH" ":" prefix (,(getenv "GI_TYPELIB_PATH"))))
304 ;; Avoid printing locale warnings, which trip up the text
305 ;; matching tests.
306 (unsetenv "LC_ALL"))))))
307 (inputs
308 (list audit
da3c784c
MC
309 bash-minimal ;for cross-compilation
310 coreutils-minimal ;ditto
a8f53d54
MC
311 linux-pam
312 shadow ;for sbin/nologin
313 libgcrypt
314 libxcb
315 libxdmcp))
316 (native-inputs
317 (list accountsservice
318 autoconf
319 automake
320 gobject-introspection
321 gtk-doc
322 pkg-config
323 itstool
324 intltool
325 libtool
326 vala ;for Vala bindings
327 ;; For tests
328 dbus
329 python-wrapper
330 python-pygobject
331 which
332 yelp-tools))
333 ;; Required by liblightdm-gobject-1.pc.
334 (propagated-inputs
335 (list glib libx11 libxklavier))
336 (home-page "https://www.freedesktop.org/wiki/Software/LightDM/")
337 (synopsis "Lightweight display manager")
338 (description "The Light Display Manager (LightDM) is a cross-desktop
4606f3a3 339display manager which supports different greeters.")
a8f53d54 340 (license license:gpl3+)))
4606f3a3 341
c0326ebc
SB
342(define-public lightdm-gtk-greeter
343 (package
344 (name "lightdm-gtk-greeter")
c5962a72 345 (version "2.0.8")
c0326ebc
SB
346 (source (origin
347 (method url-fetch)
348 (uri (string-append
c5962a72
DGC
349 "https://github.com/xubuntu/lightdm-gtk-greeter"
350 "/releases/download/lightdm-gtk-greeter-" version "/"
351 "lightdm-gtk-greeter-" version ".tar.gz"))
c0326ebc
SB
352 (sha256
353 (base32
c5962a72 354 "04q62mvr97l9gv8h37hfarygqc7p0498ig7xclcg4kxkqw0b7yxy"))))
9376411f 355 (build-system glib-or-gtk-build-system)
4e639698 356 (arguments
90b705ea
MC
357 (list
358 #:configure-flags
af2d160c 359 #~(list "--disable-indicator-services-command" ;requires upstart
0d23e9cd
MC
360 ;; Put the binary under /bin rather than /sbin, so that it gets
361 ;; wrapped by the glib-or-gtk-wrap phase.
362 (string-append "--sbindir=" #$output "/bin")
d0046bc1 363 (string-append "--with-libxklavier")
af2d160c 364 (string-append "--enable-at-spi-command="
90b705ea 365 (search-input-file
0e76781d
MC
366 %build-inputs "libexec/at-spi-bus-launcher")
367 " --launch-immediately"))
90b705ea
MC
368 #:phases
369 #~(modify-phases %standard-phases
20c8fb04
MC
370 (add-after 'unpack 'customize-default-config-path
371 (lambda _
372 (substitute* "src/Makefile.in"
373 ;; Have the default config directory sourced from
374 ;; /etc/lightdm/lightdm-gtk-greeter.conf, which is where the
375 ;; lightdm service writes it.
376 (("\\$\\(sysconfdir)/lightdm/lightdm-gtk-greeter.conf")
377 "/etc/lightdm/lightdm-gtk-greeter.conf"))))
90b705ea
MC
378 (add-after 'install 'fix-.desktop-file
379 (lambda* (#:key outputs #:allow-other-keys)
380 (substitute* (search-input-file
381 outputs
382 "share/xgreeters/lightdm-gtk-greeter.desktop")
383 (("Exec=lightdm-gtk-greeter")
384 (string-append "Exec="
385 (search-input-file
0d23e9cd
MC
386 outputs "bin/lightdm-gtk-greeter"))))))
387 (add-after 'glib-or-gtk-wrap 'custom-wrap
388 (lambda* (#:key outputs #:allow-other-keys)
389 (wrap-script (search-input-file
390 outputs "bin/lightdm-gtk-greeter")
391 ;; Wrap GDK_PIXBUF_MODULE_FILE, so that the SVG loader is
392 ;; available at all times even outside of profiles, such as
393 ;; when used in the lightdm-service-type. Otherwise, it
394 ;; wouldn't be able to display its own icons.
395 `("GDK_PIXBUF_MODULE_FILE" =
396 (,(search-input-file
397 outputs
398 "lib/gdk-pixbuf-2.0/2.10.0/loaders.cache")))
399 `("XDG_DATA_DIRS" ":" prefix
400 (,(string-append "/run/current-system/profile/share:"
401 (getenv "XDG_DATA_DIRS"))))
402 '("XCURSOR_PATH" ":" prefix
403 ("/run/current-system/profile/share/icons"))))))))
c0326ebc 404 (native-inputs
0d23e9cd
MC
405 (list exo
406 intltool
407 pkg-config
408 xfce4-dev-tools))
c0326ebc 409 (inputs
9376411f
MC
410 (list at-spi2-core
411 bash-minimal ;for wrap-program
412 gtk+
413 guile-3.0
414 librsvg
d0046bc1 415 libxklavier
90b705ea 416 lightdm
9376411f 417 shared-mime-info))
c0326ebc 418 (synopsis "GTK+ greeter for LightDM")
c5962a72 419 (home-page "https://github.com/xubuntu/lightdm-gtk-greeter")
c0326ebc
SB
420 (description "This package provides a LightDM greeter implementation using
421GTK+, lets you select a desktop session and log in to it.")
422 (license license:gpl3+)))
423
4aa0891c
JG
424(define-public slim
425 (package
426 (name "slim")
16686a90 427 (version "1.3.6")
4aa0891c
JG
428 (source (origin
429 (method url-fetch)
d8c19441
LC
430 ;; Used to be available from download.berlios.de.
431 (uri (string-append
0f971a04 432 "mirror://sourceforge/slim.berlios/slim-"
d8c19441 433 version ".tar.gz"))
4aa0891c 434 (sha256
16686a90 435 (base32 "1pqhk22jb4aja4hkrm7rjgbgzjyh7i4zswdgf5nw862l2znzxpi1"))
fc1adab1 436 (patches (search-patches "slim-config.patch"
0b71c15c 437 "slim-reset.patch"
17d50dfd 438 "slim-login.patch"
fc1adab1 439 "slim-session.patch"
6426a8fb
DNB
440 "slim-sigusr1.patch"
441 "slim-display.patch"))))
4aa0891c
JG
442 (build-system cmake-build-system)
443 (inputs `(("linux-pam" ,linux-pam)
444 ("libpng" ,libpng)
4bd428a7 445 ("libjpeg" ,libjpeg-turbo)
4aa0891c
JG
446 ("freeglut" ,freeglut)
447 ("libxrandr" ,libxrandr)
448 ("libxrender" ,libxrender)
449 ("freetype" ,freetype)
450 ("fontconfig" ,fontconfig)
c4c4cc05 451 ("libx11" ,libx11)
4aa0891c
JG
452 ("libxft" ,libxft)
453 ("libxmu" ,libxmu)
454 ("xauth" ,xauth)))
c4c4cc05 455 (native-inputs
8394619b 456 (list pkg-config))
4aa0891c 457 (arguments
dc1d3cde
KK
458 '(#:phases
459 (modify-phases %standard-phases
460 (add-before 'configure 'set-new-etc-location
461 (lambda _
462 (substitute* "CMakeLists.txt"
463 (("/etc")
464 (string-append (assoc-ref %outputs "out") "/etc"))
465 (("install.*systemd.*")
466 ;; The build system's logic here is: if "Linux", then
467 ;; "systemd". Strip that.
468 ""))
469 #t)))
06ed5982
AE
470 #:configure-flags '("-DUSE_PAM=yes"
471 "-DUSE_CONSOLEKIT=no")
4aa0891c 472 #:tests? #f))
d8c19441
LC
473
474 ;; This used to be at <http://slim.berlios.de/>.
3b3b60d0 475 (home-page "https://sourceforge.net/projects/slim.berlios/")
ae133b89 476 (synopsis "Desktop-independent graphical login manager for X11")
4aa0891c
JG
477 (description
478 "SLiM is a Desktop-independent graphical login manager for X11, derived
ae133b89
EB
479from Login.app. It aims to be light and simple, although completely
480configurable through themes and an option file; is suitable for machines on
481which remote login functionalities are not needed.
4aa0891c 482
ae133b89
EB
483Features included: PNG and XFT support for alpha transparency and antialiased
484fonts, External themes support, Configurable runtime options: X server --
485login / shutdown / reboot commands, Single (GDM-like) or double (XDM-like)
486input control, Can load predefined user at startup, Configurable welcome /
e881752c 487shutdown messages, Random theme selection.")
99c53e22 488 (license license:gpl2)))