diff options
author | Parabola <dev@list.parabolagnulinux.org> | 2011-04-05 14:26:38 +0000 |
---|---|---|
committer | Parabola <dev@list.parabolagnulinux.org> | 2011-04-05 14:26:38 +0000 |
commit | 415856bdd4f48ab4f2732996f0bae58595092bbe (patch) | |
tree | ede2018b591f6dfb477fe9341ba17b9bc000fab9 /extra/twisted |
Tue Apr 5 14:26:38 UTC 2011
Diffstat (limited to 'extra/twisted')
-rw-r--r-- | extra/twisted/4771.diff | 22 | ||||
-rw-r--r-- | extra/twisted/PKGBUILD | 33 | ||||
-rw-r--r-- | extra/twisted/twisted.install | 11 |
3 files changed, 66 insertions, 0 deletions
diff --git a/extra/twisted/4771.diff b/extra/twisted/4771.diff new file mode 100644 index 000000000..4e36f2632 --- /dev/null +++ b/extra/twisted/4771.diff @@ -0,0 +1,22 @@ +Index: twisted/words/protocols/jabber/jstrports.py +=================================================================== +--- twisted/words/protocols/jabber/jstrports.py (revision 30346) ++++ twisted/words/protocols/jabber/jstrports.py (working copy) +@@ -6,7 +6,7 @@ + """ A temporary placeholder for client-capable strports, until we + sufficient use cases get identified """ + +-from twisted.application import strports ++from twisted.internet.endpoints import _parse + + def _parseTCPSSL(factory, domain, port): + """ For the moment, parse TCP or SSL connections the same """ +@@ -22,7 +22,7 @@ + + + def parse(description, factory): +- args, kw = strports._parse(description) ++ args, kw = _parse(description) + return (args[0].upper(),) + _funcs[args[0]](factory, *args[1:], **kw) + + def client(description, factory): diff --git a/extra/twisted/PKGBUILD b/extra/twisted/PKGBUILD new file mode 100644 index 000000000..14991ddb8 --- /dev/null +++ b/extra/twisted/PKGBUILD @@ -0,0 +1,33 @@ +# $Id: PKGBUILD 107380 2011-01-24 14:03:19Z ibiru $ +# Maintainer : Ionut Biru <ibiru@archlinux.org> +# Contributor: Juergen Hoetzel <juergen@archlinux.org> +# Contributor: Douglas Soares de Andrade <douglas@archlinux.org> + +pkgname=twisted +pkgver=10.2.0 +pkgrel=3 +pkgdesc="Asynchronous networking framework written in Python." +arch=('i686' 'x86_64') +url="http://twistedmatrix.com/" +license=('MIT') +depends=('python2' 'pycrypto' 'zope-interface') +optdepends=('python2-pyopenssl' + 'python-soappy:for twisted.web.soap') +install=twisted.install +source=(http://tmrc.mit.edu/mirror/twisted/Twisted/${pkgver%.*}/Twisted-${pkgver}.tar.bz2 + 4771.diff) +md5sums=('73da62c793269eade8121da336b01ba5' + '087ed6149abca43919dcece24ba222ab') +build() { + cd "${srcdir}/Twisted-${pkgver}" + #http://twistedmatrix.com/trac/ticket/4771 + patch -Np0 -i ${srcdir}/4771.diff + + python2 setup.py install --prefix=/usr --root=${pkgdir} --optimize=1 + install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + + sed -e 's|#!/usr/bin/env python|#!/usr/bin/env python2|' \ + -i ${pkgdir}/usr/lib/python2.7/site-packages/twisted/trial/test/scripttest.py + sed -e 's|#!/usr/bin/env python|#!/usr/bin/env python2|' \ + -i ${pkgdir}/usr/lib/python2.7/site-packages/twisted/mail/test/pop3testserver.py +} diff --git a/extra/twisted/twisted.install b/extra/twisted/twisted.install new file mode 100644 index 000000000..8e93ffd3c --- /dev/null +++ b/extra/twisted/twisted.install @@ -0,0 +1,11 @@ +post_install() { + python2 -c 'from twisted.plugin import IPlugin, getPlugins; list(getPlugins(IPlugin))' >/dev/null 2>&1 || return 1 +} + +post_upgrade() { + post_install +} + +post_remove() { + find /usr/lib/python2.7/site-packages/twisted/plugins -name dropin.cache | xargs -r rm -f +} |