[arch-commits] Commit in python-beaker/repos (staging-any staging-any/PKGBUILD)
Felix Yan
fyan at archlinux.org
Sat Sep 19 12:44:33 UTC 2015
Date: Saturday, September 19, 2015 @ 14:44:33
Author: fyan
Revision: 246612
archrelease: copy trunk to staging-any
Added:
python-beaker/repos/staging-any/
python-beaker/repos/staging-any/PKGBUILD
(from rev 246611, python-beaker/trunk/PKGBUILD)
----------+
PKGBUILD | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 60 insertions(+)
Copied: python-beaker/repos/staging-any/PKGBUILD (from rev 246611, python-beaker/trunk/PKGBUILD)
===================================================================
--- staging-any/PKGBUILD (rev 0)
+++ staging-any/PKGBUILD 2015-09-19 12:44:33 UTC (rev 246612)
@@ -0,0 +1,60 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Ionut Biru <ibiru at archlinux.org>
+# Contributor: Massimiliano Torromeo < massimiliano DOT torromeo AT gmail DOT com >
+
+pkgbase=python-beaker
+pkgname=('python-beaker' 'python2-beaker')
+pkgver=1.7.0
+pkgrel=3
+arch=('any')
+license=('custom')
+pkgdesc="Caching and sessions WSGI middleware for use with web applications and stand-alone Python scripts and applications"
+url="http://beaker.groovie.org/"
+makedepends=('python-setuptools' 'python2-setuptools' 'git')
+checkdepends=('python-nose' 'python2-nose' 'python-mock' 'python2-mock' 'python-sqlalchemy' 'python2-sqlalchemy'
+ 'python-crypto' 'python2-crypto' 'python-coverage' 'python2-coverage' 'python-webtest' 'python2-webtest'
+ 'python-beautifulsoup4' 'python2-beautifulsoup4')
+source=("git+https://github.com/bbangert/beaker.git#tag=$pkgver")
+md5sums=('SKIP')
+
+prepare() {
+ cp -a beaker{,-py2}
+
+ sed -i "s#/usr/bin/python#/usr/bin/python3#" beaker/beaker/crypto/pbkdf2.py
+ sed -i "s#/usr/bin/python#/usr/bin/python2#" beaker-py2/beaker/crypto/pbkdf2.py
+}
+
+build() {
+ cd "${srcdir}/beaker"
+ python3 setup.py build
+
+ cd "${srcdir}/beaker-py2"
+ python2 setup.py build
+}
+
+check() {
+ cd "${srcdir}/beaker"
+ mkdir tests_py3
+ 2to3 -w -n -o tests_py3 tests/*.py
+ PYTHONPATH="$PWD/build/lib:$PYTHONPATH" nosetests3 --py3where=tests_py3
+
+ cd "${srcdir}/beaker-py2"
+ PYTHONPATH="$PWD/build/lib:$PYTHONPATH" nosetests2
+}
+
+package_python-beaker() {
+ depends=('python')
+
+ cd "${srcdir}/beaker"
+ python3 setup.py install --root="${pkgdir}" --optimize=1
+ install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/python-beaker/LICENSE"
+}
+
+package_python2-beaker() {
+ depends=('python2')
+
+ cd "${srcdir}/beaker-py2"
+ python2 setup.py install --root="${pkgdir}" --optimize=1
+ install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/python2-beaker/LICENSE"
+}
More information about the arch-commits
mailing list