gnu: guix: Honor the effective Guile version.
* gnu/packages/package-management.scm (guix-0.12.0)[arguments]: In 'wrap-program' phase, use the effective Guile version rather than "2.0". Add #:modules argument.master
parent
38f10b0c4e
commit
ab2419e56a
|
@ -91,6 +91,12 @@
|
||||||
(assoc-ref %build-inputs
|
(assoc-ref %build-inputs
|
||||||
"libgcrypt")))
|
"libgcrypt")))
|
||||||
#:parallel-tests? #f ;work around <http://bugs.gnu.org/21097>
|
#:parallel-tests? #f ;work around <http://bugs.gnu.org/21097>
|
||||||
|
|
||||||
|
#:modules ((guix build gnu-build-system)
|
||||||
|
(guix build utils)
|
||||||
|
(ice-9 popen)
|
||||||
|
(ice-9 rdelim))
|
||||||
|
|
||||||
#:phases (modify-phases %standard-phases
|
#:phases (modify-phases %standard-phases
|
||||||
(add-before
|
(add-before
|
||||||
'configure 'copy-bootstrap-guile
|
'configure 'copy-bootstrap-guile
|
||||||
|
@ -139,19 +145,24 @@
|
||||||
;; correct value, so set it.
|
;; correct value, so set it.
|
||||||
(setenv "SHELL" (which "sh"))
|
(setenv "SHELL" (which "sh"))
|
||||||
#t))
|
#t))
|
||||||
(add-after
|
(add-after 'install 'wrap-program
|
||||||
'install 'wrap-program
|
|
||||||
(lambda* (#:key inputs outputs #:allow-other-keys)
|
(lambda* (#:key inputs outputs #:allow-other-keys)
|
||||||
;; Make sure the 'guix' command finds GnuTLS and
|
;; Make sure the 'guix' command finds GnuTLS and
|
||||||
;; Guile-JSON automatically.
|
;; Guile-JSON automatically.
|
||||||
(let* ((out (assoc-ref outputs "out"))
|
(let* ((out (assoc-ref outputs "out"))
|
||||||
|
(guile (assoc-ref inputs "guile"))
|
||||||
(json (assoc-ref inputs "guile-json"))
|
(json (assoc-ref inputs "guile-json"))
|
||||||
(ssh (assoc-ref inputs "guile-ssh"))
|
(ssh (assoc-ref inputs "guile-ssh"))
|
||||||
(gnutls (assoc-ref inputs "gnutls"))
|
(gnutls (assoc-ref inputs "gnutls"))
|
||||||
|
(effective
|
||||||
|
(read-line
|
||||||
|
(open-pipe* OPEN_READ
|
||||||
|
(string-append guile "/bin/guile")
|
||||||
|
"-c" "(display (effective-version))")))
|
||||||
(path (string-append
|
(path (string-append
|
||||||
json "/share/guile/site/2.0:"
|
json "/share/guile/site/" effective ":"
|
||||||
ssh "/share/guile/site/2.0:"
|
ssh "/share/guile/site/" effective ":"
|
||||||
gnutls "/share/guile/site/2.0")))
|
gnutls "/share/guile/site/" effective)))
|
||||||
|
|
||||||
(wrap-program (string-append out "/bin/guix")
|
(wrap-program (string-append out "/bin/guix")
|
||||||
`("GUILE_LOAD_PATH" ":" prefix (,path))
|
`("GUILE_LOAD_PATH" ":" prefix (,path))
|
||||||
|
|
Reference in New Issue