1 # Maintainer: Angel Velasquez <angvp@archlinux.org>
2 # Maintainer: Dan McGee <dan@archlinux.org>
3 # Contributor: Shahar Weiss <sweiss4@gmx.net>
6 pkgname=('python-django')
9 pkgdesc="A high-level Python Web framework that encourages rapid development and clean design"
12 url="http://www.djangoproject.com/"
13 checkdepends=('python-pytest' 'python-tblib')
14 makedepends=('python' 'python-setuptools')
15 depends=('python' 'python-pytz' 'python-sqlparse' 'python-asgiref')
16 # TODO: package and add python-pymemcache https://docs.djangoproject.com/en/dev/topics/cache/
17 optdepends=('python-psycopg2: for PostgreSQL backend'
18 'python-argon2_cffi: for Argon2 password hashing support')
19 source=("Django-$pkgver.tar.gz::https://www.djangoproject.com/download/$pkgver/tarball/")
20 sha512sums=('62fb297694a7f5e48465e102dc97e3d1d04b94499bc6d98d37a00d96b438b8c919b6d08055868a1836d62b89ff65ce4fa7dbc9390789dab2eeca0187269b125f')
23 cd "$srcdir/Django-$pkgver"
27 package_python-django() {
28 cd "$srcdir/Django-$pkgver"
30 python setup.py install --root="$pkgdir" --optimize=1
32 ln -s django-admin.py "$pkgdir"/usr/bin/django-admin3.py
33 ln -s django-admin "$pkgdir"/usr/bin/django-admin3
34 install -Dm644 extras/django_bash_completion \
35 "$pkgdir"/usr/share/bash-completion/completions/django-admin.py
36 ln -s django-admin.py \
37 "$pkgdir"/usr/share/bash-completion/completions/django-admin
38 ln -s django-admin.py \
39 "$pkgdir"/usr/share/bash-completion/completions/manage.py
41 install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
45 cd "$srcdir/Django-$pkgver"
46 PYTHONPATH="$PWD" python tests/runtests.py || echo 'tests failed'