2012-02-15 16:24:02 +00:00
|
|
|
{ stdenv, fetchsvn, pythonPackages, makeWrapper, nettools
|
|
|
|
, enablePlayer ? false, vlc ? null }:
|
2011-05-03 17:12:31 +00:00
|
|
|
|
2012-03-13 17:35:11 +00:00
|
|
|
let rev = "25411"; in
|
2011-09-02 11:11:48 +00:00
|
|
|
|
2011-05-03 17:12:31 +00:00
|
|
|
stdenv.mkDerivation {
|
2012-03-13 17:35:11 +00:00
|
|
|
name = "tribler-5.5.21-pre${rev}";
|
2011-05-03 17:12:31 +00:00
|
|
|
|
|
|
|
src = fetchsvn {
|
2012-02-08 16:46:09 +00:00
|
|
|
url = http://svn.tribler.org/abc/branches/release-5.5.x;
|
2011-09-02 11:11:48 +00:00
|
|
|
inherit rev;
|
2012-03-13 17:35:11 +00:00
|
|
|
sha256 = "17c9svy4zjchzihk6mf0kh4lnvaxjfmgfmimyby5w0d3cwbw49zx";
|
2011-05-03 17:12:31 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ pythonPackages.python pythonPackages.wrapPython makeWrapper ];
|
|
|
|
|
|
|
|
pythonPath =
|
2012-02-21 23:35:35 +00:00
|
|
|
[ pythonPackages.wxPython pythonPackages.curses pythonPackages.apsw
|
2011-05-03 17:12:31 +00:00
|
|
|
pythonPackages.setuptools pythonPackages.m2crypto pythonPackages.sqlite3
|
|
|
|
];
|
|
|
|
|
|
|
|
installPhase =
|
|
|
|
''
|
|
|
|
substituteInPlace Tribler/Core/NATFirewall/guessip.py \
|
|
|
|
--replace /bin/netstat ${nettools}/bin/netstat \
|
|
|
|
--replace /sbin/ifconfig ${nettools}/sbin/ifconfig
|
|
|
|
|
|
|
|
# Nasty hack; call wrapPythonPrograms to set program_PYTHONPATH.
|
|
|
|
wrapPythonPrograms
|
|
|
|
|
|
|
|
mkdir -p $out/share/tribler
|
|
|
|
cp -prvd Tribler $out/share/tribler/
|
|
|
|
|
|
|
|
makeWrapper ${pythonPackages.python}/bin/python $out/bin/tribler \
|
|
|
|
--set _TRIBLERPATH $out/share/tribler \
|
|
|
|
--set PYTHONPATH $out/share/tribler:$program_PYTHONPATH \
|
|
|
|
--run 'cd $_TRIBLERPATH' \
|
2012-02-15 16:24:02 +00:00
|
|
|
--add-flags "-O $out/share/tribler/Tribler/Main/tribler.py" \
|
|
|
|
${stdenv.lib.optionalString enablePlayer ''
|
|
|
|
--prefix LD_LIBRARY_PATH : ${vlc}/lib
|
|
|
|
''}
|
2011-05-03 17:12:31 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = http://www.tribler.org/;
|
|
|
|
description = "A completely decentralised P2P filesharing client based on the Bittorrent protocol";
|
2014-06-19 04:19:00 +00:00
|
|
|
license = stdenv.lib.licenses.lgpl21;
|
2011-05-03 17:12:31 +00:00
|
|
|
};
|
|
|
|
}
|