1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
3 ;;; Copyright © 2015 Siniša Biđin <sinisa@bidin.eu>
4 ;;; Copyright © 2015, 2016 Eric Bavier <bavier@member.fsf.org>
5 ;;; Copyright © 2015 xd1le <elisp.vim@gmail.com>
6 ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
7 ;;; Copyright © 2016 Danny Milosavljevic <dannym@scratchpost.org>
8 ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il>
9 ;;; Copyright © 2016 Al McElrath <hello@yrns.org>
10 ;;; Copyright © 2016 Carlo Zancanaro <carlo@zancanaro.id.au>
11 ;;; Copyright © 2016, 2017, 2018 Ludovic Courtès <ludo@gnu.org>
12 ;;; Copyright © 2016, 2017, 2018 ng0 <ng0@crash.cx>
13 ;;; Copyright © 2016 doncatnip <gnopap@gmail.com>
14 ;;; Copyright © 2016 Ivan Vilata i Balaguer <ivan@selidor.net>
15 ;;; Copyright © 2017 Mekeor Melire <mekeor.melire@gmail.com>
16 ;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com>
17 ;;; Copyright © 2017 Oleg Pykhalov <go.wigust@gmail.com>
18 ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
20 ;;; This file is part of GNU Guix.
22 ;;; GNU Guix is free software; you can redistribute it and/or modify it
23 ;;; under the terms of the GNU General Public License as published by
24 ;;; the Free Software Foundation; either version 3 of the License, or (at
25 ;;; your option) any later version.
27 ;;; GNU Guix is distributed in the hope that it will be useful, but
28 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
29 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 ;;; GNU General Public License for more details.
32 ;;; You should have received a copy of the GNU General Public License
33 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
35 (define-module (gnu packages wm)
36 #:use-module ((guix licenses) #:prefix license:)
37 #:use-module (guix packages)
38 #:use-module (gnu packages)
39 #:use-module (gnu packages linux)
40 #:use-module (guix build-system cmake)
41 #:use-module (guix build-system gnu)
42 #:use-module (guix build-system haskell)
43 #:use-module (guix build-system perl)
44 #:use-module (guix build-system python)
45 #:use-module (gnu packages haskell)
46 #:use-module (gnu packages haskell-check)
47 #:use-module (gnu packages haskell-web)
48 #:use-module (gnu packages autotools)
49 #:use-module (gnu packages bison)
50 #:use-module (gnu packages gawk)
51 #:use-module (gnu packages base)
52 #:use-module (gnu packages pkg-config)
53 #:use-module (gnu packages perl)
54 #:use-module (gnu packages pulseaudio)
55 #:use-module (gnu packages xorg)
56 #:use-module (gnu packages xdisorg)
57 #:use-module (gnu packages documentation)
58 #:use-module (gnu packages xml)
59 #:use-module (gnu packages m4)
60 #:use-module (gnu packages docbook)
61 #:use-module (gnu packages image)
62 #:use-module (gnu packages pcre)
63 #:use-module (gnu packages python)
64 #:use-module (gnu packages gtk)
65 #:use-module (gnu packages libevent)
66 #:use-module (gnu packages fribidi)
67 #:use-module (gnu packages maths)
68 #:use-module (gnu packages web)
69 #:use-module (gnu packages fontutils)
70 #:use-module (gnu packages freedesktop)
71 #:use-module (gnu packages glib)
72 #:use-module (gnu packages gperf)
73 #:use-module (gnu packages imagemagick)
74 #:use-module (gnu packages lua)
75 #:use-module (gnu packages linux)
76 #:use-module (gnu packages suckless)
77 #:use-module (guix download)
78 #:use-module (guix git-download))
80 (define-public libconfuse
86 (uri (string-append "https://github.com/martinh/libconfuse/"
87 "releases/download/v" version
88 "/confuse-" version ".tar.xz"))
91 "0pnjmlj9i0alp407qd7c0vq83sz7gpsjrbdgpcn4xvzjp9r35ii3"))))
92 (build-system gnu-build-system)
93 (home-page "https://github.com/martinh/libconfuse")
94 (synopsis "Configuration file parser library")
95 (description "libconfuse is a configuration file parser library. It
96 supports sections and (lists of) values (strings, integers, floats, booleans
97 or other sections), as well as some other features (such as
98 single/double-quoted strings, environment variable expansion, functions and
99 nested include statements).")
100 (license license:isc)))
108 (file-name (string-append name "-" version ".tar.gz"))
111 "https://github.com/baskerville/bspwm/archive/"
115 "17dwj7w16cdj7g4s2y2f96lgj5msq1s4543dnfa3rijlazzy6mmk"))))
116 (build-system gnu-build-system)
119 ("libxinerama" ,libxinerama)
121 ("xcb-util" ,xcb-util)
122 ("xcb-util-keysyms" ,xcb-util-keysyms)
123 ("xcb-util-wm" ,xcb-util-wm)))
125 '(#:phases (modify-phases %standard-phases (delete 'configure))
126 #:tests? #f ; no check target
127 #:make-flags (list "CC=gcc"
128 (string-append "PREFIX=" %output))))
129 (home-page "https://github.com/baskerville/bspwm")
130 (synopsis "Tiling window manager based on binary space partitioning")
131 (description "bspwm is a tiling window manager that represents windows as
132 the leaves of a full binary tree.")
133 (license license:bsd-2)))
135 (define-public i3status
141 (uri (string-append "https://i3wm.org/i3status/i3status-"
145 "0pwcy599fw8by1a1sf91crkqba7679qhvhbacpmhis8c1xrpxnwq"))))
146 (build-system gnu-build-system)
148 `(#:make-flags (list "CC=gcc" (string-append "PREFIX=" %output))
150 (modify-phases %standard-phases
152 #:tests? #f)) ; no test suite
154 `(("openlibm" ,openlibm)
155 ("libconfuse" ,libconfuse)
157 ("alsa-lib" ,alsa-lib)
158 ("pulseaudio" ,pulseaudio)
161 ("asciidoc" ,asciidoc)))
163 `(("pkg-config" ,pkg-config)))
164 (home-page "https://i3wm.org/i3status/")
165 (synopsis "Status bar for i3bar, dzen2, xmobar or similar programs")
166 (description "i3status is a small program for generating a status bar for
167 i3bar, dzen2, xmobar or similar programs. It is designed to be very efficient
168 by issuing a very small number of system calls, as one generally wants to
169 update such a status line every second. This ensures that even under high
170 load, your status bar is updated correctly. Also, it saves a bit of energy by
171 not hogging your CPU as much as spawning the corresponding amount of shell
173 (license license:bsd-3)))
181 (uri (string-append "https://i3wm.org/downloads/i3-"
185 "09jk70hsdxab24lqvj2f30ijrkbv3f6q9xi5dcsax1dw3x6m4z91"))))
186 (build-system gnu-build-system)
190 (string-append "PREFIX=" %output)
191 ;; This works around the following error:
192 ;; 'error: ‘for’ loop initial declarations are only allowed in C99
195 ;; The build system tries to build in a separate directory, but that
196 ;; seems to be unnecessary.
197 #:configure-flags '("--disable-builddir")
198 ;; The test suite appears to require the unpackaged Perl module AnyEvent.
202 ("xcb-util" ,xcb-util)
203 ("xcb-util-cursor" ,xcb-util-cursor)
204 ("xcb-util-keysyms" ,xcb-util-keysyms)
205 ("xcb-util-wm" ,xcb-util-wm)
206 ("xcb-util-xrm" ,xcb-util-xrm)
207 ("libxkbcommon" ,libxkbcommon)
210 ("asciidoc" ,asciidoc)
212 ("perl-pod-simple" ,perl-pod-simple)
215 ("startup-notification" ,startup-notification)
221 ("pkg-config" ,pkg-config)
222 ;; For building the documentation.
224 ("docbook-xsl" ,docbook-xsl)))
225 (home-page "https://i3wm.org/")
226 (synopsis "Improved tiling window manager")
227 (description "A tiling window manager, completely written
228 from scratch. i3 is primarily targeted at advanced users and
230 (license license:bsd-3)))
232 (define-public perl-anyevent-i3
234 (name "perl-anyevent-i3")
238 (uri (string-append "mirror://cpan/authors/id/M/MS/MSTPLBG/"
239 "AnyEvent-I3-" version ".tar.gz"))
242 "0qvd9bq16jyy7v3ma82qcnvz9j503bw0mh7h55gkjf7ir62ck0jk"))))
243 (build-system perl-build-system)
245 `(("perl-anyevent" ,perl-anyevent)
246 ("perl-json-xs" ,perl-json-xs)))
247 (home-page "http://search.cpan.org/dist/AnyEvent-I3")
249 "Communicate with the i3 window manager through perl")
251 "This module connects to the i3 window manager using the UNIX socket
252 based IPC interface it provides (if enabled in the configuration file).
253 You can then subscribe to events or send messages and receive their replies.")
254 ;; Can be used with either license.
255 (license (list license:gpl3+ license:perl-license))))
257 (define-public python-i3-py
259 (name "python-i3-py")
263 ;; The latest release is not tagged in Git nor has an entry in PyPi,
264 ;; but there is still a clear commit for it, and it's been the last one
268 (url "https://github.com/ziberna/i3-py.git")
269 (commit "27f88a616e9ecc340e7d041d3d00782f8a1964c1")))
272 "1nm719dc2xqlll7vj4c4m7mpjb27lpn3bg3c66gajvnrz2x1nmxs"))
273 (file-name (string-append name "-" version "-checkout"))))
274 (build-system python-build-system)
276 `(#:tests? #f ; no tests yet
277 #:phases (modify-phases %standard-phases
278 (add-after 'install 'install-doc
279 ;; Copy readme file to documentation directory.
280 (lambda* (#:key outputs #:allow-other-keys)
281 (let ((doc (string-append (assoc-ref outputs "out")
282 "/share/doc/" ,name)))
283 (install-file "README.md" doc)
284 ;; Avoid unspecified return value.
288 (home-page "https://github.com/ziberna/i3-py")
289 (synopsis "Python interface to the i3 window manager")
290 (description "This package allows you to interact from a Python program
291 with the i3 window manager via its IPC socket. It can send commands and other
292 kinds of messages to i3, select the affected containers, filter results and
293 subscribe to events.")
294 (license license:gpl3+)))
296 (define-public python2-i3-py
297 (package-with-python2 python-i3-py))
299 (define-public quickswitch-i3
300 (let ((commit "ed692b1e8f43b95bd907ced26238ce8ccb2ed28f")
301 (revision "1")) ; Guix package revision
303 (name "quickswitch-i3")
304 (version (string-append "2.2-" revision "."
305 (string-take commit 7)))
308 ;; The latest commit is a few years old and just a couple commits
309 ;; after the last tagged release, so we use that latest commit
310 ;; instead of the release.
313 (url "https://github.com/proxypoke/quickswitch-for-i3.git")
317 "0447077sama80jcdg5p64zjsvafmz5rbdrirhm1adcdjhkh6iqc5"))
318 (patches (search-patches "quickswitch-fix-dmenu-check.patch"))
319 (file-name (string-append name "-" version "-checkout"))))
320 (build-system python-build-system)
322 `(#:tests? #f ; no tests yet
323 #:phases (modify-phases %standard-phases
324 (add-after 'install 'install-doc
325 ;; Copy readme file to documentation directory.
326 (lambda* (#:key outputs #:allow-other-keys)
327 (let ((doc (string-append (assoc-ref outputs "out")
328 "/share/doc/" ,name)))
329 (install-file "README.rst" doc)
330 ;; Avoid unspecified return value.
333 `(("python-i3-py" ,python-i3-py)
335 (home-page "https://github.com/proxypoke/quickswitch-for-i3")
336 (synopsis "Quickly change to and locate windows in the i3 window manager")
338 "This utility for the i3 window manager allows you to quickly switch to
339 and locate windows on all your workspaces, using an interactive dmenu
341 (license (license:non-copyleft "http://www.wtfpl.net/txt/copying/")))))
343 (define-public i3lock-color
345 (name "i3lock-color")
350 (uri (string-append "https://github.com/PandorasFox/i3lock-color/"
351 "archive/" version ".tar.gz"))
352 (file-name (string-append name "-" version ".tar.gz"))
355 "119xvdm4r6irqk0mar80hx6s8ydw26y35h7712rd7nbg7pb7i053"))))
356 (build-system gnu-build-system)
358 `(#:tests? #f)) ;no tests included
360 `(("xcb-util-image" ,xcb-util-image)
361 ("xcb-util" ,xcb-util)
363 ("linux-pam" ,linux-pam)
364 ("libxkbcommon" ,libxkbcommon)
368 `(("pkg-config" ,pkg-config)
369 ("autoconf" ,autoconf)
370 ("automake" ,automake)))
371 (home-page "https://github.com/PandorasFox/i3lock-color")
372 (synopsis "Screen locker with color configuration support")
374 "i3lock-color is a simpler X11 screen locker derived from i3lock.
378 @item forking process, the locked screen is preserved when you suspend to RAM;
379 @item specify background color or image to be displayed in the lock screen;
380 @item many additional color options.
382 (license license:bsd-3)))
384 (define-public i3lock-fancy
386 (name "i3lock-fancy")
391 (uri (string-append "https://github.com/meskarune/i3lock-fancy/archive/"
393 (file-name (string-append name "-" version ".tar.gz"))
396 "020m7mnfq5cvir7p9v3hkb7cvb4cai33wppxl2zdwscwwjnchc5y"))))
397 (build-system gnu-build-system)
399 `(#:tests? #f ;No tests included
401 (modify-phases %standard-phases
403 (lambda* (#:key inputs outputs #:allow-other-keys)
404 (let* ((out (assoc-ref outputs "out"))
405 (icons (string-append out "/share/i3lock-fancy/icons/"))
406 (wmctrl (string-append (assoc-ref inputs "wmctrl")
408 (mconvert (string-append (assoc-ref inputs "imagemagick")
410 (mimport (string-append (assoc-ref inputs "imagemagick")
412 (awk (string-append (assoc-ref inputs "gawk")
416 (("$(which wmctrl)") wmctrl)
417 (("convert") mconvert)
418 (("shot=\\(import") (string-append "shot=\(" mimport))
419 (("awk -F") (string-append awk " -F"))
421 (("\\$scriptpath/icons/") icons))
425 (lambda* (#:key inputs outputs #:allow-other-keys)
426 (let* ((out (assoc-ref outputs "out"))
427 (bin (string-append out "/bin"))
428 (icons (string-append out "/share/i3lock-fancy/icons/")))
430 (install-file "lock" bin)
431 (rename-file (string-append bin "/lock")
432 (string-append bin "/i3lock-fancy"))
433 (copy-recursively "icons" icons)
436 `(("imagemagick" ,imagemagick)
439 (home-page "https://github.com/meskarune/i3lock-fancy")
440 (synopsis "Screen locker with screenshot function")
442 "@code{i3lock-fancy} is a Bash script that takes a screenshot of
443 the desktop, blurs the background and adds a lock icon and text.
444 It requires @code{i3lock-color} or @code{i3lock} and can optionally
445 be passed any screenshot util like @code{scrot}.
446 This screen locker can be used with any window manager or
447 desktop environment.")
448 (license license:expat)))
450 (define-public xmonad
454 (synopsis "Tiling window manager")
457 (uri (string-append "mirror://hackage/package/xmonad/"
458 name "-" version ".tar.gz"))
461 "1jh3lcs20qpna36fa5a0r174xqrsxhj10x1rm5vwf64zariipy7r"))))
462 (build-system haskell-build-system)
464 `(("ghc-extensible-exceptions" ,ghc-extensible-exceptions)
466 ("ghc-quickcheck" ,ghc-quickcheck)
467 ("ghc-setlocale" ,ghc-setlocale)
468 ("ghc-utf8-string" ,ghc-utf8-string)
469 ("ghc-directory" ,ghc-directory)
470 ("ghc-x11" ,ghc-x11)))
473 (modify-phases %standard-phases
475 'install 'install-xsession
477 (let* ((xsessions (string-append %output "/share/xsessions")))
479 (call-with-output-file
480 (string-append xsessions "/xmonad.desktop")
487 Type=Application~%" ,name ,synopsis %output)))))))))
488 (home-page "http://xmonad.org")
490 "Xmonad is a tiling window manager for X. Windows are arranged
491 automatically to tile the screen without gaps or overlap, maximising screen
492 use. All features of the window manager are accessible from the keyboard: a
493 mouse is strictly optional. Xmonad is written and extensible in Haskell.
494 Custom layout algorithms, and other extensions, may be written by the user in
495 config files. Layouts are applied dynamically, and different layouts may be
496 used on each workspace. Xinerama is fully supported, allowing windows to be
497 tiled on several screens.")
498 (license license:bsd-3)))
500 (define-public xmobar
506 (uri (string-append "mirror://hackage/package/xmobar/"
507 name "-" version ".tar.gz"))
510 "0382r4vzqkz76jlp2069rdbwf4gh1a22r9w4rkphcn5qflw0dlb6"))))
511 (build-system haskell-build-system)
513 `(("ghc-hinotify" ,ghc-hinotify)
514 ("ghc-http" ,ghc-http)
515 ("ghc-iwlib" ,ghc-iwlib)
516 ("ghc-parsec" ,ghc-parsec)
517 ("ghc-regex-compat" ,ghc-regex-compat)
519 ("ghc-x11-xft" ,ghc-x11-xft)
523 (list (string-append "--flags="
524 (string-join (list "with_inotify"
531 (home-page "http://xmobar.org")
532 (synopsis "Minimalistic text based status bar")
534 "@code{xmobar} is a lightweight, text-based, status bar written in
535 Haskell. It was originally designed to be used together with Xmonad, but it
536 is also usable with any other window manager. While xmobar is written in
537 Haskell, no knowledge of the language is required to install and use it.")
538 (license license:bsd-3)))
540 (define-public ghc-xmonad-contrib
542 (name "ghc-xmonad-contrib")
547 (uri (string-append "mirror://hackage/package/xmonad-contrib/"
548 "xmonad-contrib-" version ".tar.gz"))
551 "0vj72jhfng6y7hv5frx2v99jvl3jn9rbpk2j7xw9vydiwmzq4q57"))))
552 (build-system haskell-build-system)
554 `(("ghc-mtl" ,ghc-mtl)
555 ("ghc-old-time" ,ghc-old-time)
556 ("ghc-random" ,ghc-random)
557 ("ghc-utf8-string" ,ghc-utf8-string)
558 ("ghc-extensible-exceptions" ,ghc-extensible-exceptions)
560 ("ghc-x11-xft" ,ghc-x11-xft)
562 (home-page "http://xmonad.org")
563 (synopsis "Third party extensions for xmonad")
565 "Third party tiling algorithms, configurations, and scripts to Xmonad, a
566 tiling window manager for X.")
567 (license license:bsd-3)))
569 (define-public evilwm
576 (uri (string-append "http://www.6809.org.uk/evilwm/evilwm-"
580 "0ak0yajzk3v4dg5wmaghv6acf7v02a4iw8qxmq5yw5ard8lrqn3r"))
581 (patches (search-patches "evilwm-lost-focus-bug.patch"))))
582 (build-system gnu-build-system)
586 ("libxrandr" ,libxrandr)))
588 `(#:modules ((srfi srfi-26)
590 (guix build gnu-build-system))
591 #:make-flags (let ((inputs (map (cut assoc-ref %build-inputs <>)
592 '("libx11" "libxext" "libxrandr")))
593 (join (lambda (proc strs)
594 (string-join (map proc strs) " ")))
595 (dash-I (cut string-append "-I" <> "/include"))
596 (dash-L (cut string-append "-L" <> "/lib")))
597 `("desktopfilesdir=$(prefix)/share/xsessions"
598 ,(string-append "prefix=" (assoc-ref %outputs "out"))
599 ,(string-append "CPPFLAGS=" (join dash-I inputs))
600 ,(string-append "LDFLAGS=" (join dash-L inputs))))
601 #:tests? #f ;no tests
602 #:phases (modify-phases %standard-phases
603 (delete 'configure)))) ;no configure script
604 (home-page "http://www.6809.org.uk/evilwm/")
605 (synopsis "Minimalist window manager for the X Window System")
607 "evilwm is a minimalist window manager based on aewm, extended to feature
608 many keyboard controls with repositioning and maximize toggles, solid window
609 drags, snap-to-border support, and virtual desktops.")
610 (license (license:x11-style "file:///README"))))
612 (define-public fluxbox
616 (synopsis "Small and fast window manager")
619 (uri (string-append "mirror://sourceforge/fluxbox/fluxbox/"
620 version "/fluxbox-" version ".tar.xz"))
623 "1h1f70y40qd225dqx937vzb4k2cz219agm1zvnjxakn5jkz7b37w"))))
624 (build-system gnu-build-system)
626 `(#:make-flags '("CPPFLAGS=-U__TIME__") ;ugly, but for reproducibility
628 (modify-phases %standard-phases
630 'install 'install-xsession
632 (let ((xsessions (string-append %output "/share/xsessions")))
634 (call-with-output-file
635 (string-append xsessions "/fluxbox.desktop")
641 Exec=~a/bin/startfluxbox~@
642 Type=Application~%" ,name ,synopsis %output)))))))))
644 `(("pkg-config" ,pkg-config)))
646 `(("freetype" ,freetype)
652 ("libxinerama" ,libxinerama)
654 ("libxrandr" ,libxrandr)
655 ("libxrender" ,libxrender)))
656 (description "Fluxbox is a window manager. It is light on resources
657 and easy to handle yet full of features to make an easy and fast desktop
659 (home-page "http://fluxbox.org/")
660 (license license:expat)))
662 (define-public awesome
667 (origin (method url-fetch)
669 "https://github.com/awesomeWM/awesome-releases/raw/"
670 "master/awesome-" version ".tar.xz"))
673 "0kwpbls9h1alxcmvxh5g9qb995fds5b2ngcr44w0ibazkyls2pdc"))
674 (modules '((guix build utils)
677 ;; Remove non-reproducible timestamp and use the date
678 ;; of the source file instead.
679 (substitute* "common/version.c"
680 (("__DATE__ \" \" __TIME__")
683 (make-time time-utc 0
684 (stat:mtime (stat "awesome.c"))))
687 (patches (search-patches "awesome-reproducible-png.patch"))))
688 (build-system cmake-build-system)
689 (native-inputs `(("asciidoc" ,asciidoc)
690 ("docbook-xsl" ,docbook-xsl)
693 ("imagemagick" ,imagemagick)
694 ("libxml2" ,libxml2) ;for XML_CATALOG_FILES
695 ("pkg-config" ,pkg-config)
697 (inputs `(("cairo" ,cairo)
699 ("gdk-pixbuf" ,gdk-pixbuf)
701 ("gobject-introspection" ,gobject-introspection)
705 ("libxcursor" ,libxcursor)
706 ("libxdg-basedir" ,libxdg-basedir)
707 ("libxkbcommon" ,libxkbcommon)
711 ("startup-notification" ,startup-notification)
712 ("xcb-util" ,xcb-util)
713 ("xcb-util-cursor" ,xcb-util-cursor)
714 ("xcb-util-image" ,xcb-util-image)
715 ("xcb-util-keysyms" ,xcb-util-keysyms)
716 ("xcb-util-renderutil" ,xcb-util-renderutil)
717 ("xcb-util-xrm" ,xcb-util-xrm)
718 ("xcb-util-wm" ,xcb-util-wm)))
720 `(;; Let compression happen in our 'compress-documentation' phase so that
721 ;; '--no-name' is used, which removes timestamps from gzip output.
722 #:configure-flags '("-DCOMPRESS_MANPAGES=off")
724 ;; Building awesome in its source dir is no longer supported.
728 (modify-phases %standard-phases
729 (add-before 'build 'xmlto-skip-validation
731 ;; We can't download the necessary schema, so so skip
732 ;; validation and assume they're valid.
733 (substitute* "../build/CMakeFiles/man.dir/build.make"
735 (string-append "/xmlto --skip-validation")))
737 (add-before 'configure 'set-lua-paths
738 (lambda* (#:key inputs #:allow-other-keys)
739 ;; The build process needs to load cairo dynamically.
740 (let* ((cairo (string-append
741 (assoc-ref inputs "cairo") "/lib" ))
742 (lua-lgi (assoc-ref inputs "lua-lgi") ))
743 (setenv "LD_LIBRARY_PATH" cairo )
744 (setenv "LUA_PATH" (string-append lua-lgi
745 "/share/lua/5.2/?.lua"))
746 (setenv "LUA_CPATH" (string-append lua-lgi
747 "/lib/lua/5.2/?.so"))
751 ;; There aren't any tests, so just make sure the binary
752 ;; gets built and can be run successfully.
753 (zero? (system* "../build/awesome" "-v"))))
754 (add-after 'install 'wrap
755 (lambda* (#:key inputs outputs #:allow-other-keys)
756 (let* ((awesome (assoc-ref outputs "out"))
757 (cairo (string-append
758 (assoc-ref inputs "cairo") "/lib" ))
759 (lua-lgi (assoc-ref inputs "lua-lgi") ))
760 (wrap-program (string-append awesome "/bin/awesome")
761 `("GI_TYPELIB_PATH" ":" prefix (,(getenv "GI_TYPELIB_PATH")))
762 `("LD_LIBRARY_PATH" suffix (, cairo))
763 `("LUA_PATH" suffix (,(string-append lua-lgi
764 "/share/lua/5.2/?.lua")))
765 `("LUA_CPATH" suffix (,(string-append
766 lua-lgi "/lib/lua/5.2/?.so"))))))))))
767 (synopsis "Highly configurable window manager")
769 "Awesome has been designed as a framework window manager. It is fast, small,
770 dynamic and extensible using the Lua programming language.")
771 (license license:gpl2+)
772 (home-page "https://awesome.naquadah.org/")))
774 (define-public menumaker
781 (uri (string-append "mirror://sourceforge/menumaker/"
782 "menumaker-" version ".tar.gz"))
785 "1mm4cvg3kphkkd8nwrhcg6d9nm5ar7mgc0wf6fxk6zck1l7xn8ky"))))
786 (build-system gnu-build-system)
788 `(("python" ,python)))
789 (synopsis "Heuristics-driven menu generator")
791 "MenuMaker is a menu generation utility for a number of X window
792 managers and desktop environments. It is capable of finding lots of
793 installed programs and generating a root menu consistent across all
794 supported window managers, so one will get (almost) the same menu in
795 all of them. Currently supported window managers include:
807 (home-page "http://menumaker.sourceforge.net/")
808 (license license:bsd-2)))
810 (define-public keybinder
817 (uri (string-append "https://github.com/kupferlauncher/keybinder"
818 "/releases/download/v" version "/keybinder-"
820 (file-name (string-append name "-" version ".tar.gz"))
823 "0h52hj3ay8mfhwvmfxbxlfyq74hifdk8wxgxp7fr4iy6189hg7w7"))))
824 (build-system gnu-build-system)
826 `(("python-2" ,python-2)
829 `(("python2-pygtk" ,python2-pygtk)
831 ("pkg-config" ,pkg-config)))
832 (synopsis "Library for registering global keyboard shortcuts")
834 "Keybinder is a library for registering global keyboard shortcuts.
835 Keybinder works with GTK-based applications using the X Window System.")
836 (home-page "https://github.com/kupferlauncher/keybinder")
837 (license license:gpl2+)))
839 (define-public spectrwm
846 (uri (let ((version-with-underscores
847 (string-join (string-split version #\.) "_")))
848 (string-append "https://github.com/conformal/spectrwm/archive/"
849 "SPECTRWM_" version-with-underscores ".tar.gz")))
850 (file-name (string-append name "-" version ".tar.gz"))
853 "16lxcharxslf9rc39wxa3mr2nx5d8kzm9ls7p7dal8yrwr7y59dp"))))
854 (build-system gnu-build-system)
856 `(#:make-flags (let ((pkg-config (lambda (flag)
858 "$(shell pkg-config " flag " "
859 "xft fontconfig x11 libpng)"))))
862 (string-append "PREFIX=" %output)
863 (string-append "INCS=-I. " (pkg-config "--cflags"))
864 (string-append "LIBS=" (pkg-config "--libs") " -lm")))
865 #:tests? #f ;No test suite
867 (modify-phases %standard-phases
868 (add-before 'build 'change-dir
871 (add-after 'change-dir 'patch-makefile
873 (substitute* "Makefile"
875 (add-after 'change-dir 'fix-freetype-include
877 (substitute* "Makefile"
878 (("/usr/include/freetype2")
879 (string-append (assoc-ref %build-inputs "freetype")
880 "/include/freetype2")))))
881 (delete 'configure)))) ;no 'configure' exists
883 `(("freetype" ,freetype)
884 ("fontconfig" ,fontconfig)
886 ("libxcursor" ,libxcursor)
887 ("libxrandr" ,libxrandr)
890 ("xcb-util" ,xcb-util)
891 ("xcb-util-wm" ,xcb-util-wm)
892 ("xcb-util-keysyms" ,xcb-util-keysyms)))
895 ("pkg-config" ,pkg-config)))
896 (synopsis "Minimalistic automatic tiling window manager")
898 "Spectrwm is a small dynamic tiling and reparenting window manager for X11.
899 It is inspired by Xmonad and dwm. Its major features include:
902 @item Navigation anywhere on all screens with either the keyboard or mouse
903 @item Customizable status bar
904 @item Restartable without losing state
905 @item Quick launch menu
906 @item Many screen layouts possible with a few simple key strokes
907 @item Move/resize floating windows
908 @item Extended Window Manager Hints (@dfn{EWMH}) support
909 @item Configurable tiling
910 @item Adjustable tile gap allows for a true one pixel border
911 @item Customizable colors and border width
913 (home-page "https://github.com/conformal/spectrwm")
914 (license license:isc)))
923 (uri (string-append "http://chneukirchen.org/releases/cwm-"
927 "1b8k2hjxpb0bzqjh2wj6mn2nf2360zacf8z19sw2rw5lxvmfy89x"))))
928 (build-system gnu-build-system)
930 `(#:make-flags (list "CC=gcc"
931 (string-append "PREFIX=" %output))
934 (modify-phases %standard-phases
936 (add-after 'build 'install-xsession
937 (lambda* (#:key outputs #:allow-other-keys)
938 ;; Add a .desktop file to xsessions.
939 (let* ((output (assoc-ref outputs "out"))
940 (xsessions (string-append output "/share/xsessions")))
943 (string-append xsessions "/cwm.desktop")
948 Comment=OpenBSD Calm Window Manager fork~@
950 TryExec=~@*~a/bin/cwm~@
957 ("libxrandr" ,libxrandr)
958 ("libxinerama" ,libxinerama)))
960 `(("pkg-config" ,pkg-config)
962 (home-page "https://github.com/chneukirchen/cwm")
963 (synopsis "OpenBSD fork of the calmwm window manager")
964 (description "Cwm is a stacking window manager for X11. It is an OpenBSD
965 project derived from the original Calm Window Manager.")
966 (license license:isc)))