[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/02: gnu: cuirass: Add dependency on Guile-Gcrypt.

From: Ludovic Courtès
Subject: 02/02: gnu: cuirass: Add dependency on Guile-Gcrypt.
Date: Wed, 5 Sep 2018 09:36:00 -0400 (EDT)

civodul pushed a commit to branch master
in repository guix.

commit 7903f00a74871ac4ecd41878ac9846fdae91e276
Author: Ludovic Courtès <address@hidden>
Date:   Wed Sep 5 14:46:28 2018 +0200

    gnu: cuirass: Add dependency on Guile-Gcrypt.
    This is a followup to 53166aec987957efba917c83f093817d6cf6e943, which
    added a hard dependency of Guix on Guile-Gcrypt.
    * gnu/packages/ci.scm (cuirass)[inputs]: Add GUILE-GCRYPT.
    [arguments]: In 'wrap-program' phase, use 'string-join' to compute
    'mods'.  Define 'objs' for use in GUILE_LOAD_COMPILED_PATH, and take
    objects from lib/guile/X.Y/site-ccache.
 gnu/packages/ci.scm | 30 +++++++++++++++++-------------
 1 file changed, 17 insertions(+), 13 deletions(-)

diff --git a/gnu/packages/ci.scm b/gnu/packages/ci.scm
index e26983d..067a288 100644
--- a/gnu/packages/ci.scm
+++ b/gnu/packages/ci.scm
@@ -32,6 +32,7 @@
   #:use-module (gnu packages compression)
   #:use-module (gnu packages databases)
   #:use-module (gnu packages guile)
+  #:use-module (gnu packages gnupg)
   #:use-module (gnu packages mail)
   #:use-module (gnu packages package-management)
   #:use-module (gnu packages perl)
@@ -223,39 +224,42 @@ their dependencies.")
              (lambda* (#:key inputs outputs #:allow-other-keys)
                ;; Wrap the 'cuirass' command to refer to the right modules.
                (let* ((out    (assoc-ref outputs "out"))
+                      (gcrypt (assoc-ref inputs "guile-gcrypt"))
                       (json   (assoc-ref inputs "guile-json"))
                       (sqlite (assoc-ref inputs "guile-sqlite3"))
                       (git    (assoc-ref inputs "guile-git"))
                       (bytes  (assoc-ref inputs "guile-bytestructures"))
                       (fibers (assoc-ref inputs "guile-fibers"))
                       (guix   (assoc-ref inputs "guix"))
+                      (deps   (list gcrypt json sqlite git bytes fibers guix))
                       (guile  (assoc-ref %build-inputs "guile"))
                       (effective (read-line
                                   (open-pipe* OPEN_READ
                                               (string-append guile 
                                               "-c" "(display 
-                      (mods   (string-append json "/share/guile/site/"
-                                             effective ":"
-                                             git "/share/guile/site/"
-                                             effective ":"
-                                             bytes "/share/guile/site/"
-                                             effective ":"
-                                             sqlite "/share/guile/site/"
-                                             effective ":"
-                                             fibers "/share/guile/site/"
-                                             effective ":"
-                                             guix "/share/guile/site/"
-                                             effective)))
+                      (mods   (string-drop-right  ;drop trailing colon
+                               (string-join deps
+                                            (string-append "/share/guile/site/"
+                                                           effective ":")
+                                            'suffix)
+                               1))
+                      (objs   (string-drop-right
+                               (string-join deps
+                                            (string-append "/lib/guile/" 
+                                                           "/site-ccache:")
+                                            'suffix)
+                               1)))
                  ;; Make sure 'cuirass' can find the 'evaluate' command, as
                  ;; well as the relevant Guile modules.
                  (wrap-program (string-append out "/bin/cuirass")
                    `("PATH" ":" prefix (,(string-append out "/bin")))
                    `("GUILE_LOAD_PATH" ":" prefix (,mods))
-                   `("GUILE_LOAD_COMPILED_PATH" ":" prefix (,mods)))
+                   `("GUILE_LOAD_COMPILED_PATH" ":" prefix (,objs)))
        `(("guile" ,guile-2.2)
          ("guile-fibers" ,guile-fibers)
+         ("guile-gcrypt" ,guile-gcrypt)
          ("guile-json" ,guile-json)
          ("guile-sqlite3" ,guile-sqlite3)
          ("guile-git" ,guile-git)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]