2009-08-11 09:11:13 +01:00
|
|
|
{ fetchurl, lib, unzip, buildPythonPackage, twisted, foolscap, nevow
|
2009-07-07 23:44:29 +01:00
|
|
|
, simplejson, zfec, pycryptopp, pysqlite, nettools }:
|
2009-06-28 22:03:00 +01:00
|
|
|
|
|
|
|
buildPythonPackage (rec {
|
2009-10-31 22:34:24 +00:00
|
|
|
name = "tahoe-lafs-1.5.0";
|
2009-06-28 22:03:00 +01:00
|
|
|
namePrefix = "";
|
|
|
|
|
|
|
|
src = fetchurl {
|
2009-10-31 22:34:24 +00:00
|
|
|
url = "http://allmydata.org/source/tahoe/releases/allmydata-tahoe-1.5.0.zip";
|
2009-08-11 09:11:13 +01:00
|
|
|
sha256 = "1cgwm7v49mlfsq47k8gw2bz14d6lnls0mr6dc18815pf24z4f00n";
|
2009-06-28 22:03:00 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
patchPhase = ''
|
2009-10-31 22:34:24 +00:00
|
|
|
echo "forcing the use of \`setuptools' 0.6c9 rather than an unreleased version"
|
2009-06-28 22:03:00 +01:00
|
|
|
for i in *setup.py
|
|
|
|
do
|
|
|
|
sed -i "$i" -es'/0.6c12dev/0.6c9/g'
|
|
|
|
done
|
|
|
|
|
|
|
|
# `find_exe()' returns a list like ['.../bin/python'
|
|
|
|
# '.../bin/twistd'], which doesn't work when `twistd' is not a
|
|
|
|
# Python script (e.g., when it's a script produced by
|
|
|
|
# `wrapProgram').
|
|
|
|
sed -i "src/allmydata/scripts/startstop_node.py" \
|
|
|
|
-es"|cmd = find_exe.find_exe('twistd')|cmd = ['${twisted}/bin/twistd']|g"
|
|
|
|
|
|
|
|
sed -i "src/allmydata/util/iputil.py" \
|
|
|
|
-es"|_linux_path = '/sbin/ifconfig'|_linux_path = '${nettools}/sbin/ifconfig'|g"
|
|
|
|
'';
|
|
|
|
|
|
|
|
buildInputs = [ unzip ];
|
2009-07-07 23:44:29 +01:00
|
|
|
|
|
|
|
# The `backup' command works best with `pysqlite'.
|
2009-06-28 22:03:00 +01:00
|
|
|
propagatedBuildInputs = [
|
2009-07-07 23:44:29 +01:00
|
|
|
twisted foolscap nevow simplejson zfec pycryptopp pysqlite
|
2009-06-28 22:03:00 +01:00
|
|
|
];
|
|
|
|
|
|
|
|
# FIXME: Many tests try to write to the Nix store or to $HOME, which
|
|
|
|
# fails. Disable tests until we have a reasonable hack to allow
|
|
|
|
# them to run.
|
|
|
|
doCheck = false;
|
|
|
|
|
2009-08-11 17:26:12 +01:00
|
|
|
postInstall = ''
|
|
|
|
# Install the documentation.
|
|
|
|
|
2009-10-31 22:34:24 +00:00
|
|
|
# FIXME: Inkscape segfaults when run from here. Setting $HOME to
|
2009-08-11 17:26:12 +01:00
|
|
|
# something writable doesn't help; providing $FONTCONFIG_FILE doesn't
|
|
|
|
# help either. So we just don't run `make' under `docs/'.
|
|
|
|
|
|
|
|
ensureDir "$out/share/doc/${name}"
|
|
|
|
cp -rv "docs/"* "$out/share/doc/${name}"
|
|
|
|
find "$out/share/doc/${name}" -name Makefile -exec rm -v {} \;
|
|
|
|
'';
|
|
|
|
|
2009-06-28 22:03:00 +01:00
|
|
|
meta = {
|
2009-10-31 22:34:24 +00:00
|
|
|
description = "Tahoe-LAFS, a decentralized, fault-tolerant, distributed storage system";
|
2009-06-28 22:03:00 +01:00
|
|
|
|
|
|
|
longDescription = ''
|
2009-10-31 22:34:24 +00:00
|
|
|
Tahoe-LAFS is a secure, decentralized, fault-tolerant filesystem.
|
2009-06-28 22:03:00 +01:00
|
|
|
This filesystem is encrypted and spread over multiple peers in
|
|
|
|
such a way that it remains available even when some of the peers
|
|
|
|
are unavailable, malfunctioning, or malicious.
|
|
|
|
'';
|
|
|
|
|
|
|
|
homepage = http://allmydata.org/;
|
|
|
|
|
2009-10-31 22:34:24 +00:00
|
|
|
license = [ "GPLv2+" /* or */ "TGPPLv1+" ];
|
2009-08-11 09:11:13 +01:00
|
|
|
|
|
|
|
maintainers = [ lib.maintainers.ludo ];
|
2009-06-28 22:03:00 +01:00
|
|
|
};
|
|
|
|
})
|