# Maintainer: Antonio Rojas <arojas@archlinux.org>
# Contributor: Ronald van Haren <ronald.archlinux.org>
# Contributor: Andrea Scarpino <andrea@archlinux.org>

pkgname=libktorrent
pkgver=2.1.1
_ktorrentver=5.1.2
pkgrel=1
pkgdesc="A BitTorrent protocol implementation"
arch=(x86_64)
url="https://www.kde.org/applications/internet/ktorrent/"
license=(GPL2)
depends=(kio qca-qt5)
makedepends=(extra-cmake-modules boost doxygen)
source=("https://download.kde.org/stable/ktorrent/$_ktorrentver/$pkgname-$pkgver.tar.xz"{,.sig})
sha256sums=('5cc45c0b50a1b6b2ce64ad0384128f4ac3bc0e4a1417eb58e5e992b510fca100'
            'SKIP')
validpgpkeys=(1EE5A3205904BAA2B88C0A9D24FD31940095C0E1) # Andrius Štikonas <andrius@stikonas.eu>

prepare() {
  mkdir -p build
}

build() {
  cd build
  cmake ../$pkgname-$pkgver
  make
}

package() {
  cd build
  make DESTDIR="$pkgdir" install
}
