guix-commits
[Top][All Lists]
Advanced

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

02/09: gnu: sbcl-cl-cffi-gtk-gobject: Link source to parent to reduce cl


From: guix-commits
Subject: 02/09: gnu: sbcl-cl-cffi-gtk-gobject: Link source to parent to reduce closure size.
Date: Tue, 28 Apr 2020 05:50:25 -0400 (EDT)

ambrevar pushed a commit to branch master
in repository guix.

commit eac71f54fe561aadc02067d114c8f32ff3f359cb
Author: Pierre Neidhardt <address@hidden>
AuthorDate: Tue Apr 28 10:42:44 2020 +0200

    gnu: sbcl-cl-cffi-gtk-gobject: Link source to parent to reduce closure size.
    
    * gnu/packages/lisp-xyz.scm (sbcl-cl-cffi-gtk-gobject)[arguments]: Replace 
source
      folder with link to the same folder in the sbcl-cl-cffi-gtk-glib 
dependency.
---
 gnu/packages/lisp-xyz.scm | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index cc9bda8..b8efaf9 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -2916,7 +2916,20 @@ is a library for creating graphical user interfaces.")
            (lambda* (#:key inputs #:allow-other-keys)
              (substitute* "gobject/gobject.init.lisp"
                (("libgobject" all) (string-append
-                                    (assoc-ref inputs "glib") "/lib/" 
all))))))))))
+                                    (assoc-ref inputs "glib") "/lib/" all)))))
+         (add-after 'install 'link-source
+           ;; Since source is particularly heavy (16MiB+), let's reuse it
+           ;; across the different components of cl-ffi-gtk.
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((glib-source (string-append (assoc-ref inputs 
"cl-cffi-gtk-glib")
+                                               
"/share/common-lisp/sbcl-source/"
+                                               "cl-cffi-gtk-glib"))
+                   (out-source (string-append (assoc-ref outputs "out")
+                                              "/share/common-lisp/sbcl-source/"
+                                              "cl-cffi-gtk-gobject")))
+               (delete-file-recursively out-source)
+               (symlink glib-source out-source)
+               #t))))))))
 
 (define-public sbcl-cl-cffi-gtk-gio
   (package



reply via email to

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