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>
9 ;;; This file is part of GNU Guix.
11 ;;; GNU Guix is free software; you can redistribute it and/or modify it
12 ;;; under the terms of the GNU General Public License as published by
13 ;;; the Free Software Foundation; either version 3 of the License, or (at
14 ;;; your option) any later version.
16 ;;; GNU Guix is distributed in the hope that it will be useful, but
17 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
18 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 ;;; GNU General Public License for more details.
21 ;;; You should have received a copy of the GNU General Public License
22 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
24 (define-module (gnu packages wm)
25 #:use-module ((guix licenses) #:prefix license:)
26 #:use-module (guix packages)
27 #:use-module (gnu packages)
28 #:use-module (gnu packages linux)
29 #:use-module (guix build-system gnu)
30 #:use-module (guix build-system haskell)
31 #:use-module (gnu packages haskell)
32 #:use-module (gnu packages base)
33 #:use-module (gnu packages pkg-config)
34 #:use-module (gnu packages perl)
35 #:use-module (gnu packages xorg)
36 #:use-module (gnu packages xdisorg)
37 #:use-module (gnu packages qt)
38 #:use-module (gnu packages asciidoc)
39 #:use-module (gnu packages xml)
40 #:use-module (gnu packages m4)
41 #:use-module (gnu packages docbook)
42 #:use-module (gnu packages image)
43 #:use-module (gnu packages pcre)
44 #:use-module (gnu packages gtk)
45 #:use-module (gnu packages libevent)
46 #:use-module (gnu packages fribidi)
47 #:use-module (gnu packages maths)
48 #:use-module (gnu packages web)
49 #:use-module (gnu packages fontutils)
50 #:use-module (guix download)
51 #:use-module (guix git-download))
53 (define-public libconfuse
59 (uri (string-append "http://savannah.nongnu.org/download/confuse/"
60 "confuse-" version ".tar.gz"))
63 "0y47r2ashz44wvnxdb18ivpmj8nxhw3y9bf7v9w0g5byhgyp89g3"))))
64 (build-system gnu-build-system)
65 (home-page "http://www.nongnu.org/confuse/")
66 (synopsis "Configuration file parser library")
67 (description "libconfuse is a configuration file parser library. It
68 supports sections and (lists of) values (strings, integers, floats, booleans
69 or other sections), as well as some other features (such as
70 single/double-quoted strings, environment variable expansion, functions and
71 nested include statements).")
72 (license license:isc)))
80 (file-name (string-append name "-" version ".tar.gz"))
83 "https://github.com/baskerville/bspwm/archive/"
87 "1pig0h2jk8wipyz90j69c4bk37bfyq60asnn0v0bqld2p2vjvyqy"))))
88 (build-system gnu-build-system)
91 ("libxinerama" ,libxinerama)
93 ("xcb-util" ,xcb-util)
94 ("xcb-util-keysyms" ,xcb-util-keysyms)
95 ("xcb-util-wm" ,xcb-util-wm)))
97 '(#:phases (alist-delete 'configure %standard-phases)
98 #:tests? #f ; no check target
99 #:make-flags (list "CC=gcc"
100 (string-append "PREFIX=" %output))))
101 (home-page "https://github.com/baskerville/bspwm")
102 (synopsis "Tiling window manager based on binary space partitioning")
103 (description "bspwm is a tiling window manager that represents windows as
104 the leaves of a full binary tree.")
105 (license license:bsd-2)))
107 (define-public i3status
113 (uri (string-append "http://i3wm.org/i3status/i3status-"
117 "1qwxbrga2fi5wf742hh9ajwa8b2kpzkjjnhjlz4wlpv21i80kss2"))))
118 (build-system gnu-build-system)
120 `(#:make-flags (list "CC=gcc" (string-append "PREFIX=" %output))
122 (modify-phases %standard-phases
124 #:tests? #f)) ; no test suite
126 `(("openlibm" ,openlibm)
127 ("libconfuse" ,libconfuse)
129 ("alsa-lib" ,alsa-lib)
130 ("wireless-tools" ,wireless-tools)
132 ("asciidoc" ,asciidoc)))
133 (home-page "http://i3wm.org/i3status/")
134 (synopsis "Status bar for i3bar, dzen2, xmobar or similar programs")
135 (description "i3status is a small program for generating a status bar for
136 i3bar, dzen2, xmobar or similar programs. It is designed to be very efficient
137 by issuing a very small number of system calls, as one generally wants to
138 update such a status line every second. This ensures that even under high
139 load, your status bar is updated correctly. Also, it saves a bit of energy by
140 not hogging your CPU as much as spawning the corresponding amount of shell
142 (license license:bsd-3)))
150 (uri (string-append "http://i3wm.org/downloads/i3-"
154 "1lq7h4w7m0hi31iva8g7yf1sc11ispnknxjdaj9agld4smxqb44j"))))
155 (build-system gnu-build-system)
157 `(#:make-flags (list "CC=gcc" (string-append "PREFIX=" %output))
159 (modify-phases %standard-phases
161 #:tests? #f)) ; no test suite
164 ("xcb-util" ,xcb-util)
165 ("xcb-util-cursor" ,xcb-util-cursor)
166 ("xcb-util-keysyms" ,xcb-util-keysyms)
167 ("xcb-util-wm" ,xcb-util-wm)
168 ("libxkbcommon" ,libxkbcommon)
171 ("asciidoc" ,asciidoc)
173 ("perl-pod-simple" ,perl-pod-simple)
174 ("docbook-xml" ,docbook-xml)
177 ("startup-notification" ,startup-notification)
183 ("pkg-config" ,pkg-config)))
184 (home-page "http://i3wm.org/")
185 (synopsis "Improved tiling window manager")
186 (description "A tiling window manager, completely written
187 from scratch. i3 is primarily targeted at advanced users and
189 (license license:bsd-3)))
191 (define-public xmonad
195 (synopsis "Tiling window manager")
198 (uri (string-append "http://hackage.haskell.org/package/xmonad/"
199 name "-" version ".tar.gz"))
202 "1pfjssamiwpwjp1qqkm9m9p9s35pv381m0cwg6jxg0ppglibzq1r"))
203 (modules '((guix build utils)))
205 ;; Here we update the constraints on the utf8-string package in
206 ;; the Cabal file. We allow a newer version which is compatible
207 ;; with GHC 7.10.2. The same change is applied on Hackage. See
208 ;; <https://hackage.haskell.org/package/xmonad-0.11.1/revisions/>.
209 '(substitute* "xmonad.cabal"
210 (("utf8-string >= 0.3 && < 0.4")
211 "utf8-string >= 0.3 && < 1.1")))))
212 (build-system haskell-build-system)
214 `(("ghc-mtl" ,ghc-mtl)
215 ("ghc-utf8-string" ,ghc-utf8-string)
216 ("ghc-extensible-exceptions" ,ghc-extensible-exceptions)
217 ("ghc-x11" ,ghc-x11)))
220 (modify-phases %standard-phases
222 'install 'install-xsession
224 (let* ((xsessions (string-append %output "/share/xsessions")))
226 (call-with-output-file
227 (string-append xsessions "/xmonad.desktop")
234 Type=Application~%" ,name ,synopsis %output)))))))))
235 (home-page "http://xmonad.org")
237 "Xmonad is a tiling window manager for X. Windows are arranged
238 automatically to tile the screen without gaps or overlap, maximising screen
239 use. All features of the window manager are accessible from the keyboard: a
240 mouse is strictly optional. Xmonad is written and extensible in Haskell.
241 Custom layout algorithms, and other extensions, may be written by the user in
242 config files. Layouts are applied dynamically, and different layouts may be
243 used on each workspace. Xinerama is fully supported, allowing windows to be
244 tiled on several screens.")
245 (license license:bsd-3)))
247 (define-public ghc-xmonad-contrib
249 (name "ghc-xmonad-contrib")
254 (uri (string-append "http://hackage.haskell.org/package/xmonad-contrib/"
255 "xmonad-contrib-" version ".tar.gz"))
258 "1g5cw9vvnfbiyi599fngk02zlmdhrf82x0bndhypkn6kybab6yd3"))))
259 (build-system haskell-build-system)
261 `(("ghc-mtl" ,ghc-mtl)
262 ("ghc-old-time" ,ghc-old-time)
263 ("ghc-random" ,ghc-random)
264 ("ghc-utf8-string" ,ghc-utf8-string)
265 ("ghc-extensible-exceptions" ,ghc-extensible-exceptions)
267 ("ghc-x11-xft" ,ghc-x11-xft)
269 (home-page "http://xmonad.org")
270 (synopsis "Third party extensions for xmonad")
272 "Third party tiling algorithms, configurations, and scripts to Xmonad, a
273 tiling window manager for X.")
274 (license license:bsd-3)))
276 (define-public evilwm
283 (uri (string-append "http://www.6809.org.uk/evilwm/evilwm-"
287 "0ak0yajzk3v4dg5wmaghv6acf7v02a4iw8qxmq5yw5ard8lrqn3r"))
288 (patches (map search-patch '("evilwm-lost-focus-bug.patch")))))
289 (build-system gnu-build-system)
293 ("libxrandr" ,libxrandr)))
295 `(#:modules ((srfi srfi-26)
297 (guix build gnu-build-system))
298 #:make-flags (let ((inputs (map (cut assoc-ref %build-inputs <>)
299 '("libx11" "libxext" "libxrandr")))
300 (join (lambda (proc strs)
301 (string-join (map proc strs) " ")))
302 (dash-I (cut string-append "-I" <> "/include"))
303 (dash-L (cut string-append "-L" <> "/lib")))
304 `("desktopfilesdir=$(prefix)/share/xsessions"
305 ,(string-append "prefix=" (assoc-ref %outputs "out"))
306 ,(string-append "CPPFLAGS=" (join dash-I inputs))
307 ,(string-append "LDFLAGS=" (join dash-L inputs))))
308 #:tests? #f ;no tests
309 #:phases (modify-phases %standard-phases
310 (delete 'configure)))) ;no configure script
311 (home-page "http://www.6809.org.uk/evilwm/")
312 (synopsis "Minimalist window manager for the X Window System")
314 "evilwm is a minimalist window manager based on aewm, extended to feature
315 many keyboard controls with repositioning and maximize toggles, solid window
316 drags, snap-to-border support, and virtual desktops.")
317 (license (license:x11-style "file:///README"))))
319 (define-public fluxbox
323 (synopsis "Small and fast window manager")
326 (uri (string-append "mirror://sourceforge/fluxbox/"
327 version "/fluxbox-" version ".tar.xz"))
330 "1h1f70y40qd225dqx937vzb4k2cz219agm1zvnjxakn5jkz7b37w"))))
331 (build-system gnu-build-system)
333 `(#:make-flags '("CPPFLAGS=-U__TIME__") ;ugly, but for reproducibility
335 (modify-phases %standard-phases
337 'install 'install-xsession
339 (let ((xsessions (string-append %output "/share/xsessions")))
341 (call-with-output-file
342 (string-append xsessions "/fluxbox.desktop")
348 Exec=~a/bin/startfluxbox~@
349 Type=Application~%" ,name ,synopsis %output)))))))))
351 `(("pkg-config" ,pkg-config)))
353 `(("freetype" ,freetype)
359 ("libxinerama" ,libxinerama)
361 ("libxrandr" ,libxrandr)
362 ("libxrender" ,libxrender)))
363 (description "Fluxbox is a window manager. It is light on resources
364 and easy to handle yet full of features to make an easy and fast desktop
366 (home-page "http://fluxbox.org/")
367 (license license:expat)))