libchop: Attempt to fix bug in Guile bindings; augment the expression.

svn path=/nixpkgs/trunk/; revision=30417
This commit is contained in:
Ludovic Courtès 2011-11-13 22:25:30 +00:00
parent c62c173944
commit c9e8f6fc40
2 changed files with 45 additions and 8 deletions

View File

@ -1,26 +1,48 @@
{ fetchurl, stdenv, zlib, bzip2, libgcrypt, gdbm, gperf, tdb, gnutls, db4, { fetchurl, stdenv, zlib, bzip2, libgcrypt, gdbm, gperf, tdb, gnutls, db4
libuuid, lzo, pkgconfig }: , libuuid, lzo, pkgconfig, guile }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
name = "libchop-0.5"; name = "libchop-0.5";
src = fetchurl { src = fetchurl {
url = "http://download.savannah.gnu.org/releases/libchop/libchop-0.5.tar.gz"; url = "mirror://savannah/libchop/${name}.tar.gz";
sha256 = "0i7gl0c99pf6794bbwm3iha6a0bciqq969mgwwv6gm9phiiy5s8b"; sha256 = "0i7gl0c99pf6794bbwm3iha6a0bciqq969mgwwv6gm9phiiy5s8b";
}; };
buildInputs = [ zlib libgcrypt gdbm gperf bzip2 db4 tdb gnutls libuuid lzo patches = [ ./guile-ascii-deserialize.patch ];
pkgconfig ];
buildNativeInputs = [ pkgconfig gperf ];
buildInputs =
[ zlib bzip2 lzo
libgcrypt
gdbm db4 tdb
gnutls libuuid
guile
];
doCheck = true; doCheck = true;
meta = { meta = {
description = "Set of utilities and library for data backup and distributed storage"; description = "libchop, tools & library for data backup and distributed storage";
longDescription =
'' Libchop is a set of utilities and library for data backup and
distributed storage. Its main application is chop-backup, an
encrypted backup program that supports data integrity checks,
versioning at little cost, distribution among several sites,
selective sharing of stored data, adaptive compression, and more.
The library itself, which chop-backup builds upon, implements
storage techniques such as content-based addressing, content hash
keys, Merkle trees, similarity detection, and lossless compression.
It makes it easy to combine them in different ways. The
chop-archiver and chop-block-server tools, illustrated in the
manual, provide direct access to these facilities from the command
line. It is written in C and has Guile (Scheme) bindings.
'';
homepage = http://nongnu.org/libchop/; homepage = http://nongnu.org/libchop/;
license = "GPLv3+"; license = "GPLv3+";
maintainers = [ stdenv.lib.maintainers.ludo maintainers = with stdenv.lib.maintainers; [ ludo viric ];
stdenv.lib.maintainers.viric ];
}; };
} }

View File

@ -0,0 +1,15 @@
This fixes `deserialize-object/ascii'.
diff --git a/guile2/chop/objects.scm b/guile2/chop/objects.scm
index 1849195..1aa521d 100644
--- a/guile2/chop/objects.scm
+++ b/guile2/chop/objects.scm
@@ -133,7 +133,7 @@
(define (deserialize-object/ascii class str)
"Deserialize STR and return a new instance of CLASS that corresponds."
- (%deserialize-object class (string->utf8 str) %ascii))
+ (%deserialize-object class (string->pointer str) %ascii))
(define (deserialize-object/binary class bv)
"Deserialize BV and return a new instance of CLASS that corresponds."