blob: 531daec308b91b51bfcb6573dc76a3003b8685d4 (
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
|
# Contributor: Kaarle Ritvanen <kaarle.ritvanen@datakunkku.fi>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=uwsgi
pkgver=1.9.15
pkgrel=0
pkgdesc="uWSGI application container server"
url=http://projects.unbit.it/uwsgi/
arch=all
license=GPL-2
makedepends="linux-headers lua5.2-dev python python-dev zeromq-dev paxctl"
subpackages="uwsgi-lua uwsgi-python:py"
source="http://projects.unbit.it/downloads/uwsgi-${pkgver}.tar.gz
uwsgi.initd uwsgi.confd
"
_builddir=$srcdir/$pkgname-$pkgver
prepare() {
local i
cd "$_builddir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
}
build() {
cd "$_builddir"
export CFLAGS=-D_GNU_SOURCE
msg "building core"
python uwsgiconfig.py --build core || return 1
msg "building lua plugin"
UWSGICONFIG_LUAPC="lua5.2" \
python uwsgiconfig.py --plugin plugins/lua core || return 1
msg "building python plugin"
python uwsgiconfig.py --plugin plugins/python core || return 1
}
package() {
cd "$_builddir"
local bindir=$pkgdir/usr/sbin
install -d "$bindir"
install uwsgi "$bindir"
local libdir=$pkgdir/usr/lib/uwsgi
install -d "$libdir"
install *_plugin.so "$libdir"
install -Dm755 "$srcdir"/uwsgi.initd \
"$pkgdir"/etc/init.d/uwsgi || return 1
install -Dm644 "$srcdir"/uwsgi.confd \
"$pkgdir"/etc/conf.d/uwsgi || return 1
# disable emutramp/mprotect, this is needed for luajit and cffi
paxctl -czxm "$bindir"/uwsgi
}
lua() {
depends=uwsgi
mkdir -p "$subpkgdir"/usr/lib/uwsgi
mv "$pkgdir/usr/lib/uwsgi/lua_plugin.so" "$subpkgdir/usr/lib/uwsgi"
}
py() {
depends=uwsgi
mkdir -p "$subpkgdir"/usr/lib/uwsgi
mv "$pkgdir/usr/lib/uwsgi/python_plugin.so" "$subpkgdir/usr/lib/uwsgi"
}
md5sums="e2a1c245e0b8b7e3c8dff8dbbfca52f3 uwsgi-1.9.15.tar.gz
8a8be061d7b5f3108a0f16813da68389 uwsgi.initd
3d6afe6a8c52556d1d6c52384fc38d9a uwsgi.confd"
sha256sums="87a9dba42df4344dab001ed9f14ad3176977367905dbf9524d18c3808c0e17af uwsgi-1.9.15.tar.gz
58b998b025e4a9df20ca917bc93e287f9a8cf02d278d513fa461f70e1d08f799 uwsgi.initd
4cb047e311aecd0f498da1d6a4c0947dd6dc7cc98575d54cb2ef150cacf8425c uwsgi.confd"
sha512sums="f845dc85c270caa4599f3f7c7be57848ebbb3dcbd69b0089674fcba42773cb1b4b2516315e09eb75832529c12c727135dbf54b88714e942a5274da01b27b19b8 uwsgi-1.9.15.tar.gz
ab9dc6277bd05821287f6f8beb3ac2504f0e41db38e11b4d2884ac026f14ac7bfaaca138f045afa712d4f2843f94de105bf0d43fad35d18679ac33b507cd187e uwsgi.initd
9f00afb2aa574bbc59040f945475712b8c40da0c06eeb5699de5510aa116148e35ab0429fa891084cf0cd7868876d5a80e1601b7c85d0e2e9ea2a1f54cdde619 uwsgi.confd"
|