aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/guile.scm
diff options
context:
space:
mode:
authorMark H Weaver <mhw@netris.org>2018-03-18 08:43:06 -0400
committerMark H Weaver <mhw@netris.org>2018-03-18 23:30:31 -0400
commit56f31a9fd5806d490570550a0446d41502c6c6eb (patch)
tree2862482a33280d2e6095f6dbedb59699b6f0e27c /gnu/packages/guile.scm
parent07e36357a51a62ce14afd19a3187ddf6a813cf0a (diff)
downloadpatches-56f31a9fd5806d490570550a0446d41502c6c6eb.tar
patches-56f31a9fd5806d490570550a0446d41502c6c6eb.tar.gz
gnu: guile-gdbm-ffi: Add support for gdbm-1.14.
* gnu/packages/patches/guile-gdbm-ffi-support-gdbm-1.14.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/guile.scm (guile-gdbm-ffi)[inputs]: Move above arguments. Add the patch, and the 'patch' program. [propagated-inputs]: Move above arguments. [arguments]: In the builder, add code to apply the patch.
Diffstat (limited to 'gnu/packages/guile.scm')
-rw-r--r--gnu/packages/guile.scm21
1 files changed, 17 insertions, 4 deletions
diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm
index 1c8eaa9ec5..f6f8ef9b95 100644
--- a/gnu/packages/guile.scm
+++ b/gnu/packages/guile.scm
@@ -1134,6 +1134,15 @@ inspired by the SCSH regular expression system.")
(base32
"1j8wrsw7v9w6qkl47xz0rdikg50v16nn6kbs3lgzcymjzpa7babj"))))
(build-system trivial-build-system)
+ (inputs
+ `(("guile" ,guile-2.2)
+ ;; patch-and-repack doesn't work for git checkouts,
+ ;; so we must apply the patch manually.
+ ("patch" ,patch)
+ ("patch-file" ,(search-patch
+ "guile-gdbm-ffi-support-gdbm-1.14.patch"))))
+ (propagated-inputs
+ `(("gdbm" ,gdbm)))
(arguments
`(#:modules
((guix build utils))
@@ -1186,12 +1195,16 @@ inspired by the SCSH regular expression system.")
(format #f "(dynamic-link \"~a/lib/libgdbm.so\")"
(assoc-ref %build-inputs "gdbm"))))
+ ;; Apply the patch to add support for gdbm-1.14.
+ (let ((patch-command (string-append (assoc-ref %build-inputs "patch")
+ "/bin/patch"))
+ (patch-file (assoc-ref %build-inputs "patch-file")))
+ (with-directory-excursion (dirname gdbm.scm-dest)
+ (format #t "applying '~a'...~%" patch-file)
+ (invoke patch-command "--force" "--input" patch-file)))
+
;; compile to the destination
(compile-file gdbm.scm-dest gdbm.go-dest)))))
- (inputs
- `(("guile" ,guile-2.2)))
- (propagated-inputs
- `(("gdbm" ,gdbm)))
(home-page "https://github.com/ijp/guile-gdbm")
(synopsis "Guile bindings to the GDBM library via Guile's FFI")
(description