* [bug#29543] [PATCH] gnu: windowmaker: Add '.desktop' file.
@ 2017-12-03 0:46 Kei Kebreau
2017-12-05 12:39 ` Ludovic Courtès
0 siblings, 1 reply; 5+ messages in thread
From: Kei Kebreau @ 2017-12-03 0:46 UTC (permalink / raw)
To: 29543; +Cc: Kei Kebreau
* gnu/packages/gnustep.scm (windowmaker)[arguments]: Add 'install-xsession'
phase.
---
gnu/packages/gnustep.scm | 23 +++++++++++++++++++----
1 file changed, 19 insertions(+), 4 deletions(-)
diff --git a/gnu/packages/gnustep.scm b/gnu/packages/gnustep.scm
index 195249c43..9a2bfefb4 100644
--- a/gnu/packages/gnustep.scm
+++ b/gnu/packages/gnustep.scm
@@ -65,6 +65,7 @@ to easily create cross-compiled binaries.")
(package
(name "windowmaker")
(version "0.95.8")
+ (synopsis "NeXTSTEP-like window manager")
(source (origin
(method url-fetch)
(uri (string-append
@@ -75,7 +76,7 @@ to easily create cross-compiled binaries.")
"12p8kljqgx5hnic0zvs5mxwp7kg21sb6qjagb2qw8ydvf5amrgwx"))))
(build-system gnu-build-system)
(arguments
- '(#:phases
+ `(#:phases
(modify-phases %standard-phases
(add-before 'configure 'pre-configure
(lambda* (#:key outputs #:allow-other-keys)
@@ -97,14 +98,29 @@ to easily create cross-compiled binaries.")
(substitute* "src/defaults.c"
(("len = strlen\\(text\\) \\+ 40;")
(string-append "len = strlen(text) + 107;"))))))
- (add-after 'install 'wrap
+ (add-after 'install 'install-xsession
+ (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 "/windowmaker.desktop")
+ (lambda (port)
+ (format port "~
+ [Desktop Entry]~@
+ Name=Window Maker~@
+ Comment=~a~@
+ Exec=~a/bin/wmaker~@
+ Type=Application~%" ,synopsis %output))))
+ #t))
+ (add-after 'install-xsession 'wrap
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(bin (string-append out "/bin")))
;; In turn, 'wmaker.inst' wants to invoke 'wmmenugen'
;; etc., so make sure everything is in $PATH.
(wrap-program (string-append bin "/wmaker.inst")
- `("PATH" ":" prefix (,bin)))))))))
+ `("PATH" ":" prefix (,bin)))))))))
(inputs
`(("libxmu" ,libxmu)
("libxft" ,libxft)
@@ -117,7 +133,6 @@ to easily create cross-compiled binaries.")
(native-inputs
`(("pkg-config" ,pkg-config)))
(home-page "http://windowmaker.org/")
- (synopsis "NeXTSTEP-like window manager")
(description
"Window Maker is an X11 window manager originally designed to provide
integration support for the GNUstep Desktop Environment. In every way
--
2.15.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [bug#29543] [PATCH] gnu: windowmaker: Add '.desktop' file.
2017-12-03 0:46 [bug#29543] [PATCH] gnu: windowmaker: Add '.desktop' file Kei Kebreau
@ 2017-12-05 12:39 ` Ludovic Courtès
2017-12-06 19:46 ` Kei Kebreau
0 siblings, 1 reply; 5+ messages in thread
From: Ludovic Courtès @ 2017-12-05 12:39 UTC (permalink / raw)
To: Kei Kebreau; +Cc: 29543
Kei Kebreau <kkebreau@posteo.net> skribis:
> * gnu/packages/gnustep.scm (windowmaker)[arguments]: Add 'install-xsession'
> phase.
[...]
> + (call-with-output-file
> + (string-append xsessions "/windowmaker.desktop")
> + (lambda (port)
> + (format port "~
> + [Desktop Entry]~@
> + Name=Window Maker~@
> + Comment=~a~@
> + Exec=~a/bin/wmaker~@
> + Type=Application~%" ,synopsis %output))))
We’ll have to make sure that ‘synopsis’ does not contain any newline
character or the ‘.desktop’ file would have invalid syntax, I suppose.
To be on the safe side perhaps we can do:
(string-map (match-lambda
(#\newline #\space)
(chr chr))
synopsis)
Apart from that it LGTM, thanks!
Ludo’.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [bug#29543] [PATCH] gnu: windowmaker: Add '.desktop' file.
2017-12-05 12:39 ` Ludovic Courtès
@ 2017-12-06 19:46 ` Kei Kebreau
2017-12-06 21:11 ` Ludovic Courtès
0 siblings, 1 reply; 5+ messages in thread
From: Kei Kebreau @ 2017-12-06 19:46 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 29543
[-- Attachment #1.1: Type: text/plain, Size: 1045 bytes --]
ludo@gnu.org (Ludovic Courtès) writes:
> Kei Kebreau <kkebreau@posteo.net> skribis:
>
>> * gnu/packages/gnustep.scm (windowmaker)[arguments]: Add 'install-xsession'
>> phase.
>
> [...]
>
>> + (call-with-output-file
>> + (string-append xsessions "/windowmaker.desktop")
>> + (lambda (port)
>> + (format port "~
>> + [Desktop Entry]~@
>> + Name=Window Maker~@
>> + Comment=~a~@
>> + Exec=~a/bin/wmaker~@
>> + Type=Application~%" ,synopsis %output))))
>
> We’ll have to make sure that ‘synopsis’ does not contain any newline
> character or the ‘.desktop’ file would have invalid syntax, I suppose.
>
> To be on the safe side perhaps we can do:
>
> (string-map (match-lambda
> (#\newline #\space)
> (chr chr))
> synopsis)
>
> Apart from that it LGTM, thanks!
>
> Ludo’.
Like I've attached?
[-- Attachment #1.2: 0001-gnu-windowmaker-Add-.desktop-file.patch --]
[-- Type: text/plain, Size: 3910 bytes --]
From df79e8050b4385d92d6807a4d76cb1c7347d5906 Mon Sep 17 00:00:00 2001
From: Kei Kebreau <kkebreau@posteo.net>
Date: Sat, 2 Dec 2017 19:43:08 -0500
Subject: [PATCH] gnu: windowmaker: Add '.desktop' file.
* gnu/packages/gnustep.scm (windowmaker)[arguments]: Add 'install-xsession'
phase. Add (guix build build-system), (guix build utils) and (ice-9 match) to
---
gnu/packages/gnustep.scm | 33 ++++++++++++++++++++++++++++-----
1 file changed, 28 insertions(+), 5 deletions(-)
diff --git a/gnu/packages/gnustep.scm b/gnu/packages/gnustep.scm
index 195249c43..a6adc697a 100644
--- a/gnu/packages/gnustep.scm
+++ b/gnu/packages/gnustep.scm
@@ -34,7 +34,8 @@
#:use-module (gnu packages fontutils)
#:use-module (gnu packages image)
#:use-module (gnu packages pkg-config)
- #:use-module (gnu packages xml))
+ #:use-module (gnu packages xml)
+ #:use-module (ice-9 match))
(define-public gnustep-make
(package
@@ -65,6 +66,7 @@ to easily create cross-compiled binaries.")
(package
(name "windowmaker")
(version "0.95.8")
+ (synopsis "NeXTSTEP-like window manager")
(source (origin
(method url-fetch)
(uri (string-append
@@ -75,7 +77,10 @@ to easily create cross-compiled binaries.")
"12p8kljqgx5hnic0zvs5mxwp7kg21sb6qjagb2qw8ydvf5amrgwx"))))
(build-system gnu-build-system)
(arguments
- '(#:phases
+ `(#:modules ((guix build gnu-build-system)
+ (guix build utils)
+ (ice-9 match))
+ #:phases
(modify-phases %standard-phases
(add-before 'configure 'pre-configure
(lambda* (#:key outputs #:allow-other-keys)
@@ -97,14 +102,33 @@ to easily create cross-compiled binaries.")
(substitute* "src/defaults.c"
(("len = strlen\\(text\\) \\+ 40;")
(string-append "len = strlen(text) + 107;"))))))
- (add-after 'install 'wrap
+ (add-after 'install 'install-xsession
+ (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 "/windowmaker.desktop")
+ (lambda (port)
+ (format port "~
+ [Desktop Entry]~@
+ Name=Window Maker~@
+ Comment=~a~@
+ Exec=~a/bin/wmaker~@
+ Type=Application~%"
+ (string-map (match-lambda
+ (#\newline #\space)
+ (chr chr))
+ ,synopsis) %output))))
+ #t))
+ (add-after 'install-xsession 'wrap
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
(bin (string-append out "/bin")))
;; In turn, 'wmaker.inst' wants to invoke 'wmmenugen'
;; etc., so make sure everything is in $PATH.
(wrap-program (string-append bin "/wmaker.inst")
- `("PATH" ":" prefix (,bin)))))))))
+ `("PATH" ":" prefix (,bin)))))))))
(inputs
`(("libxmu" ,libxmu)
("libxft" ,libxft)
@@ -117,7 +141,6 @@ to easily create cross-compiled binaries.")
(native-inputs
`(("pkg-config" ,pkg-config)))
(home-page "http://windowmaker.org/")
- (synopsis "NeXTSTEP-like window manager")
(description
"Window Maker is an X11 window manager originally designed to provide
integration support for the GNUstep Desktop Environment. In every way
--
2.15.0
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [bug#29543] [PATCH] gnu: windowmaker: Add '.desktop' file.
2017-12-06 19:46 ` Kei Kebreau
@ 2017-12-06 21:11 ` Ludovic Courtès
2017-12-06 21:41 ` bug#29543: " Kei Kebreau
0 siblings, 1 reply; 5+ messages in thread
From: Ludovic Courtès @ 2017-12-06 21:11 UTC (permalink / raw)
To: Kei Kebreau; +Cc: 29543
Kei Kebreau <kkebreau@posteo.net> skribis:
> Like I've attached?
>
> From df79e8050b4385d92d6807a4d76cb1c7347d5906 Mon Sep 17 00:00:00 2001
> From: Kei Kebreau <kkebreau@posteo.net>
> Date: Sat, 2 Dec 2017 19:43:08 -0500
> Subject: [PATCH] gnu: windowmaker: Add '.desktop' file.
>
> * gnu/packages/gnustep.scm (windowmaker)[arguments]: Add 'install-xsession'
> phase. Add (guix build build-system), (guix build utils) and (ice-9 match) to
(Message cut too early?)
All right!
Ludo’.
^ permalink raw reply [flat|nested] 5+ messages in thread
* bug#29543: [PATCH] gnu: windowmaker: Add '.desktop' file.
2017-12-06 21:11 ` Ludovic Courtès
@ 2017-12-06 21:41 ` Kei Kebreau
0 siblings, 0 replies; 5+ messages in thread
From: Kei Kebreau @ 2017-12-06 21:41 UTC (permalink / raw)
To: Ludovic Courtès; +Cc: 29543-done
[-- Attachment #1: Type: text/plain, Size: 718 bytes --]
ludo@gnu.org (Ludovic Courtès) writes:
> Kei Kebreau <kkebreau@posteo.net> skribis:
>
>> Like I've attached?
>>
>> From df79e8050b4385d92d6807a4d76cb1c7347d5906 Mon Sep 17 00:00:00 2001
>> From: Kei Kebreau <kkebreau@posteo.net>
>> Date: Sat, 2 Dec 2017 19:43:08 -0500
>> Subject: [PATCH] gnu: windowmaker: Add '.desktop' file.
>>
>> * gnu/packages/gnustep.scm (windowmaker)[arguments]: Add 'install-xsession'
>> phase. Add (guix build build-system), (guix build utils) and (ice-9 match) to
>
> (Message cut too early?)
>
Yes, I meant to put #:modules, but I forgot that 'git commit' ignores lines
beginning with a hash symbol by default.
> All right!
>
> Ludo’.
Thanks for the review!
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2017-12-06 21:43 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-12-03 0:46 [bug#29543] [PATCH] gnu: windowmaker: Add '.desktop' file Kei Kebreau
2017-12-05 12:39 ` Ludovic Courtès
2017-12-06 19:46 ` Kei Kebreau
2017-12-06 21:11 ` Ludovic Courtès
2017-12-06 21:41 ` bug#29543: " Kei Kebreau
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.