summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBritney Fransen <brfransen@gmail.com>2018-03-06 18:09:56 (GMT)
committerBritney Fransen <brfransen@gmail.com>2018-03-06 18:09:56 (GMT)
commit78d3fd09a03fada6a389baba21758699cb18e451 (patch)
tree8c7896a89fbe4c9726b1d9e6cdfac3ff43d75269
parent5a6389af19f6810accabea04ec5eaeba17950152 (diff)
downloadlinhes_pkgbuild-78d3fd09a03fada6a389baba21758699cb18e451.zip
linhes_pkgbuild-78d3fd09a03fada6a389baba21758699cb18e451.tar.gz
linhes_pkgbuild-78d3fd09a03fada6a389baba21758699cb18e451.tar.bz2
python-beaker: update to 1.8.1
-rw-r--r--abs/core/python_modules/python-beaker/PKGBUILD62
-rw-r--r--abs/core/python_modules/python-beaker/__changelog1
2 files changed, 40 insertions, 23 deletions
diff --git a/abs/core/python_modules/python-beaker/PKGBUILD b/abs/core/python_modules/python-beaker/PKGBUILD
index fbc3bae..8947e3f 100644
--- a/abs/core/python_modules/python-beaker/PKGBUILD
+++ b/abs/core/python_modules/python-beaker/PKGBUILD
@@ -1,42 +1,60 @@
# $Id$
-# Maintainer : Ionut Biru <ibiru@archlinux.org>
+# Maintainer: Felix Yan <felixonmars@archlinux.org>
+# Contributor: Ionut Biru <ibiru@archlinux.org>
# Contributor: Massimiliano Torromeo < massimiliano DOT torromeo AT gmail DOT com >
-pkgname=('python2-beaker')
-pkgver=1.6.4
+pkgbase=python-beaker
+pkgname=('python-beaker' 'python2-beaker')
+pkgver=1.8.1
pkgrel=2
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=('python2-setuptools')
-source=("http://cheeseshop.python.org/packages/source/B/Beaker/Beaker-${pkgver}.tar.gz")
-md5sums=('c2e102870ed4c53104dec48ceadf8e9d')
+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() {
- cp -r Beaker-${pkgver} python2-Beaker-${pkgver}
-
- cd "${srcdir}/Beaker-${pkgver}"
- sed -i "s#/usr/bin/python#/usr/bin/python3#" beaker/crypto/pbkdf2.py
-# python3 setup.py build
+ cd "$srcdir"/beaker
+ python3 setup.py build
- cd "${srcdir}/python2-Beaker-${pkgver}"
- sed -i "s#/usr/bin/python#/usr/bin/python2#" beaker/crypto/pbkdf2.py
+ cd "$srcdir"/beaker-py2
python2 setup.py build
}
-#package_python-beaker() {
-# depends=('python')
+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-${pkgver}"
-# python3 setup.py install --root="${pkgdir}" --optimize=1
-# install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/python-beaker/LICENSE"
-#}
+ cd 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}/python2-Beaker-${pkgver}"
- python2 setup.py install --root="${pkgdir}" --optimize=1
- install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/python2-beaker/LICENSE"
+ cd beaker-py2
+ python2 setup.py install --root="$pkgdir" --optimize=1
+ install -D -m644 LICENSE "$pkgdir"/usr/share/licenses/python2-beaker/LICENSE
}
diff --git a/abs/core/python_modules/python-beaker/__changelog b/abs/core/python_modules/python-beaker/__changelog
deleted file mode 100644
index 9715c21..0000000
--- a/abs/core/python_modules/python-beaker/__changelog
+++ /dev/null
@@ -1 +0,0 @@
-PKGBUILD - comment out all python 3 stuff and only build for py 2