aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py-sip/APKBUILD
blob: a2a29510ee1ad317d7703915c0f02cbc8370727f (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
# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer:  Francesco Colista <fcolista@alpinelinux.org>
pkgname=py-sip
_pkgname=sip
pkgver=4.17
pkgrel=0
pkgdesc="A tool that makes it easy to create Python bindings for C and C++ libraries"
url="http://www.riverbankcomputing.com/software/sip/"
arch="all"
license="custom:sip"
depends=""
depends_dev=""
makedepends="python-dev"
install=""
subpackages="$pkgname-dev"
source="http://sourceforge.net/projects/pyqt/files/sip/sip-$pkgver/sip-$pkgver.tar.gz"

_builddir="$srcdir"/$_pkgname-$pkgver
build() {
	cd "$_builddir"
	local sip_api_major_nr=$(sed -nre 's:^#define SIP_API_MAJOR_NR\s+([0-9]+):\1:p' siplib/sip.h.in)
	python configure.py
	make CC="${CC:-gcc}" \
		CXX="${CXX:-g++}" \
		CFLAGS="$CFLAGS -fPIC" \
		CXXFLAGS="$CXXFLAGS" \
		|| return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
	install -Dm644 LICENSE ${pkgdir}/usr/share/licenses/custom/${pkgname}/LICENSE
}

md5sums="ca51677770fa62dd5087877688cf97ba  sip-4.17.tar.gz"
sha256sums="603026822adf8673fca6e0ea20b02c3c4a2dccb309647656f7269adc8de89060  sip-4.17.tar.gz"
sha512sums="ac9af0b0e8424152a9768bccacd4db393fd3f4e5c8cf171863d9e615564c744c5be4d0b4af82c5ceed8d27f9845e308f559df30153e6d5bce8d4e2af6e5192d9  sip-4.17.tar.gz"