summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorFantix King2015-12-30 13:38:59 +0800
committerFantix King2016-01-19 21:53:30 +0800
commitd274434a14b71d6d3da84902ab6e9d8c96f57358 (patch)
tree49500de68467e15cd43fd2cbcb5f2e4b26a458da
downloadaur-d274434a14b71d6d3da84902ab6e9d8c96f57358.tar.gz
2.0.11.2-3.1
-rw-r--r--.SRCINFO69
-rw-r--r--PKGBUILD105
-rw-r--r--archlinux.ini5
-rw-r--r--emperor.ini4
-rw-r--r--emperor.uwsgi.service16
-rw-r--r--emperor.uwsgi.socket9
-rw-r--r--uwsgi.install9
-rw-r--r--uwsgi_at.service16
-rw-r--r--uwsgi_at.socket9
-rw-r--r--uwsgi_fix_rpath.patch66
-rw-r--r--uwsgi_ruby20_compatibility.patch42
-rw-r--r--uwsgi_trick_chroot.patch16
12 files changed, 366 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..e55e47ef6a00
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,69 @@
+# Generated by mksrcinfo v8
+# Tue Jan 19 13:53:27 UTC 2016
+pkgbase = uwsgi
+ pkgver = 2.0.11.2
+ pkgrel = 3.1
+ url = http://projects.unbit.it/uwsgi
+ arch = x86_64
+ license = GPL2
+ makedepends = gcc-multilib-x32
+ makedepends = libx32-python
+ makedepends = python-greenlet
+ makedepends = libx32-libxml2
+ makedepends = libx32-libyaml
+ makedepends = libx32-pcre
+ makedepends = libx32-openssl
+ makedepends = libx32-bzip2
+ makedepends = libx32-pam
+ makedepends = libx32-jansson
+ makedepends = libx32-systemd
+ backup = etc/uwsgi/emperor-x32.ini
+ source = http://projects.unbit.it/downloads/uwsgi-2.0.11.2.tar.gz
+ source = archlinux.ini
+ source = uwsgi_at.service
+ source = uwsgi_at.socket
+ source = uwsgi_fix_rpath.patch
+ source = uwsgi_ruby20_compatibility.patch
+ source = uwsgi_trick_chroot.patch
+ source = emperor.ini
+ source = emperor.uwsgi.service
+ source = emperor.uwsgi.socket
+ md5sums = 1f02dcbee7f6f61de4b1fd68350cf16f
+ md5sums = e069992a7e9aa86534d89a333b1ec2d7
+ md5sums = 8f3231b89b2cdc3802c2b14fa70a6ba1
+ md5sums = e4e20c976e476f5560dc24f0b16991f1
+ md5sums = 1a4516d5cdcf5b95b036f4eae2d0c152
+ md5sums = 4d09535ce379c8acd76160f35d5d6b55
+ md5sums = 0c09a52fdb88f08c36a8b380f451ce6d
+ md5sums = 5fa14ddea9a3dae17b5be28468d47b80
+ md5sums = f51c2e8f8c87a9c19b00b3bb79d6da50
+ md5sums = f726795b7beb92bf9e62cab8fcbf8c8f
+
+pkgname = libx32-uwsgi
+ pkgdesc = A fast, self-healing and developer/sysadmin-friendly application container server coded in pure C (x32 ABI)
+ install = uwsgi.install
+ depends = uwsgi
+ depends = libx32-libxml2
+ depends = libx32-jansson
+ depends = libx32-libyaml
+ depends = libx32-systemd
+ depends = libx32-libcap
+ depends = libx32-pam
+ depends = libx32-util-linux
+ depends = libx32-openssl
+ depends = libx32-pcre
+
+pkgname = libx32-uwsgi-plugin-cgi
+ pkgdesc = CGI plugin (x32 ABI)
+ depends = libx32-uwsgi
+
+pkgname = libx32-uwsgi-plugin-python
+ pkgdesc = Plugin for Python support (x32 ABI)
+ depends = libx32-uwsgi
+ depends = libx32-python
+ depends = libx32-python-greenlet
+
+pkgname = libx32-uwsgi-plugin-webdav
+ pkgdesc = Plugin for webdav support (x32 ABI)
+ depends = libx32-uwsgi
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..ab39790221da
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,105 @@
+# $Id: PKGBUILD 148079 2015-12-01 15:59:34Z svenstaro $
+# Maintainer: Daniel Wallace <danielwallace at gtmanfred dot com>
+# Maintainer: Sven-Hendrik Haase <sh@lutzhaase.com>
+# Contributor: Valentin Hăloiu <vially.ichb+aur@gmail.com>
+# Contributor: Angel Velasquez <angvp@archlinux.org>
+# Contributor: Kevin Zuber <uKev@knet.eu>
+# Contributor: Vsevolod Balashov <vsevolod@balashov.name>
+# Contributor: David Runge <dave@sleepmap.de>
+
+pkgbase=uwsgi
+pkgname=(libx32-uwsgi
+ libx32-uwsgi-plugin-cgi
+ libx32-uwsgi-plugin-python
+ libx32-uwsgi-plugin-webdav)
+pkgver=2.0.11.2
+pkgrel=3.1
+arch=(x86_64)
+url="http://projects.unbit.it/$pkgbase"
+license=(GPL2)
+backup=('etc/uwsgi/emperor-x32.ini')
+makedepends=(gcc-multilib-x32 libx32-python python-greenlet libx32-libxml2 libx32-libyaml
+ libx32-pcre libx32-openssl libx32-bzip2 libx32-pam
+ libx32-jansson libx32-systemd)
+source=(http://projects.unbit.it/downloads/$pkgbase-$pkgver.tar.gz
+ archlinux.ini
+ uwsgi_at.service
+ uwsgi_at.socket
+ uwsgi_fix_rpath.patch
+ uwsgi_ruby20_compatibility.patch
+ uwsgi_trick_chroot.patch
+ emperor.ini
+ emperor.uwsgi.service
+ emperor.uwsgi.socket)
+
+md5sums=('1f02dcbee7f6f61de4b1fd68350cf16f'
+ 'e069992a7e9aa86534d89a333b1ec2d7'
+ '8f3231b89b2cdc3802c2b14fa70a6ba1'
+ 'e4e20c976e476f5560dc24f0b16991f1'
+ '1a4516d5cdcf5b95b036f4eae2d0c152'
+ '4d09535ce379c8acd76160f35d5d6b55'
+ '0c09a52fdb88f08c36a8b380f451ce6d'
+ '5fa14ddea9a3dae17b5be28468d47b80'
+ 'f51c2e8f8c87a9c19b00b3bb79d6da50'
+ 'f726795b7beb92bf9e62cab8fcbf8c8f')
+
+prepare() {
+ cd $srcdir/$pkgbase-$pkgver
+ cp $srcdir/archlinux.ini buildconf/archlinux.ini
+ #sed -i 's/LIBS .*-lphp5.*/LIBS = []/' plugins/php/uwsgiplugin.py
+ for patch in uwsgi_fix_rpath.patch uwsgi_ruby20_compatibility.patch uwsgi_trick_chroot.patch; do
+ patch -Np1 -i $srcdir/$patch
+ done
+ rm -rf plugins/ruby
+ mv plugins/ruby{19,}
+ sed -i 's:\(ruby\)19:\1:' plugins/ruby/uwsgiplugin.py
+}
+
+build() {
+ pushd $srcdir/$pkgbase-$pkgver
+
+ python-x32 uwsgiconfig.py --build archlinux
+ python-x32 uwsgiconfig.py --plugin plugins/python archlinux python
+ python-x32 uwsgiconfig.py --plugin plugins/greenlet archlinux greenlet
+ python-x32 uwsgiconfig.py --plugin plugins/asyncio archlinux asyncio
+
+ #pushd $srcdir/$pkgbase-$pkgver/apache2
+ #/usr/bin/apxs -c mod_proxy_uwsgi.c
+}
+
+package_libx32-uwsgi() {
+ pkgdesc="A fast, self-healing and developer/sysadmin-friendly application container server coded in pure C (x32 ABI)"
+ depends=(uwsgi libx32-libxml2 libx32-jansson libx32-libyaml libx32-systemd libx32-libcap libx32-pam libx32-util-linux libx32-openssl libx32-pcre)
+ install=uwsgi.install
+ cd $srcdir/$pkgbase-$pkgver
+ install -Dm755 uwsgi $pkgdir/usr/bin/uwsgi-x32
+ install -Dm644 $srcdir/uwsgi_at.service $pkgdir/usr/lib/systemd/system/uwsgi-x32@.service
+ install -Dm644 $srcdir/uwsgi_at.socket $pkgdir/usr/lib/systemd/system/uwsgi-x32@.socket
+ install -Dm644 $srcdir/emperor.uwsgi.service $pkgdir/usr/lib/systemd/system/emperor.uwsgi-x32.service
+ install -Dm644 $srcdir/emperor.uwsgi.socket $pkgdir/usr/lib/systemd/system/emperor.uwsgi-x32.socket
+ install -Dm644 $srcdir/emperor.ini $pkgdir/etc/uwsgi/emperor-x32.ini
+}
+
+package_libx32-uwsgi-plugin-cgi() {
+ depends=(libx32-uwsgi)
+ pkgdesc="CGI plugin (x32 ABI)"
+ install -Dm755 $pkgbase-$pkgver/cgi_plugin.so $pkgdir/usr/libx32/uwsgi/cgi_plugin.so
+}
+
+package_libx32-uwsgi-plugin-python() {
+ depends=(libx32-uwsgi libx32-python libx32-python-greenlet)
+ pkgdesc="Plugin for Python support (x32 ABI)"
+ install -Dm755 $pkgbase-$pkgver/python_plugin.so $pkgdir/usr/libx32/uwsgi/python_plugin.so
+ install -Dm755 $pkgbase-$pkgver/greenlet_plugin.so $pkgdir/usr/libx32/uwsgi/greenlet_plugin.so
+ install -Dm755 $pkgbase-$pkgver/asyncio_plugin.so $pkgdir/usr/libx32/uwsgi/asyncio_plugin.so
+ install -Dm644 $pkgbase-$pkgver/uwsgidecorators.py $pkgdir/usr/libx32/python3.5/site-packages/uwsgidecorators.py
+ python -m compileall $pkgdir/usr/libx32/python3.5/site-packages/
+ python -O -m compileall $pkgdir/usr/libx32/python3.5/site-packages/
+}
+
+package_libx32-uwsgi-plugin-webdav() {
+ depends=(libx32-uwsgi)
+ pkgdesc="Plugin for webdav support (x32 ABI)"
+ install -Dm755 $pkgbase-$pkgver/webdav_plugin.so $pkgdir/usr/libx32/uwsgi/webdav_plugin.so
+}
+
diff --git a/archlinux.ini b/archlinux.ini
new file mode 100644
index 000000000000..cf8f8f479566
--- /dev/null
+++ b/archlinux.ini
@@ -0,0 +1,5 @@
+[uwsgi]
+plugin_dir = /usr/libx32/uwsgi
+plugins = cgi, webdav
+main_plugin = systemd_logger,pam
+inherit = base
diff --git a/emperor.ini b/emperor.ini
new file mode 100644
index 000000000000..27c9120bd9ce
--- /dev/null
+++ b/emperor.ini
@@ -0,0 +1,4 @@
+[uwsgi]
+emperor = /etc/uwsgi/vassals
+uid = http
+gid = http
diff --git a/emperor.uwsgi.service b/emperor.uwsgi.service
new file mode 100644
index 000000000000..3cca7ec6e745
--- /dev/null
+++ b/emperor.uwsgi.service
@@ -0,0 +1,16 @@
+[Unit]
+Description=uWSGI Emperor (x32 ABI)
+After=syslog.target
+
+[Service]
+ExecStart=/usr/bin/uwsgi-x32 --ini /etc/uwsgi/emperor-x32.ini
+ExecReload=/bin/kill -HUP $MAINPID
+ExecStop=/bin/kill -INT $MAINPID
+Restart=always
+Type=notify
+StandardError=syslog
+NotifyAccess=all
+KillSignal=SIGQUIT
+
+[Install]
+WantedBy=multi-user.target
diff --git a/emperor.uwsgi.socket b/emperor.uwsgi.socket
new file mode 100644
index 000000000000..24da5988af72
--- /dev/null
+++ b/emperor.uwsgi.socket
@@ -0,0 +1,9 @@
+[Unit]
+Description=Socket for uWSGI Emperor (x32 ABI)
+
+[Socket]
+# Change this to your uwsgi application port or unix socket location
+ListenStream=/run/uwsgi/emperor-x32.sock
+
+[Install]
+WantedBy=sockets.target
diff --git a/uwsgi.install b/uwsgi.install
new file mode 100644
index 000000000000..d8336054bbd9
--- /dev/null
+++ b/uwsgi.install
@@ -0,0 +1,9 @@
+post_update(){
+ echo "To use uwsgi-x32@.socket and uwsgi-x32@.service:"
+ echo "\tAll you need to do is put the name of your .ini file after the @ sign"
+ echo "\tYou can use either the .socket or .service, but if you use the .socket"
+ echo "\tuwsgi@<sameinifile>.service won't be started until the first time your http"
+ echo "\tserver touches the socket. You will also not need to specify the socket in"
+ echo "\tthe .ini file or in the .service file. Systemd will handle listening to"
+ echo "\tthe socket for you."
+}
diff --git a/uwsgi_at.service b/uwsgi_at.service
new file mode 100644
index 000000000000..7a919c18635d
--- /dev/null
+++ b/uwsgi_at.service
@@ -0,0 +1,16 @@
+[Unit]
+Description=uWSGI service unit (x32 ABI)
+After=syslog.target
+
+[Service]
+ExecStart=/usr/bin/uwsgi-x32 --ini /etc/uwsgi/%I.ini
+ExecReload=/bin/kill -HUP $MAINPID
+ExecStop=/bin/kill -INT $MAINPID
+Restart=always
+Type=notify
+StandardError=syslog
+NotifyAccess=all
+KillSignal=SIGQUIT
+
+[Install]
+WantedBy=multi-user.target
diff --git a/uwsgi_at.socket b/uwsgi_at.socket
new file mode 100644
index 000000000000..f5790b8dc505
--- /dev/null
+++ b/uwsgi_at.socket
@@ -0,0 +1,9 @@
+[Unit]
+Description=Socket for uWSGI %I (x32 ABI)
+
+[Socket]
+# Change this to your uwsgi application port or unix socket location
+ListenStream=/run/uwsgi/%I.sock
+
+[Install]
+WantedBy=sockets.target
diff --git a/uwsgi_fix_rpath.patch b/uwsgi_fix_rpath.patch
new file mode 100644
index 000000000000..3de66a7712bb
--- /dev/null
+++ b/uwsgi_fix_rpath.patch
@@ -0,0 +1,66 @@
+diff --git a/plugins/jvm/uwsgiplugin.py b/plugins/jvm/uwsgiplugin.py
+index ac7eb3e..0911288 100644
+--- a/plugins/jvm/uwsgiplugin.py
++++ b/plugins/jvm/uwsgiplugin.py
+@@ -59,11 +59,6 @@ if "-framework JavaVM" in JVM_LIBPATH:
+
+ GCC_LIST = ['jvm_plugin']
+
+-if 'LD_RUN_PATH' in os.environ:
+- os.environ['LD_RUN_PATH'] += ':' + JVM_LIBPATH[0][2:]
+-else:
+- os.environ['LD_RUN_PATH'] = JVM_LIBPATH[0][2:]
+-
+ def post_build(config):
+ if os.system("javac %s/plugins/jvm/uwsgi.java" % os.getcwd()) != 0:
+ os._exit(1)
+diff --git a/plugins/php/uwsgiplugin.py b/plugins/php/uwsgiplugin.py
+index fb9e5bb..fd12c91 100644
+--- a/plugins/php/uwsgiplugin.py
++++ b/plugins/php/uwsgiplugin.py
+@@ -22,7 +22,6 @@ CFLAGS = [os.popen(PHPPATH + ' --includes').read().rstrip(), '-Wno-error=sign-co
+ LDFLAGS = os.popen(PHPPATH + ' --ldflags').read().rstrip().split()
+ if ld_run_path:
+ LDFLAGS.append('-L%s' % ld_run_path)
+- os.environ['LD_RUN_PATH'] = ld_run_path
+
+ LIBS = [os.popen(PHPPATH + ' --libs').read().rstrip(), '-lphp5']
+
+diff --git a/plugins/python/uwsgiplugin.py b/plugins/python/uwsgiplugin.py
+index c4f03e1..8d4b2e0 100644
+--- a/plugins/python/uwsgiplugin.py
++++ b/plugins/python/uwsgiplugin.py
+@@ -45,10 +45,8 @@ if not 'UWSGI_PYTHON_NOLIB' in os.environ:
+ else:
+ try:
+ LDFLAGS.append("-L%s" % sysconfig.get_config_var('LIBDIR'))
+- os.environ['LD_RUN_PATH'] = "%s" % (sysconfig.get_config_var('LIBDIR'))
+ except:
+ LDFLAGS.append("-L%s/lib" % sysconfig.PREFIX)
+- os.environ['LD_RUN_PATH'] = "%s/lib" % sysconfig.PREFIX
+
+ LIBS.append('-lpython%s' % get_python_version())
+ else:
+diff --git a/plugins/rack/uwsgiplugin.py b/plugins/rack/uwsgiplugin.py
+index 8dee214..2375bc9 100644
+--- a/plugins/rack/uwsgiplugin.py
++++ b/plugins/rack/uwsgiplugin.py
+@@ -44,7 +44,6 @@ LIBS = os.popen(RUBYPATH + " -e \"require 'rbconfig';print %s::CONFIG['LIBS']\""
+
+ if has_shared == 'yes':
+ LDFLAGS.append('-L' + libpath )
+- os.environ['LD_RUN_PATH'] = libpath
+ LIBS.append(os.popen(RUBYPATH + " -e \"require 'rbconfig';print '-l' + %s::CONFIG['RUBY_SO_NAME']\"" % rbconfig).read().rstrip())
+ else:
+ GCC_LIST.append("%s/%s" % (libpath, os.popen(RUBYPATH + " -e \"require 'rbconfig';print %s::CONFIG['LIBRUBY_A']\"" % rbconfig).read().rstrip()))
+diff --git a/plugins/ruby19/uwsgiplugin.py b/plugins/ruby19/uwsgiplugin.py
+index ecea48d..4f35984 100644
+--- a/plugins/ruby19/uwsgiplugin.py
++++ b/plugins/ruby19/uwsgiplugin.py
+@@ -40,6 +40,5 @@ LDFLAGS = os.popen(RUBYPATH + " -e \"require 'rbconfig';print %s::CONFIG['LDFLAG
+
+ libpath = os.popen(RUBYPATH + " -e \"require 'rbconfig';print %s::CONFIG['libdir']\"" % rbconfig).read().rstrip()
+ LDFLAGS.append('-L' + libpath )
+-os.environ['LD_RUN_PATH'] = libpath
+ LIBS = os.popen(RUBYPATH + " -e \"require 'rbconfig';print '-l' + %s::CONFIG['RUBY_SO_NAME']\"" % rbconfig).read().rstrip().split()
+
diff --git a/uwsgi_ruby20_compatibility.patch b/uwsgi_ruby20_compatibility.patch
new file mode 100644
index 000000000000..b4bf20d381b5
--- /dev/null
+++ b/uwsgi_ruby20_compatibility.patch
@@ -0,0 +1,42 @@
+diff --git a/plugins/rack/uwsgiplugin.py b/plugins/rack/uwsgiplugin.py
+index 2375bc9..b908417 100644
+--- a/plugins/rack/uwsgiplugin.py
++++ b/plugins/rack/uwsgiplugin.py
+@@ -10,13 +10,14 @@ except:
+ rbconfig = 'Config'
+
+ version = os.popen(RUBYPATH + " -e \"print RUBY_VERSION\"").read().rstrip()
+-v = version.split('.')
+
+ GCC_LIST = ['rack_plugin', 'rack_api']
+
+-if (v[0] == '1' and v[1] == '9') or v[0] >= '2':
++if version >= '1.9':
+ CFLAGS = os.popen(RUBYPATH + " -e \"require 'rbconfig';print RbConfig::CONFIG['CFLAGS']\"").read().rstrip().split()
+ CFLAGS.append('-DRUBY19')
++ if version >= '2.0':
++ CFLAGS.append('-DRUBY20')
+ CFLAGS.append('-Wno-unused-parameter')
+ rbconfig = 'RbConfig'
+ else:
+diff --git a/plugins/ruby19/uwsgiplugin.py b/plugins/ruby19/uwsgiplugin.py
+index 4f35984..156018f 100644
+--- a/plugins/ruby19/uwsgiplugin.py
++++ b/plugins/ruby19/uwsgiplugin.py
+@@ -10,13 +10,14 @@ except:
+ rbconfig = 'Config'
+
+ version = os.popen(RUBYPATH + " -e \"print RUBY_VERSION\"").read().rstrip()
+-v = version.split('.')
+
+ GCC_LIST = ['../rack/rack_plugin', '../rack/rack_api']
+
+-if v[0] == '1' and v[1] == '9':
++if version >= '1.9':
+ CFLAGS = os.popen(RUBYPATH + " -e \"require 'rbconfig';print RbConfig::CONFIG['CFLAGS']\"").read().rstrip().split()
+ CFLAGS.append('-DRUBY19')
++ if version >= '2.0':
++ CFLAGS.append('-DRUBY20')
+ CFLAGS.append('-Wno-unused-parameter')
+ rbconfig = 'RbConfig'
+ else:
diff --git a/uwsgi_trick_chroot.patch b/uwsgi_trick_chroot.patch
new file mode 100644
index 000000000000..3bfb1ac220ae
--- /dev/null
+++ b/uwsgi_trick_chroot.patch
@@ -0,0 +1,16 @@
+diff --git a/uwsgiconfig.py b/uwsgiconfig.py
+index e447123..4d55f2c 100644
+--- a/uwsgiconfig.py
++++ b/uwsgiconfig.py
+@@ -1129,10 +1129,7 @@ def build_plugin(path, uc, cflags, ldflags, libs, name = None):
+ except:
+ pass
+
+- if uc:
+- plugin_dest = uc.get('plugin_dir') + '/' + name + '_plugin'
+- else:
+- plugin_dest = name + '_plugin'
++ plugin_dest = name + '_plugin'
+
+ shared_flag = '-shared'
+