[arch-commits] Commit in zope-interface/trunk (PKGBUILD)
Ionut Biru
ibiru at archlinux.org
Mon Jun 27 06:20:40 UTC 2011
Date: Monday, June 27, 2011 @ 02:20:40
Author: ibiru
Revision: 129388
add python3 support, rename zope-interface to python2-zope-interface, fix missing common interface.
Modified:
zope-interface/trunk/PKGBUILD
----------+
PKGBUILD | 33 +++++++++++++++++++++++++++++----
1 file changed, 29 insertions(+), 4 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2011-06-27 06:11:16 UTC (rev 129387)
+++ PKGBUILD 2011-06-27 06:20:40 UTC (rev 129388)
@@ -2,23 +2,48 @@
# Maintainer : Ionut Biru <ibiru at archlinux.org>
# Contributor: Douglas Soares de Andrade <douglas at archlinux.org>
-pkgname=zope-interface
+pkgbase=zope-interface
+pkgname=('python-zope-interface' 'python2-zope-interface')
pkgver=3.6.3
pkgrel=1
-pkgdesc="Separate distribution of the zope.interface package used in Zope 3."
license=('ZPL')
arch=('any')
url="http://pypi.python.org/pypi/zope.interface"
-depends=('python2')
+makedepends=('python-distribute' 'python2-distribute')
source=(http://pypi.python.org/packages/source/z/zope.interface/zope.interface-${pkgver}.tar.gz)
md5sums=('954a56113b491b5856b9e78424ba0922')
build() {
+ cd "${srcdir}"
+ cp -a zope.interface-${pkgver}{,-python2}
+
+ #build python3 module
cd "${srcdir}/zope.interface-${pkgver}"
+ python setup.py build
+
+ #build python2 module
+ cd "${srcdir}/zope.interface-${pkgver}-python2"
python2 setup.py build
}
-package() {
+package_python-zope-interface() {
+ pkgdesc=('Zope Interfaces for Python3')
+ depends=('python')
cd "${srcdir}/zope.interface-${pkgver}"
+ python setup.py install --prefix=/usr --root="${pkgdir}" --optimize=1
+ cp src/zope/__init__.py "${pkgdir}/usr/lib/python3.2/site-packages/zope/"
+ #delete debug
+ rm "${pkgdir}"/usr/lib/python3.2/site-packages/zope/interface/_zope_interface_coptimizations.cpython-32mu.so
+}
+
+package_python2-zope-interface(){
+ pkgdesc=('Zope Interfaces for Python2')
+ depends=('python2')
+ replaces=('zope-interface')
+ provides=('zope-interface')
+ cd "${srcdir}/zope.interface-${pkgver}-python2"
python2 setup.py install --prefix=/usr --root="${pkgdir}" --optimize=1
+ cp src/zope/__init__.py "${pkgdir}/usr/lib/python2.7/site-packages/zope/"
+ #delete debug
+ rm "${pkgdir}"/usr/lib/python2.7/site-packages/zope/interface/_zope_interface_coptimizations.so
}
More information about the arch-commits
mailing list