me
/
guix
Archived
1
0
Fork 0

gnu: exim: Don't address build inputs by their labels.

The package's output remains identical.

* gnu/packages/mail.scm (exim)[arguments]: Use SEARCH-INPUT-FILE or
PATCH-SHEBANG in place of ASSOC-REF for all inputs.
master
Tobias Geerinckx-Rice 2022-06-19 02:00:00 +02:00
parent b1cb621063
commit 41bc69886a
No known key found for this signature in database
GPG Key ID: 0DB0FF884F556D79
1 changed files with 9 additions and 14 deletions

View File

@ -1822,10 +1822,7 @@ delivery.")
(string-append var "rm\n"))) (string-append var "rm\n")))
(copy-file "src/EDITME" "Local/Makefile") (copy-file "src/EDITME" "Local/Makefile")
(copy-file "exim_monitor/EDITME" "Local/eximon.conf") (copy-file "exim_monitor/EDITME" "Local/eximon.conf")
(let ((out (assoc-ref outputs "out")) (let ((out (assoc-ref outputs "out")))
(gzip (assoc-ref inputs "gzip"))
(bzip2 (assoc-ref inputs "bzip2"))
(xz (assoc-ref inputs "xz")))
(substitute* '("Local/Makefile") (substitute* '("Local/Makefile")
(("(BIN_DIRECTORY=).*" all var) (("(BIN_DIRECTORY=).*" all var)
(string-append var out "/bin\n")) (string-append var out "/bin\n"))
@ -1836,9 +1833,9 @@ delivery.")
(("(FIXED_NEVER_USERS=).*" all var) (("(FIXED_NEVER_USERS=).*" all var)
(string-append var "\n")) ; XXX no root in build environment (string-append var "\n")) ; XXX no root in build environment
(("(COMPRESS_COMMAND=).*" all var) (("(COMPRESS_COMMAND=).*" all var)
(string-append var gzip "/bin/gzip\n")) (string-append var (search-input-file inputs "bin/gzip") "\n"))
(("(ZCAT_COMMAND=).*" all var) (("(ZCAT_COMMAND=).*" all var)
(string-append var gzip "/bin/zcat\n")) (string-append var (search-input-file inputs "bin/zcat") "\n"))
(("# (USE_GNUTLS(|_PC)=.*)" all line) (("# (USE_GNUTLS(|_PC)=.*)" all line)
(string-append line "\n")) (string-append line "\n"))
(("# (AUTH_CRAM_MD5=yes)" all line) line) (("# (AUTH_CRAM_MD5=yes)" all line) line)
@ -1850,19 +1847,17 @@ delivery.")
;; This file has hard-coded relative file names for tools despite ;; This file has hard-coded relative file names for tools despite
;; the zcat configuration above. ;; the zcat configuration above.
(substitute* '("src/exigrep.src") (substitute* '("src/exigrep.src")
(("'zcat'") (string-append "'" gzip "/bin/zcat'")) (("'(bzcat|xzcat|zcat|lzma)'" _ command)
(("'bzcat'") (string-append "'" bzip2 "/bin/bzcat'")) (format #f "'~a'"
(("'xzcat'") (string-append "'" xz "/bin/xzcat'")) (search-input-file
(("'lzma'") (string-append "'" xz "/bin/lzma'")))))) inputs (string-append "bin/" command))))))))
(add-before 'build 'fix-sh-paths (add-before 'build 'fix-sh-paths
(lambda* (#:key inputs #:allow-other-keys) (lambda _
(substitute* '("scripts/lookups-Makefile" "scripts/reversion") (substitute* '("scripts/lookups-Makefile" "scripts/reversion")
(("SHELL=/bin/sh") "SHELL=sh")) (("SHELL=/bin/sh") "SHELL=sh"))
(substitute* '("scripts/Configure-config.h") (substitute* '("scripts/Configure-config.h")
(("\\| /bin/sh") "| sh")) (("\\| /bin/sh") "| sh"))
(let ((bash (assoc-ref inputs "bash"))) (patch-shebang "scripts/Configure-eximon")))
(substitute* '("scripts/Configure-eximon")
(("#!/bin/sh") (string-append "#!" bash "/bin/sh"))))))
(add-before 'build 'build-reproducibly (add-before 'build 'build-reproducibly
(lambda _ (lambda _
;; The compilation number is incremented for every build from the ;; The compilation number is incremented for every build from the