diff options
author | Parabola <dev@list.parabolagnulinux.org> | 2011-04-05 14:26:38 +0000 |
---|---|---|
committer | Parabola <dev@list.parabolagnulinux.org> | 2011-04-05 14:26:38 +0000 |
commit | 415856bdd4f48ab4f2732996f0bae58595092bbe (patch) | |
tree | ede2018b591f6dfb477fe9341ba17b9bc000fab9 /community/qbittorrent |
Tue Apr 5 14:26:38 UTC 2011
Diffstat (limited to 'community/qbittorrent')
-rw-r--r-- | community/qbittorrent/PKGBUILD | 42 | ||||
-rw-r--r-- | community/qbittorrent/python2.patch | 33 | ||||
-rw-r--r-- | community/qbittorrent/qbittorrent.install | 11 |
3 files changed, 86 insertions, 0 deletions
diff --git a/community/qbittorrent/PKGBUILD b/community/qbittorrent/PKGBUILD new file mode 100644 index 000000000..d22966eed --- /dev/null +++ b/community/qbittorrent/PKGBUILD @@ -0,0 +1,42 @@ +# Maintainer: Thomas Dziedzic < gostrc at gmail > +# Maintainer: Daniel J Griffiths <ghost1227@archlinux.us> +# Contributor: Geoffroy Carrier <geoffroy.carrier@koon.fr> + +pkgname=qbittorrent +pkgver=2.7.1 +pkgrel=1 +pkgdesc="A bittorrent client written in C++ / Qt4 using the good libtorrent library" +arch=('i686' 'x86_64') +url="http://www.qbittorrent.org/" +license=('GPL') +depends=('qt' 'libtorrent-rasterbar' 'xdg-utils') +makedepends=('boost' 'geoip') +optdepends=('python2: needed for search' + 'geoip: improves peer country resolution') +install='qbittorrent.install' +source=("http://downloads.sourceforge.net/sourceforge/qbittorrent/${pkgname}-${pkgver}.tar.gz" + 'python2.patch') +md5sums=('ce5c84cd0edc4c182466b207b3375423' + 'db0d79fee8ce3470ad3741d36b02a94c') + +build() { + cd ${pkgname}-${pkgver} + + sed -i \ + -e "s|#![ ]*/usr/bin/python$|#!/usr/bin/python2|" \ + -e "s|#![ ]*/usr/bin/env python$|#!/usr/bin/env python2|" \ + $(find ./ -name '*.py') + + patch -Np1 -i ${srcdir}/python2.patch + + ./configure \ + --prefix=/usr + + make +} + +package() { + cd ${pkgname}-${pkgver} + + make INSTALL_ROOT=${pkgdir} install +} diff --git a/community/qbittorrent/python2.patch b/community/qbittorrent/python2.patch new file mode 100644 index 000000000..24ab742db --- /dev/null +++ b/community/qbittorrent/python2.patch @@ -0,0 +1,33 @@ +diff -Nur qbittorrent-2.4.8.orig/src/searchengine/searchengine.cpp qbittorrent-2.4.8/src/searchengine.cpp +--- qbittorrent-2.4.8.orig/src/searchengine/searchengine.cpp 2010-10-01 13:52:53.000000000 -0700 ++++ qbittorrent-2.4.8/src/searchengine/searchengine.cpp 2010-10-25 01:20:20.046700620 -0700 +@@ -354,7 +354,7 @@ + //on change le texte du label courrant + currentSearchTab->getCurrentLabel()->setText(tr("Results")+" <i>(0)</i>:"); + // Launch search +- searchProcess->start("python", params, QIODevice::ReadOnly); ++ searchProcess->start("python2", params, QIODevice::ReadOnly); + searchTimeout->start(180000); // 3min + } + +@@ -421,7 +421,7 @@ + params << engine_url; + params << torrent_url; + // Launch search +- downloadProcess->start("python", params, QIODevice::ReadOnly); ++ downloadProcess->start("python2", params, QIODevice::ReadOnly); + } + } + +diff -Nur qbittorrent-2.4.8.orig/src/searchengine/supportedengines.h qbittorrent-2.4.8/src/supportedengines.h +--- qbittorrent-2.4.8.orig/src/searchengine/supportedengines.h 2010-10-24 01:32:39.000000000 -0700 ++++ qbittorrent-2.4.8/src/searchengine/supportedengines.h 2010-10-25 01:18:42.230032834 -0700 +@@ -144,7 +144,7 @@ + QStringList params; + params << misc::searchEngineLocation()+QDir::separator()+"nova2.py"; + params << "--capabilities"; +- nova.start("python", params, QIODevice::ReadOnly); ++ nova.start("python2", params, QIODevice::ReadOnly); + nova.waitForStarted(); + nova.waitForFinished(); + QString capabilities = QString(nova.readAll()); diff --git a/community/qbittorrent/qbittorrent.install b/community/qbittorrent/qbittorrent.install new file mode 100644 index 000000000..e70c054ec --- /dev/null +++ b/community/qbittorrent/qbittorrent.install @@ -0,0 +1,11 @@ +post_install() { + xdg-icon-resource forceupdate --theme hicolor &> /dev/null +} + +post_upgrade() { + post_install +} + +post_remove() { + post_install +} |