aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/guile.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2023-03-03 23:32:52 +0100
committerLudovic Courtès <ludo@gnu.org>2023-03-03 23:32:52 +0100
commitf14ead765bc7937af790b007a07ca4e163e55095 (patch)
tree95cb8210bbf93fe1c17ef5a5379a2c35f74744e9 /gnu/packages/guile.scm
parent0aed5bf5120bd434e53be0cea3f96547f95837d6 (diff)
downloadguix-f14ead765bc7937af790b007a07ca4e163e55095.tar
guix-f14ead765bc7937af790b007a07ca4e163e55095.tar.gz
gnu: guile: Fix cross-compilation.
Fixes a regression introduced in d427ec403800dc5b0b69f3d7c259a7d62eb6c881, which changed the label of Bash from "bash" to "bash-minimal" when cross-compiling. * gnu/packages/guile.scm (guile-2.0)[arguments]: In 'pre-configure' phase, use 'search-input-file' when (%current-target-system) is true.
Diffstat (limited to 'gnu/packages/guile.scm')
-rw-r--r--gnu/packages/guile.scm14
1 files changed, 9 insertions, 5 deletions
diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm
index d1b8f70f47..2adf271d07 100644
--- a/gnu/packages/guile.scm
+++ b/gnu/packages/guile.scm
@@ -218,17 +218,21 @@ without requiring the source code to be rewritten.")
(add-before 'configure 'pre-configure
(lambda* (#:key inputs #:allow-other-keys)
;; Tell (ice-9 popen) the file name of Bash.
+
+ ;; TODO: On the next rebuild cycle, unconditionally use
+ ;; 'search-input-file' instead of 'assoc-ref'.
(let ((bash (assoc-ref inputs "bash")))
(substitute* "module/ice-9/popen.scm"
;; If bash is #f allow fallback for user to provide
;; "bash" in PATH. This happens when cross-building to
;; MinGW for which we do not have Bash yet.
(("/bin/sh")
- ,@(if (target-mingw?)
- '((if bash
- (string-append bash "/bin/bash")
- "bash"))
- '((string-append bash "/bin/bash")))))
+ ,(cond ((target-mingw?)
+ "bash")
+ ((%current-target-system)
+ '(search-input-file inputs "/bin/bash"))
+ (else
+ '(string-append bash "/bin/bash")))))
#t))))))
(native-search-paths