diff options
-rw-r--r-- | gnu/packages/mail.scm | 27 |
1 files changed, 16 insertions, 11 deletions
diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm index 355fb964e3..90bbbe0498 100644 --- a/gnu/packages/mail.scm +++ b/gnu/packages/mail.scm @@ -60,6 +60,7 @@ ;;; Copyright © 2024 Zheng Junjie <[email protected]> ;;; Copyright © 2024 Ashish SHUKLA <[email protected]> ;;; Copyright © 2025 Tanguy Le Carrour <[email protected]> +;;; Copyright © 2025 Sharlatan Hellseher <[email protected]> ;;; ;;; This file is part of GNU Guix. ;;; @@ -5101,33 +5102,37 @@ remote SMTP server.") ;; Patch all occurrences to "sh" with absolute path to ;; the shell available in Guix. (("\"sh\"") - (string-append - "\"" (search-input-file inputs "bin/sh") - "\""))) - (let ((zoxide (search-input-file inputs "bin/zoxide"))) + (format #f "~s" (which "sh")))) + (let ((zoxide #$(this-package-input "zoxide"))) (when zoxide (substitute* "commands/z.go" (("\"zoxide\"") - (string-append "\"" zoxide "\""))))) + (format #f "~s" + (string-append zoxide "/bin/zoxide")))))) (substitute* (list "lib/crypto/gpg/gpg.go" "lib/crypto/gpg/gpg_test.go" "lib/crypto/gpg/gpgbin/keys.go" "lib/crypto/gpg/gpgbin/gpgbin.go") (("\"gpg\"") - (string-append - "\"" (search-input-file inputs "bin/gpg") - "\"")) + (format #f "~s" + (string-append #$(this-package-input "gnupg") + "/bin/gpg"))) (("strings\\.Contains\\(stderr\\.String\\(\\), .*\\)") "strings.Contains(stderr.String(), \"gpg\")"))))) (add-after 'build 'doc (lambda* (#:key import-path build-flags #:allow-other-keys) (invoke "make" "doc" "-C" (string-append "src/" import-path)))) + ;; XXX: This phase does the build and overwrites + ;; go-build-system's build one. (replace 'install (lambda* (#:key import-path build-flags #:allow-other-keys) - (invoke "make" "CC=gcc" "GOFLAGS=-tags=notmuch" "install" "-C" - (string-append "src/" import-path) - (string-append "PREFIX=" #$output))))))) + (invoke "make" + (string-append "CC=" #$(cc-for-target)) + (string-append "GOFLAGS=-tags=notmuch " (getenv "GOFLAGS")) + (string-append "PREFIX=" #$output) + "install" "-C" + (string-append "src/" import-path))))))) (inputs (append (list gnupg |