summaryrefslogtreecommitdiff
path: root/pcr/h-client/PKGBUILD
blob: 489aedb5c8748312374faea5ca444248551955c6 (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
# Maintainer: Omar Vega Ramos <ovruni@gnu.org.pe>
# Contributor: Michał Masłowski <mtjm@mtjm.eu>

pkgname=h-client
pkgver=0.0a0.dev134
pkgrel=1
epoch=1
pkgdesc="A client for an h-source server (such as https://www.h-node.org/)"
arch=('any')
url="https://savannah.nongnu.org/projects/h-client/"
license=('GPL3')
depends=('python2' 'python2-distribute' 'python2-pycurl' 'pygtk' 'pciutils' 'usbutils')
makedepends=('subversion')
options=(!emptydirs)
source=("svn+http://svn.savannah.nongnu.org/svn/${pkgname}/trunk/${pkgname}"
        'h-client-fix_test.patch')
sha256sums=('SKIP'
            'df842c88bb5bcf6a97db1e2ea813f7f968d9b2e8460a16a4359d62240eb44d1a')

prepare() {
  cd "$srcdir/${pkgname}"
  sed -i "s/dev/dev134/g" setup.cfg
  sed -i "s/tag_svn_revision = 1//g" setup.cfg
  sed -i "s/'h-node.org'/'https:\/\/h-node.org'/g" hclient/gtkclient.py
  patch -Np1 -i "$srcdir/h-client-fix_test.patch"
}

build() {
  cd "$srcdir/${pkgname}"
  make
}

check() {
  cd "$srcdir/${pkgname}"
  python2 setup.py test
}

package() {
  cd "$srcdir/${pkgname}"
  python2 setup.py install --root="$pkgdir/" --optimize=1
  make DESTDIR="$pkgdir" prefix=/usr install-data
}

# vim:set ts=2 sw=2 et: