blob: 437976a45abd6d0d9b4a150e594b96ce0b0ea416 (
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
|
# $Id: PKGBUILD 95395 2013-08-10 22:18:43Z eric $
# Maintainer: Kaiting Chen <kaitocracy@gmail.com>
# Maintainer: Stéphane Gaudreault <stephane@archlinux.org>
# Contributor: Douglas Soares de Andrade <dsandrade@gmail.com>
# Contributor: William Rea <sillywilly@gmail.com>
pkgbase=python-bsddb
pkgname=('python2-bsddb' 'python-bsddb')
pkgver=6.0.0
pkgrel=1
pkgdesc="Python interface for BerkeleyDB"
license=('MIT')
arch=('i686' 'x86_64')
url="http://www.jcea.es/programacion/pybsddb.htm"
makedepends=('python2-distribute' 'python-distribute')
source=(http://pypi.python.org/packages/source/b/bsddb3/bsddb3-${pkgver}.tar.gz
LICENSE)
sha1sums=('ca5c204b2c9cf4fff396ba3d49994fe1a95d669f'
'ef4e4caf618781104dbf5824279ed39d127b4713')
prepare() {
cp -r bsddb3-${pkgver}{,-python2}
}
build () {
# Build python 3 module
cd bsddb3-${pkgver}
python3 setup.py --berkeley-db=/usr build
# Build python 2 module
cd ../bsddb3-${pkgver}-python2
python2 setup.py --berkeley-db=/usr build
}
package_python2-bsddb() {
depends=('db' 'python2>=2.7')
cd bsddb3-${pkgver}-python2
python2 setup.py --berkeley-db=/usr install --root="${pkgdir}" --skip-build --optimize=1
sed -i 's|/usr/bin/env python|/usr/bin/env python2|' \
"${pkgdir}"/usr/lib/python2.7/site-packages/bsddb3/{dbshelve.py,tests/test_dbtables.py}
install -Dm644 "${srcdir}"/LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
}
package_python-bsddb() {
depends=('db' 'python>=3.3')
cd bsddb3-${pkgver}
python3 setup.py --berkeley-db=/usr install --root="${pkgdir}" --skip-build --optimize=1
install -Dm644 "${srcdir}"/LICENSE "${pkgdir}"/usr/share/licenses/${pkgname}/LICENSE
}
|