summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 1e8467ccb6933c376d6af798ef5fbc993d3c0498 (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
43
44
45
46
47
# Maintainer: Fabio 'Lolix' Loli <fabio.loli@disroot.org> -> https://github.com/FabioLolix
# Contributor: Helder Bertoldo <helder.bertoldo@gmail.com>

pkgname=torrential-git
pkgver=1.1.0.r15.gd950ce8
pkgrel=1
pkgdesc="Download torrents in style with this speedy, minimalist torrent client designed for Pantheon Shell"
arch=(i686 x86_64)
url="https://github.com/davidmhewitt/torrential"
license=(GPL2)
depends=(libgranite.so libunity libevent libnatpmp libb64 dht miniupnpc libutp)
makedepends=(git cmake vala0.42)
provides=(torrential)
conflicts=(torrential)
source=("git+https://github.com/davidmhewitt/torrential.git"
        "torrential-transmission::git+https://github.com/davidmhewitt/transmission.git#branch=2.9x-torrential")
md5sums=('SKIP'
         'SKIP')

pkgver() {
  cd "${pkgname%-git}"
  git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}

prepare() {
  cd "${pkgname%-git}"
  git submodule init
  git config 'submodule.transmission.url' "${srcdir}/torrential-transmission"
  git submodule update

  install -d build
}

build() {
  cd "${pkgname%-git}/build"
  cmake .. \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr
  make
}

package() {
  cd "${pkgname%-git}/build"
  make DESTDIR="${pkgdir}" install
  ln -s /usr/bin/com.github.davidmhewitt.torrential "$pkgdir/usr/bin/torrential"
}