aboutsummaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorMarius Bakke <mbakke@fastmail.com>2018-07-30 16:22:04 +0200
committerMarius Bakke <mbakke@fastmail.com>2018-07-30 16:22:04 +0200
commitb4052c96ee252bd65ede6b7f0983942cb653a36c (patch)
tree1ad92d4b5041cc416bfcf360194e3778c954f926 /gnu
parentd37d975b748f65a1ace4b2434d04e30ed558a7a8 (diff)
downloadguix-b4052c96ee252bd65ede6b7f0983942cb653a36c.tar
guix-b4052c96ee252bd65ede6b7f0983942cb653a36c.tar.gz
gnu: nettle: Move static libraries to separate output.
* gnu/packages/nettle.scm (nettle-2)[outputs]: Add "static". [arguments]: Add #:phases.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/nettle.scm18
1 files changed, 16 insertions, 2 deletions
diff --git a/gnu/packages/nettle.scm b/gnu/packages/nettle.scm
index 67a3062a5a..1212f32812 100644
--- a/gnu/packages/nettle.scm
+++ b/gnu/packages/nettle.scm
@@ -44,8 +44,22 @@
;; $libdir, which is not the case by default. Work around it.
'(#:configure-flags (list (string-append "LDFLAGS=-Wl,-rpath="
(assoc-ref %outputs "out")
- "/lib"))))
- (outputs '("out" "debug"))
+ "/lib"))
+ #:phases (modify-phases %standard-phases
+ (add-after 'install 'move-static-libraries
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out"))
+ (slib (string-append (assoc-ref outputs "static")
+ "/lib")))
+ (mkdir-p slib)
+ (with-directory-excursion (string-append out "/lib")
+ (for-each (lambda (ar)
+ (rename-file ar (string-append
+ slib "/"
+ (basename ar))))
+ (find-files "." "\\.a$")))
+ #t))))))
+ (outputs '("out" "debug" "static"))
(native-inputs `(("m4" ,m4)))
(propagated-inputs `(("gmp" ,gmp)))
(home-page "https://www.lysator.liu.se/~nisse/nettle/")