+
+(define-public stumpwm
+ (package
+ (name "stumpwm")
+ (version "19.11")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/stumpwm/stumpwm.git")
+ (commit version)))
+ (file-name (git-file-name "stumpwm" version))
+ (sha256
+ (base32 "1ha8803ll7472kqxsy2xz0v5d4sv8apmc9z631d67m31q0z1m9rz"))))
+ (build-system asdf-build-system/sbcl)
+ (native-inputs `(("fiasco" ,sbcl-fiasco)
+ ("texinfo" ,texinfo)))
+ (inputs `(("cl-ppcre" ,sbcl-cl-ppcre)
+ ("clx" ,sbcl-clx)
+ ("alexandria" ,sbcl-alexandria)))
+ (outputs '("out" "lib"))
+ (arguments
+ '(#:asd-system-name "stumpwm"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'create-symlinks 'build-program
+ (lambda* (#:key outputs #:allow-other-keys)
+ (build-program
+ (string-append (assoc-ref outputs "out") "/bin/stumpwm")
+ outputs
+ #:entry-program '((stumpwm:stumpwm) 0))))
+ (add-after 'build-program 'create-desktop-file
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (xsessions (string-append out "/share/xsessions")))
+ (mkdir-p xsessions)
+ (call-with-output-file
+ (string-append xsessions "/stumpwm.desktop")
+ (lambda (file)
+ (format file
+ "[Desktop Entry]~@
+ Name=stumpwm~@
+ Comment=The Stump Window Manager~@
+ Exec=~a/bin/stumpwm~@
+ TryExec=~@*~a/bin/stumpwm~@
+ Icon=~@
+ Type=Application~%"
+ out)))
+ #t)))
+ (add-after 'install 'install-manual
+ (lambda* (#:key outputs #:allow-other-keys)
+ ;; The proper way to the manual is bootstrapping a full autotools
+ ;; build system and running ‘./configure && make stumpwm.info’ to
+ ;; do some macro substitution. We can get away with much less.
+ (let* ((out (assoc-ref outputs "out"))
+ (info (string-append out "/share/info")))
+ (invoke "makeinfo" "stumpwm.texi.in")
+ (install-file "stumpwm.info" info)
+ #t))))))
+ (synopsis "Window manager written in Common Lisp")
+ (description "Stumpwm is a window manager written entirely in Common Lisp.
+It attempts to be highly customizable while relying entirely on the keyboard
+for input. These design decisions reflect the growing popularity of
+productive, customizable lisp based systems.")
+ (home-page "https://github.com/stumpwm/stumpwm")
+ (license license:gpl2+)
+ (properties `((cl-source-variant . ,(delay cl-stumpwm))))))
+
+(define-public sbcl-stumpwm
+ (deprecated-package "sbcl-stumpwm" stumpwm))
+
+(define-public cl-stumpwm
+ (package
+ (inherit (sbcl-package->cl-source-package stumpwm))
+ (name "cl-stumpwm")))
+
+(define-public stumpwm+slynk
+ (package
+ (inherit stumpwm)
+ (name "stumpwm-with-slynk")
+ (outputs '("out"))
+ (inputs
+ `(("stumpwm" ,stumpwm "lib")
+ ("slynk" ,sbcl-slynk)))
+ (arguments
+ (substitute-keyword-arguments (package-arguments stumpwm)
+ ((#:phases phases)
+ `(modify-phases ,phases
+ (replace 'build-program
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+ (program (string-append out "/bin/stumpwm")))
+ (build-program program outputs
+ #:entry-program '((stumpwm:stumpwm) 0)
+ #:dependencies '("stumpwm"
+ ,@(@@ (gnu packages lisp-xyz) slynk-systems))
+ #:dependency-prefixes
+ (map (lambda (input) (assoc-ref inputs input))
+ '("stumpwm" "slynk")))
+ ;; Remove unneeded file.
+ (delete-file (string-append out "/bin/stumpwm-exec.fasl"))
+ #t)))
+ (delete 'copy-source)
+ (delete 'build)
+ (delete 'check)
+ (delete 'create-asd-file)
+ (delete 'cleanup)
+ (delete 'create-symlinks)))))))
+
+(define-public sbcl-stumpwm+slynk
+ (deprecated-package "sbcl-stumpwm-with-slynk" stumpwm+slynk))
+
+(define-public sbcl-stumpwm-ttf-fonts
+ (let ((commit "dd5b037923ec7d3cc27c55806bcec5a1b8cf4e91")
+ (revision "1"))
+ (package
+ (name "sbcl-ttf-fonts")
+ (version (git-version "0.0.1" revision commit)) ;no upstream release
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/stumpwm/stumpwm-contrib.git")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "0ahxdj9f884afpzxczx6mx7l4nwg4kw6afqaq7lwhf7lxcwylldn"))))
+ (inputs
+ `(("stumpwm" ,stumpwm "lib")
+ ("clx-truetype" ,sbcl-clx-truetype)))
+ (build-system asdf-build-system/sbcl)
+ (arguments
+ '(#:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'chdir
+ (lambda _
+ (chdir "util/ttf-fonts"))))))
+ (home-page "https://github.com/stumpwm/stumpwm-contrib")
+ (synopsis "Implementation of TTF font rendering for Lisp")
+ (description "This package provides a Lisp implementation of TTF font
+rendering.")
+ (license (list license:gpl2+ license:gpl3+ license:bsd-2)))))
+
+(define-public lemonbar
+ (let ((commit "35183ab81d2128dbb7b6d8e119cc57846bcefdb4")
+ (revision "1"))
+ (package
+ (name "lemonbar")
+ (version (git-version "1.3" revision commit))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/LemonBoy/bar")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1wwqbph392iwz8skaqxb0xpklb1l6yganqz80g4x1fhrnz7idmlh"))))
+ (build-system gnu-build-system)
+ (arguments
+ '(#:tests? #f ; no test suite
+ #:make-flags (list "CC=gcc"
+ (string-append "PREFIX=" %output))
+ #:phases
+ (modify-phases %standard-phases
+ (delete 'configure))))
+ (inputs
+ `(("libxcb" ,libxcb)))
+ (native-inputs
+ `(("perl" ,perl)))
+ (home-page "https://github.com/LemonBoy/bar")
+ (synopsis "Featherweight status bar")
+ (description
+ "@code{lemonbar} (formerly known as @code{bar}) is a lightweight
+bar entirely based on XCB. Provides full UTF-8 support, basic
+formatting, RandR and Xinerama support and EWMH compliance without
+wasting your precious memory.")
+ (license license:x11))))