diff -u pyopenssl-0.10/debian/changelog pyopenssl-0.10/debian/changelog --- pyopenssl-0.10/debian/changelog +++ pyopenssl-0.10/debian/changelog @@ -1,3 +1,25 @@ +pyopenssl (0.10-1ubuntu3) natty; urgency=low + + * Add upstream patch so that sendall() uses a memoryview, which is + required for Python 2.7 compatibility. Patch given in upstream bug + report . (LP: #758037) + + -- Barry Warsaw Wed, 13 Apr 2011 08:39:18 -0400 + +pyopenssl (0.10-1ubuntu2) natty; urgency=low + + * No-change rebuild to prefer python2.7. + + -- Martin Pitt Wed, 22 Dec 2010 09:39:55 +0100 + +pyopenssl (0.10-1ubuntu1) natty; urgency=low + + * Rebuild with Python2.7. + * debian/rules: change dh_pysupport to dh_python2. + * debian/control: Removed python-support from Build-Depends. + + -- Daniel Holbach Mon, 29 Nov 2010 09:39:23 +0100 + pyopenssl (0.10-1) unstable; urgency=low * New upstream release diff -u pyopenssl-0.10/debian/control pyopenssl-0.10/debian/control --- pyopenssl-0.10/debian/control +++ pyopenssl-0.10/debian/control @@ -1,9 +1,10 @@ Source: pyopenssl Section: python Priority: optional -Maintainer: Debian Python Modules Team +Maintainer: Ubuntu Developers +XSBC-Original-Maintainer: Debian Python Modules Team Uploaders: Sandro Tosi -Build-Depends: debhelper (>= 5.0.37.2), python-all-dev (>= 2.5.4-1~), python-all-dbg (>= 2.5.4-1~), python-support (>= 0.6.4), libssl-dev (>= 0.9.8), dpatch, tex4ht, w3m, texlive-latex-base, texlive-latex-recommended +Build-Depends: debhelper (>= 5.0.37.2), python-all-dev (>= 2.5.4-1~), python-all-dbg (>= 2.5.4-1~), libssl-dev (>= 0.9.8), dpatch, tex4ht, w3m, texlive-latex-base, texlive-latex-recommended Standards-Version: 3.8.4 Homepage: http://pyopenssl.sourceforge.net/ Vcs-Svn: svn://svn.debian.org/python-modules/packages/pyopenssl/trunk/ diff -u pyopenssl-0.10/debian/rules pyopenssl-0.10/debian/rules --- pyopenssl-0.10/debian/rules +++ pyopenssl-0.10/debian/rules @@ -73,7 +73,7 @@ dh_installchangelogs ChangeLog -i dh_compress -i dh_fixperms -i - dh_pysupport -i + dh_python2 -i dh_installdeb -i dh_gencontrol -i dh_md5sums -i @@ -91,7 +91,7 @@ ln -s python-openssl debian/python-openssl-dbg/usr/share/doc/python-openssl-dbg dh_compress -a dh_fixperms -a - dh_pysupport -a + dh_python2 -a dh_makeshlibs -a dh_installdeb -a dh_shlibdeps -a diff -u pyopenssl-0.10/debian/patches/00list pyopenssl-0.10/debian/patches/00list --- pyopenssl-0.10/debian/patches/00list +++ pyopenssl-0.10/debian/patches/00list @@ -2,0 +3 @@ +30_py27_memoryview only in patch2: unchanged: --- pyopenssl-0.10.orig/debian/patches/30_py27_memoryview.dpatch +++ pyopenssl-0.10/debian/patches/30_py27_memoryview.dpatch @@ -0,0 +1,45 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 30_py27_memoryview.dpatch by Barry Warsaw +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Use memoryviews; required for Python 2.7 +## DP: Upstream bug report: https://launchpad.net/bugs/686804 +## DP: Closes https://launchpad.net/bugs/758037 (LP: #758037) + +@DPATCH@ + +Index: pyOpenSSL-0.10/src/ssl/connection.c +=================================================================== +--- pyOpenSSL-0.10.orig/src/ssl/connection.c ++++ pyOpenSSL-0.10/src/ssl/connection.c +@@ -369,17 +369,20 @@ has been sent.\n\ + @param buf: The string to send\n\ + @param flags: (optional) Included for compatability with the socket\n\ + API, the value is ignored\n\ +-@return: The number of bytes written\n\ ++@return: None\n\ + "; + static PyObject * + ssl_Connection_sendall(ssl_ConnectionObj *self, PyObject *args) + { ++ Py_buffer pbuf; + char *buf; + int len, ret, err, flags; + PyObject *pyret = Py_None; + +- if (!PyArg_ParseTuple(args, "s#|i:sendall", &buf, &len, &flags)) ++ if (!PyArg_ParseTuple(args, "s*|i:sendall", &pbuf, &flags)) + return NULL; ++ buf = pbuf.buf; ++ len = pbuf.len; + + do { + MY_BEGIN_ALLOW_THREADS(self->tstate) +@@ -405,6 +408,7 @@ ssl_Connection_sendall(ssl_ConnectionObj + break; + } + } while (len > 0); ++ PyBuffer_Release(&pbuf); + + Py_XINCREF(pyret); + return pyret;