tribler: 7.1.2 -> 7.4.0-exp1 (python 3)

Updating version for tribler to use python 3.
One most notable change is dropping the optional `pythonPackages.meliae`
as it does not support python 3 and addition pony, lz4 and pyqtgraph.

Also cleaned up a few other dependencies and removed an old workaround
for broken ui-graphics.
This commit is contained in:
Dima 2019-11-25 20:32:28 +01:00
parent 332fd294ad
commit 7dd99adff8

View file

@ -1,48 +1,51 @@
{ stdenv, fetchurl, pythonPackages, makeWrapper, imagemagick { stdenv, fetchurl, pkgs, python3Packages, makeWrapper
, enablePlayer ? true, vlc ? null, qt5 }: , enablePlayer ? true, vlc ? null, qt5, lib }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
pname = "tribler"; pname = "tribler";
version = "7.1.2"; version = "7.4.0-exp1";
src = fetchurl { src = fetchurl {
url = "https://github.com/Tribler/tribler/releases/download/v${version}/Tribler-v${version}.tar.gz"; url = "https://github.com/Tribler/tribler/releases/download/v${version}/Tribler-v${version}.tar.xz";
sha256 = "1ayzqx4358qlx56hsnsn5s8xl6mzdb6nw4kwsalmp86dw6vmmis8"; sha256 = "18ziisg0v2gdxnprbhqsryz92yk270waj0la7m2h326k5qql3qkf";
}; };
buildInputs = [ nativeBuildInputs = [
pythonPackages.python python3Packages.wrapPython
pythonPackages.wrapPython
makeWrapper makeWrapper
imagemagick ];
buildInputs = [
python3Packages.python
]; ];
pythonPath = [ pythonPath = [
pythonPackages.libtorrentRasterbar python3Packages.libtorrentRasterbar
pythonPackages.apsw python3Packages.twisted
pythonPackages.twisted python3Packages.netifaces
pythonPackages.netifaces python3Packages.pycrypto
pythonPackages.pycrypto python3Packages.pyasn1
pythonPackages.pyasn1 python3Packages.requests
pythonPackages.requests python3Packages.m2crypto
pythonPackages.setuptools python3Packages.pyqt5
pythonPackages.m2crypto python3Packages.chardet
pythonPackages.pyqt5 python3Packages.cherrypy
pythonPackages.chardet python3Packages.cryptography
pythonPackages.cherrypy python3Packages.libnacl
pythonPackages.cryptography python3Packages.configobj
pythonPackages.libnacl python3Packages.decorator
pythonPackages.configobj python3Packages.feedparser
pythonPackages.matplotlib python3Packages.service-identity
pythonPackages.plyvel python3Packages.psutil
pythonPackages.decorator python3Packages.pillow
pythonPackages.feedparser python3Packages.networkx
pythonPackages.service-identity python3Packages.pony
pythonPackages.psutil python3Packages.lz4
pythonPackages.meliae python3Packages.pyqtgraph
pythonPackages.sip
pythonPackages.pillow # there is a BTC feature, but it requires some unclear version of
pythonPackages.networkx # bitcoinlib, so this doesn't work right now.
# python3Packages.bitcoinlib
]; ];
postPatch = '' postPatch = ''
@ -54,12 +57,11 @@ stdenv.mkDerivation rec {
''; '';
installPhase = '' installPhase = ''
find . -name '*.png' -exec convert -strip {} {} \;
mkdir -pv $out mkdir -pv $out
# Nasty hack; call wrapPythonPrograms to set program_PYTHONPATH. # Nasty hack; call wrapPythonPrograms to set program_PYTHONPATH.
wrapPythonPrograms wrapPythonPrograms
cp -prvd ./* $out/ cp -prvd ./* $out/
makeWrapper ${pythonPackages.python}/bin/python $out/bin/tribler \ makeWrapper ${python3Packages.python}/bin/python $out/bin/tribler \
--set QT_QPA_PLATFORM_PLUGIN_PATH ${qt5.qtbase.bin}/lib/qt-*/plugins/platforms \ --set QT_QPA_PLATFORM_PLUGIN_PATH ${qt5.qtbase.bin}/lib/qt-*/plugins/platforms \
--set _TRIBLERPATH $out \ --set _TRIBLERPATH $out \
--set PYTHONPATH $out:$program_PYTHONPATH \ --set PYTHONPATH $out:$program_PYTHONPATH \