* [PATCH 1/2] gnu: dwm: Use modify-phases.
@ 2017-01-15 12:21 ng0
2017-01-15 12:21 ` [PATCH 2/2] gnu: dwm: Add '.desktop' file ng0
2017-01-16 9:45 ` [PATCH 1/2] gnu: dwm: Use modify-phases Ludovic Courtès
0 siblings, 2 replies; 4+ messages in thread
From: ng0 @ 2017-01-15 12:21 UTC (permalink / raw)
To: guix-devel
* gnu/packages/suckless.scm (dwm): Use modify-phases.
---
gnu/packages/suckless.scm | 26 ++++++++++++--------------
1 file changed, 12 insertions(+), 14 deletions(-)
diff --git a/gnu/packages/suckless.scm b/gnu/packages/suckless.scm
index 868939b90..a737a29dc 100644
--- a/gnu/packages/suckless.scm
+++ b/gnu/packages/suckless.scm
@@ -2,7 +2,7 @@
;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
;;; Copyright © 2015 Amirouche Boubekki <amirouche@hypermove.net>
;;; Copyright © 2016 Al McElrath <hello@yrns.org>
-;;; Copyright © 2016, 2017 ng0 <ng0@libertad.pw>
+;;; Copyright © 2016, 2017 ng0 <contact.ng0@cryptolab.net>
;;; Copyright © 2015 Dmitry Bogatov <KAction@gnu.org>
;;; Copyright © 2015 Leo Famulari <leo@famulari.name>
;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
@@ -64,19 +64,17 @@
(assoc-ref %build-inputs "freetype")
"/include/freetype2"))
#:phases
- (alist-replace
- 'configure
- (lambda _
- (substitute* "Makefile" (("\\$\\{CC\\}") "gcc"))
- #t)
- (alist-replace
- 'install
- (lambda* (#:key outputs #:allow-other-keys)
- (let ((out (assoc-ref outputs "out")))
- (zero?
- (system* "make" "install"
- (string-append "DESTDIR=" out) "PREFIX="))))
- %standard-phases))))
+ (modify-phases %standard-phases
+ (replace 'configure
+ (lambda _
+ (substitute* "Makefile" (("\\$\\{CC\\}") "gcc"))
+ #t))
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out")))
+ (zero?
+ (system* "make" "install"
+ (string-append "DESTDIR=" out) "PREFIX="))))))))
(inputs
`(("freetype" ,freetype)
("libx11" ,libx11)
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/2] gnu: dwm: Add '.desktop' file.
2017-01-15 12:21 [PATCH 1/2] gnu: dwm: Use modify-phases ng0
@ 2017-01-15 12:21 ` ng0
2017-01-16 9:47 ` Ludovic Courtès
2017-01-16 9:45 ` [PATCH 1/2] gnu: dwm: Use modify-phases Ludovic Courtès
1 sibling, 1 reply; 4+ messages in thread
From: ng0 @ 2017-01-15 12:21 UTC (permalink / raw)
To: guix-devel
Fixes <https://bugs.gnu.org/25438>.
* gnu/packages/suckless.scm (dwm)[arguments]: Add
'install-xsession' phase.
---
gnu/packages/suckless.scm | 21 ++++++++++++++++++++-
1 file changed, 20 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/suckless.scm b/gnu/packages/suckless.scm
index a737a29dc..e30a0883a 100644
--- a/gnu/packages/suckless.scm
+++ b/gnu/packages/suckless.scm
@@ -74,7 +74,26 @@
(let ((out (assoc-ref outputs "out")))
(zero?
(system* "make" "install"
- (string-append "DESTDIR=" out) "PREFIX="))))))))
+ (string-append "DESTDIR=" out) "PREFIX=")))))
+ (add-after 'build 'install-xsession
+ (lambda* (#:key outputs #:allow-other-keys)
+ ;; Add a .desktop file to xsessions.
+ (let* ((output (assoc-ref outputs "out"))
+ (xsessions (string-append output "/share/xsessions")))
+ (mkdir-p xsessions)
+ (with-output-to-file
+ (string-append xsessions "/dwm.desktop")
+ (lambda _
+ (format #t
+ "[Desktop Entry]~@
+ Name=dwm~@
+ Comment=Dynamic Window Manager~@
+ Exec=~a/bin/dwm~@
+ TryExec=~@*~a/bin/dwm~@
+ Icon=~@
+ Type=Application~%"
+ output)))
+ #t))))))
(inputs
`(("freetype" ,freetype)
("libx11" ,libx11)
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/2] gnu: dwm: Use modify-phases.
2017-01-15 12:21 [PATCH 1/2] gnu: dwm: Use modify-phases ng0
2017-01-15 12:21 ` [PATCH 2/2] gnu: dwm: Add '.desktop' file ng0
@ 2017-01-16 9:45 ` Ludovic Courtès
1 sibling, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2017-01-16 9:45 UTC (permalink / raw)
To: ng0; +Cc: guix-devel
ng0 <ng0@libertad.pw> skribis:
> * gnu/packages/suckless.scm (dwm): Use modify-phases.
Applied, thnaks!
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 2/2] gnu: dwm: Add '.desktop' file.
2017-01-15 12:21 ` [PATCH 2/2] gnu: dwm: Add '.desktop' file ng0
@ 2017-01-16 9:47 ` Ludovic Courtès
0 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2017-01-16 9:47 UTC (permalink / raw)
To: ng0; +Cc: guix-devel
ng0 <ng0@libertad.pw> skribis:
> Fixes <https://bugs.gnu.org/25438>.
>
> * gnu/packages/suckless.scm (dwm)[arguments]: Add
> 'install-xsession' phase.
Applied, thanks!
Make sure to close the bug.
Ludo’.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-01-16 9:47 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-15 12:21 [PATCH 1/2] gnu: dwm: Use modify-phases ng0
2017-01-15 12:21 ` [PATCH 2/2] gnu: dwm: Add '.desktop' file ng0
2017-01-16 9:47 ` Ludovic Courtès
2017-01-16 9:45 ` [PATCH 1/2] gnu: dwm: Use modify-phases Ludovic Courtès
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.