guix-commits
[Top][All Lists]
Advanced

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

01/02: gnu: guile-static: Reuse the existing phases.


From: Ludovic Courtès
Subject: 01/02: gnu: guile-static: Reuse the existing phases.
Date: Sat, 30 Dec 2017 19:21:03 -0500 (EST)

civodul pushed a commit to branch core-updates
in repository guix.

commit c99a64e15f19228ce03a683cae6e5b12d6bc1be3
Author: Ludovic Courtès <address@hidden>
Date:   Sun Dec 31 00:35:06 2017 +0100

    gnu: guile-static: Reuse the existing phases.
    
    This is a followup to 33c3a214a4194a34b534bccf76bdd05db8ee565b.
    
    * gnu/packages/make-bootstrap.scm (%guile-static)[arguments]: Use
    'substitute-keyword-arguments'.  Honor the existing phases.
---
 gnu/packages/make-bootstrap.scm | 49 +++++++++++++++++++++--------------------
 1 file changed, 25 insertions(+), 24 deletions(-)

diff --git a/gnu/packages/make-bootstrap.scm b/gnu/packages/make-bootstrap.scm
index 492ccb8..4b81f73 100644
--- a/gnu/packages/make-bootstrap.scm
+++ b/gnu/packages/make-bootstrap.scm
@@ -520,30 +520,31 @@ for `sh' in $PATH, and without nscd, and with static NSS 
modules."
                      ,@(alist-delete "bdw-gc"
                                      (package-propagated-inputs guile-2.2))))
                   (arguments
-                   `(;; When `configure' checks for ltdl availability, it
-                     ;; doesn't try to link using libtool, and thus fails
-                     ;; because of a missing -ldl.  Work around that.
-                     #:configure-flags '("LDFLAGS=-ldl")
-
-                     #:phases (alist-cons-before
-                               'configure 'static-guile
-                               (lambda _
-                                 (substitute* "libguile/Makefile.in"
-                                   ;; Create a statically-linked `guile'
-                                   ;; executable.
-                                   (("^guile_LDFLAGS =")
-                                    "guile_LDFLAGS = -all-static")
-
-                                   ;; Add `-ldl' *after* libguile-2.2.la.
-                                   (("^guile_LDADD =(.*)$" _ ldadd)
-                                    (string-append "guile_LDADD = "
-                                                   (string-trim-right ldadd)
-                                                   " -ldl\n"))))
-                               %standard-phases)
-
-                     ;; There are uses of `dynamic-link' in
-                     ;; {foreign,coverage}.test that don't fly here.
-                     #:tests? #f)))))
+                   (substitute-keyword-arguments (package-arguments guile-2.2)
+                     ((#:configure-flags flags '())
+                      ;; When `configure' checks for ltdl availability, it
+                      ;; doesn't try to link using libtool, and thus fails
+                      ;; because of a missing -ldl.  Work around that.
+                      ''("LDFLAGS=-ldl"))
+                     ((#:phases phases '%standard-phases)
+                      `(modify-phases ,phases
+                         (add-before 'configure 'static-guile
+                           (lambda _
+                             (substitute* "libguile/Makefile.in"
+                               ;; Create a statically-linked `guile'
+                               ;; executable.
+                               (("^guile_LDFLAGS =")
+                                "guile_LDFLAGS = -all-static")
+
+                               ;; Add `-ldl' *after* libguile-2.2.la.
+                               (("^guile_LDADD =(.*)$" _ ldadd)
+                                (string-append "guile_LDADD = "
+                                               (string-trim-right ldadd)
+                                               " -ldl\n")))))))
+                     ((#:tests? _ #f)
+                      ;; There are uses of `dynamic-link' in
+                      ;; {foreign,coverage}.test that don't fly here.
+                      #f))))))
     (package-with-relocatable-glibc (static-package guile))))
 
 (define %guile-static-stripped



reply via email to

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