mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-11-16 19:57:39 -05:00
utils: Use 'which' to find the shell in 'patch-makefile-SHELL'.
* guix/build/utils.scm (patch-makefile-SHELL)[find-shell]: Use 'which'.
This commit is contained in:
parent
7cc7dec139
commit
5e5deea952
1 changed files with 1 additions and 3 deletions
|
@ -629,9 +629,7 @@ (define* (patch-makefile-SHELL file #:key (keep-mtime? #t))
|
|||
;; XXX: Unlike with `patch-shebang', FILE is always touched.
|
||||
|
||||
(define (find-shell name)
|
||||
(let ((shell
|
||||
(search-path (search-path-as-string->list (getenv "PATH"))
|
||||
name)))
|
||||
(let ((shell (which name)))
|
||||
(unless shell
|
||||
(format (current-error-port)
|
||||
"patch-makefile-SHELL: warning: no binary for shell `~a' found in $PATH~%"
|
||||
|
|
Loading…
Reference in a new issue