summaryrefslogtreecommitdiffstats
path: root/main/uwsgi/APKBUILD
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2014-03-25 07:44:43 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2014-03-25 07:45:18 +0000
commitcc5f305aaba4cefe2227aef2550d565f2f5a8147 (patch)
tree0be7c2bfb3c9f345db465f04b54ccb4b7bbb4de6 /main/uwsgi/APKBUILD
parent855ad8d21bb69b8db500260c9e4033f3e60f1414 (diff)
downloadaports-cc5f305aaba4cefe2227aef2550d565f2f5a8147.tar.bz2
aports-cc5f305aaba4cefe2227aef2550d565f2f5a8147.tar.xz
main/uwsgi: moved from testing
Diffstat (limited to 'main/uwsgi/APKBUILD')
-rw-r--r--main/uwsgi/APKBUILD106
1 files changed, 106 insertions, 0 deletions
diff --git a/main/uwsgi/APKBUILD b/main/uwsgi/APKBUILD
new file mode 100644
index 000000000..cd3085b89
--- /dev/null
+++ b/main/uwsgi/APKBUILD
@@ -0,0 +1,106 @@
+# Contributor: Kaarle Ritvanen <kaarle.ritvanen@datakunkku.fi>
+# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
+pkgname=uwsgi
+pkgver=2.0.1
+pkgrel=1
+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
+ pcre-dev"
+source="http://projects.unbit.it/downloads/uwsgi-${pkgver}.tar.gz
+ uwsgi.initd uwsgi.confd
+
+ 0001-use-portable-pthread-functions-instead-of-the-non-po.patch
+ 0002-Check-for-GNU-libc-instead-of-linux-for-use-of-execi.patch
+ 0003-always-define-_GNU_SOURCE-for-linux.patch
+ 0004-define-WAIT_ANY-if-missing.patch
+ musl-fix-python.patch
+ "
+
+_plugins="lua python router_uwsgi"
+subpackages=""
+for _p in $_plugins ; do
+ subpackages="$subpackages uwsgi-$_p:_$_p"
+done
+
+_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"
+
+ msg "building core"
+ # ccache seems to trigger some weird bug on musl
+ CC="gcc" python uwsgiconfig.py --build core || return 1
+
+ export UWSGICONFIG_LUAPC="lua5.2"
+ for i in $_plugins; do
+ msg "building $i plugin"
+ python uwsgiconfig.py --plugin plugins/$i core || return 1
+ done
+}
+
+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
+}
+
+_plugin() {
+ depends=uwsgi
+ mkdir -p "$subpkgdir"/usr/lib/uwsgi
+ mv "$pkgdir/usr/lib/uwsgi/$1_plugin.so" "$subpkgdir/usr/lib/uwsgi" || return 1
+}
+
+for _p in $_plugins; do
+ eval "_$_p() { _plugin $_p; }"
+done
+
+md5sums="e7234f16ddfb4fe5d0b5d5fa76dc17e1 uwsgi-2.0.1.tar.gz
+23b476a8ad6aab93b162e8eeec50c859 uwsgi.initd
+3d6afe6a8c52556d1d6c52384fc38d9a uwsgi.confd
+a7f98e2775e9f38a0f16c28332745836 0001-use-portable-pthread-functions-instead-of-the-non-po.patch
+b40fe76f34674874815c39a7e611f259 0002-Check-for-GNU-libc-instead-of-linux-for-use-of-execi.patch
+43e4edbe50bde1096e8ca03297a1f271 0003-always-define-_GNU_SOURCE-for-linux.patch
+1ee8996f7cced9dc88515c69c04dd79a 0004-define-WAIT_ANY-if-missing.patch
+87c16f6fe482c9b0eac0d33c51873f45 musl-fix-python.patch"
+sha256sums="e84e498c217a793571f803d04fca4f2877dd856e9c5af1e66e645132d70c7cc2 uwsgi-2.0.1.tar.gz
+df99bc13609a526432afaeb16661086c73f49394e069a19ccb7423bbd025168f uwsgi.initd
+4cb047e311aecd0f498da1d6a4c0947dd6dc7cc98575d54cb2ef150cacf8425c uwsgi.confd
+b61bf4da3d022ddfd93a73196300cb86d962f8f6198079d11b727f61c0f8acb4 0001-use-portable-pthread-functions-instead-of-the-non-po.patch
+360ede589ad228f31dd06fbf8dc17d86d60e968ae76a61b3ca258a2c5ae6f007 0002-Check-for-GNU-libc-instead-of-linux-for-use-of-execi.patch
+6cefd10432900518b3c19ee7f2a20b6b1f722b6d6e7ad43e4c3ad1be3daf43ee 0003-always-define-_GNU_SOURCE-for-linux.patch
+82a2c13162387efcafa388038602d783f8a7e71c28d56ab3ac6b94abeba474d3 0004-define-WAIT_ANY-if-missing.patch
+3838e8e3926a1f6271bb5aa88d309837a3bcd06cd570c499b72ca549326c682e musl-fix-python.patch"
+sha512sums="91d134413beac4d36ad4c1334410bd4d68a1bd53b4700da00e39f17fe01b1059457a102a9835ee09f8971b26597766ec8812afb5219c4774c2c7dbc025bcf617 uwsgi-2.0.1.tar.gz
+5d8eadba7c6ee17f86c3dbb6b7c98131ecf9db173156e3196909550954dd09be2191285f46fd4e558f0c47a0cbe7831cde71d3d4c63862d11b819660cc418131 uwsgi.initd
+9f00afb2aa574bbc59040f945475712b8c40da0c06eeb5699de5510aa116148e35ab0429fa891084cf0cd7868876d5a80e1601b7c85d0e2e9ea2a1f54cdde619 uwsgi.confd
+d105c487d8bd0b496cfac2dad6090f0e420805a83dca514bfbea97c687be26d7a8b9545add0f999cb67eb66818b05995405f9a874b970f53aa38ff5ce3bbdc02 0001-use-portable-pthread-functions-instead-of-the-non-po.patch
+f4038ab866f445a94e155f4b73d308959c402e81227401bc7a5fe2165b888a2c8d95141245a2c10b186782934a4103c785769afaf4091fe3fe5524ed3c270fcf 0002-Check-for-GNU-libc-instead-of-linux-for-use-of-execi.patch
+fc13550528121a1c8ecd530b38ea63f3802cb6d829ec18e55e485acb592b29bed8afe4d23a5f8b9baf8076a00f72d45e8b48c5c56e8c05299b7a1ea7a0ee2e77 0003-always-define-_GNU_SOURCE-for-linux.patch
+deb9fb2f125b80534e8176d32ec7cd85d49225339ccd989cfb463f5b38aa0869841c4bf9a2a97e0ed1c38b999599edb057b9aae17bdad96dad68970362e8bbc3 0004-define-WAIT_ANY-if-missing.patch
+de68b16b44e554a79c073c9befa10566796316dbf4c375b4d6b633d80b0282694cca233f0a70f3d6570584324f14276826bbeb8f38b550c00087a05f9ba9227f musl-fix-python.patch"