[bug#54153] gnu: mblaze: Offer contrib executables.
Commit Message
Ludovic Courtès <ludo@gnu.org> wrote:
> Looks like the patch isn’t actually there. ↑
>
> Could you send it?
Oops! Here you go.
Comments
Hi,
elaexuotee@wilsonb.com skribis:
> From 5f14f56a51cb340a54472a76610cb4672d36134f Mon Sep 17 00:00:00 2001
> From: "B. Wilson" <elaexuotee@wilsonb.com>
> Date: Fri, 25 Feb 2022 15:31:05 +0900
> Subject: [PATCH] gnu: mblaze: Offer contrib executables.
> To: guix-patches@gnu.org
>
> * gnu/packages/mail.scm(mblaze): New contrib output.
Applied…
> #:make-flags
> - #~(list #$(string-append "CC=" (cc-for-target))
> + #~(list (string-append "CC=" #$(cc-for-target))
> "PREFIX="
> - (string-append "DESTDIR=" #$output))
> + (string-append "DESTDIR=" %output))
… without this hunk.
I also added details to the commit log.
Thanks!
Ludo’.
From e389b54cb0347bef0d31185472df7206f2b91aa3 Mon Sep 17 00:00:00 2001
From: "B. Wilson" <elaexuotee@wilsonb.com>
Date: Fri, 25 Feb 2022 15:31:05 +0900
Subject: [PATCH] gnu: mblaze: Offer contrib executables.
To: guix-patches@gnu.org
* gnu/packages/mail.scm(mblaze): New contrib output.
---
gnu/packages/mail.scm | 20 +++++++++++++++++++-
1 file changed, 19 insertions(+), 1 deletion(-)
@@ -2722,6 +2722,7 @@ (define-public mblaze
(file-name (git-file-name name version))
(sha256
(base32 "0fa8s9dp5ilwmfcwkx72x2b5i0maa5sl97hv2cdknqmc27gv0b1c"))))
+ (outputs '("out" "contrib"))
(build-system gnu-build-system)
(native-inputs
(list perl))
@@ -2730,9 +2731,26 @@ (define-public mblaze
#:make-flags (list (string-append "CC=" ,(cc-for-target))
"PREFIX="
(string-append "DESTDIR=" %output))
+ #:modules ((ice-9 ftw)
+ (guix build utils)
+ (guix build gnu-build-system))
#:phases
(modify-phases %standard-phases
- (delete 'configure))))
+ (delete 'configure)
+ (add-after 'install 'install-contrib
+ (lambda _
+ (let* ((out (assoc-ref %outputs "contrib"))
+ (bin (string-append out "/bin"))
+ (exe? (lambda (file)
+ (let ((s (stat file)))
+ (and (eq? 'regular (stat:type s))
+ (logtest #o100 (stat:perms s)))))))
+ (mkdir-p bin)
+ (with-directory-excursion "contrib"
+ (for-each
+ (lambda (file)
+ (install-file file bin))
+ (scandir "." exe?)))))))))
(home-page "https://github.com/leahneukirchen/mblaze")
(synopsis "Unix utilities to deal with Maildir")
(description
--
2.34.0