summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: c26a7f47a3071b99b7b594a39ea810ea99c4fda1 (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
48
49
50
51
# Maintainer: Stephan Springer <buzo+arch@Lini.de>
# Contributor: inemum (https://gitlab.com/inemum)
# Contributor: graysky <graysky AT archlinux DOT us>
# Contributor: Fredrick Brennan <copypaste@kittens.ph>

# based on https://git.archlinux.org/svntogit/packages.git/tree/trunk/PKGBUILD?h=packages/sip

pkgbase=('python-sip-pyqt4')
pkgname=('python-sip-pyqt4' 'python2-sip-pyqt4')
pkgver=4.19.16
pkgrel=1
arch=('x86_64')
url='http://www.riverbankcomputing.com/software/sip/intro'
license=('custom:"sip"')
makedepends=('python' 'python2')
source=("https://www.riverbankcomputing.com/static/Downloads/sip/$pkgver/sip-$pkgver.tar.gz")
sha256sums=('184c790d58e9527fc6bdac2bbf8638f3d1b41dea922cad8eb83172b4ba70c620')

prepare() {
  mkdir -p build-pyqt4{,-py2}
}

build() {
  cd "$srcdir"/build-pyqt4
  python ../sip-$pkgver/configure.py CFLAGS="$CFLAGS" LFLAGS="$LDFLAGS" --sip-module PyQt4.sip --no-tools
  make

  cd "$srcdir"/build-pyqt4-py2
  python2 ../sip-$pkgver/configure.py CFLAGS="$CFLAGS" LFLAGS="$LDFLAGS" --sip-module PyQt4.sip --no-tools
  make
}

package_python-sip-pyqt4() {
  pkgdesc="Python 3.x SIP bindings for C and C++ libraries (PyQt4 version)"
  depends=('python')

  cd build-pyqt4
  make DESTDIR="$pkgdir" install

  install -Dm644 ../sip-$pkgver/LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}

package_python2-sip-pyqt4() {
  pkgdesc="Python 2.x SIP bindings for C and C++ libraries (PyQt4 version)"
  depends=('python2')

  cd build-pyqt4-py2
  make DESTDIR="$pkgdir" install

  install -Dm644 ../sip-$pkgver/LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}