aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages
diff options
context:
space:
mode:
authorng0 <contact.ng0@cryptolab.net>2017-03-05 16:14:43 -0500
committerLeo Famulari <leo@famulari.name>2017-03-05 16:25:39 -0500
commit33c93ea33ed9ab35f9432665f931285898ca75c7 (patch)
tree2241b45b24328aeac1a61230cdfba4947986e8b8 /gnu/packages
parent5af1a381334d70d771b317f363e617a9011465c8 (diff)
downloadpatches-33c93ea33ed9ab35f9432665f931285898ca75c7.tar
patches-33c93ea33ed9ab35f9432665f931285898ca75c7.tar.gz
gnu: rxvt-unicode: Add '.desktop' files.
This fixes <https://bugs.gnu.org/23106>. * gnu/packages/xdisorg.scm (rxvt-unicode)[arguments]: Add 'install-desktop-urxvt' and 'install-desktop-urxvtc' phases.
Diffstat (limited to 'gnu/packages')
-rw-r--r--gnu/packages/xdisorg.scm43
1 files changed, 41 insertions, 2 deletions
diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index 3e0b441128..7d4209d126 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -17,6 +17,7 @@
;;; Copyright © 2016 Marius Bakke <mbakke@fastmail.com>
;;; Copyright © 2016 Petter <petter@mykolab.ch>
;;; Copyright © 2017 Mekeor Melire <mekeor.melire@gmail.com>
+;;; Copyright © 2017 ng0 <contact.ng0@cryptolab.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -689,9 +690,47 @@ compact configuration syntax.")
;; This sets the destination when installing the necessary terminal
;; capability data, which are not provided by 'ncurses'. See
;; https://lists.gnu.org/archive/html/bug-ncurses/2009-10/msg00031.html
- '(#:make-flags (list (string-append "TERMINFO="
+ `(#:make-flags (list (string-append "TERMINFO="
(assoc-ref %outputs "out")
- "/share/terminfo"))))
+ "/share/terminfo"))
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'install 'install-desktop-urxvt
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((output (assoc-ref outputs "out"))
+ (desktop (string-append output "/share/applications")))
+ (mkdir-p desktop)
+ (with-output-to-file
+ (string-append desktop "/urxvt.desktop")
+ (lambda _
+ (format #t
+ "[Desktop Entry]~@
+ Name=rxvt-unicode~@
+ Comment=~@
+ Exec=~a/bin/urxvt~@
+ TryExec=~@*~a/bin/urxvt~@
+ Icon=~@
+ Type=Application~%"
+ output)))
+ #t)))
+ (add-after 'install 'install-desktop-urxvtc
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((output (assoc-ref outputs "out"))
+ (desktop (string-append output "/share/applications")))
+ (mkdir-p desktop)
+ (with-output-to-file
+ (string-append desktop "/urxvtc.desktop")
+ (lambda _
+ (format #t
+ "[Desktop Entry]~@
+ Name=rxvt-unicode~@
+ Comment=Rxvt clone with XFT and unicode support~@
+ Exec=~a/bin/urxvtc~@
+ TryExec=~@*~a/bin/urxvtc~@
+ Icon=~@
+ Type=Application~%"
+ output)))
+ #t))))))
(inputs
`(("libXft" ,libxft)
("libX11" ,libx11)))