pull: Add a dependency to guile-git.

* build-aux/build-self.scm (guile-git, guile-bytestructures): New
  variables.
  (build): Add guile-git and guile-bytestructures to %load-path and
  %load-compiled-path.
This commit is contained in:
Mathieu Othacehe 2017-06-07 13:44:47 +02:00
parent 6b7b3ca981
commit 19c90e5f69
No known key found for this signature in database
GPG Key ID: 8354763531769CA6
1 changed files with 41 additions and 11 deletions

View File

@ -97,6 +97,13 @@ Guile major version (2.0 or 2.2), or #f if none of the packages matches."
"guile2.2-ssh" "guile2.2-ssh"
"guile2.0-ssh")) "guile2.0-ssh"))
(define guile-git
(package-for-current-guile "guile-git"
"guile2.0-git"))
(define guile-bytestructures
(package-for-current-guile "guile-bytestructures"
"guile2.0-bytestructures"))
;; The actual build procedure. ;; The actual build procedure.
@ -148,18 +155,41 @@ files."
#~(begin #~(begin
(use-modules (guix build pull)) (use-modules (guix build pull))
(let ((json (string-append #$guile-json "/share/guile/site/" (letrec-syntax ((maybe-load-path
#$(effective-version)))) (syntax-rules ()
(set! %load-path ((_ item rest ...)
(cons* json (let ((tail (maybe-load-path rest ...)))
(string-append #$guile-ssh "/share/guile/site/" (if (string? item)
(cons (string-append item
"/share/guile/site/"
#$(effective-version)) #$(effective-version))
%load-path)) tail)
(set! %load-compiled-path tail)))
(cons* json ((_)
(string-append #$guile-ssh "/lib/guile/" '()))))
(set! %load-path
(append
(maybe-load-path #$guile-json #$guile-ssh
#$guile-git #$guile-bytestructures)
%load-path)))
(letrec-syntax ((maybe-load-compiled-path
(syntax-rules ()
((_ item rest ...)
(let ((tail (maybe-load-compiled-path rest ...)))
(if (string? item)
(cons (string-append item
"/lib/guile/"
#$(effective-version) #$(effective-version)
"/site-ccache") "/site-ccache")
tail)
tail)))
((_)
'()))))
(set! %load-compiled-path
(append
(maybe-load-compiled-path #$guile-json #$guile-ssh
#$guile-git #$guile-bytestructures)
%load-compiled-path))) %load-compiled-path)))
;; XXX: The 'guile-ssh' package prior to Guix commit 92b7258 was ;; XXX: The 'guile-ssh' package prior to Guix commit 92b7258 was