guix-commits
[Top][All Lists]
Advanced

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

02/17: gnu: bzip2: Add static output.


From: Marius Bakke
Subject: 02/17: gnu: bzip2: Add static output.
Date: Sun, 22 Jul 2018 12:00:09 -0400 (EDT)

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

commit 45719c1dfb7bdce3c91086e5bed26643dccf8191
Author: Marius Bakke <address@hidden>
Date:   Sat Jul 14 22:39:01 2018 +0200

    gnu: bzip2: Add static output.
    
    * gnu/packages/compression.scm (bzip2)[arguments]: Add phase for moving 
static
    library.
    [outputs]: New field.
---
 gnu/packages/compression.scm | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/gnu/packages/compression.scm b/gnu/packages/compression.scm
index 7453b07..c82edcc 100644
--- a/gnu/packages/compression.scm
+++ b/gnu/packages/compression.scm
@@ -293,6 +293,14 @@ file; as a result, it is often used in conjunction with 
\"tar\", resulting in
                        (symlink so-file base)
                        (loop so-file (cdr numbers))))))
                #t)))
+         (add-after 'install-shared-lib 'move-static-lib
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let ((out (assoc-ref outputs "out"))
+                   (static (assoc-ref outputs "static")))
+               (with-directory-excursion (string-append out "/lib")
+                 (install-file "libbz2.a" (string-append static "/lib"))
+                 (delete-file "libbz2.a")
+                 #t))))
          (add-after 'install-shared-lib 'patch-scripts
            (lambda* (#:key outputs inputs #:allow-other-keys)
              (let* ((out (assoc-ref outputs "out")))
@@ -307,6 +315,7 @@ file; as a result, it is often used in conjunction with 
\"tar\", resulting in
        ,@(if (%current-target-system)
              '(#:tests? #f)
              '())))
+    (outputs '("out" "static"))
     (synopsis "High-quality data compression program")
     (description
      "bzip2 is a freely available, patent free (see below), high-quality data



reply via email to

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