summaryrefslogtreecommitdiff
path: root/community/qbittorrent/PKGBUILD
blob: 3a76900e5cf9c15c5a728965a40fc19fdeadf3f4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
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.8.1
pkgrel=1
pkgdesc="A bittorrent client written in C++ / Qt4 using the good libtorrent library"
arch=('i686' 'x86_64' 'mips64el')
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/qbittorrent-${pkgver}.tar.gz"
        'python2.patch')
md5sums=('4fb4490117a0909f1f0989b4b797b41a'
         'db0d79fee8ce3470ad3741d36b02a94c')

build() {
  cd qbittorrent-${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 qbittorrent-${pkgver}

  make INSTALL_ROOT=${pkgdir} install
}