diff options
-rw-r--r-- | dev-vcs/bzr/ChangeLog | 7 | ||||
-rw-r--r-- | dev-vcs/bzr/bzr-2.2.2.ebuild | 7 | ||||
-rw-r--r-- | dev-vcs/bzr/files/bzr-2.2.2-python-2.7.patch | 40 |
3 files changed, 52 insertions, 2 deletions
diff --git a/dev-vcs/bzr/ChangeLog b/dev-vcs/bzr/ChangeLog index 5065a104967b..4ad8d487cd11 100644 --- a/dev-vcs/bzr/ChangeLog +++ b/dev-vcs/bzr/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for dev-vcs/bzr # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-vcs/bzr/ChangeLog,v 1.12 2010/11/27 10:53:02 fauli Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-vcs/bzr/ChangeLog,v 1.13 2010/12/07 07:55:27 fauli Exp $ + + 07 Dec 2010; Christian Faulhammer <fauli@gentoo.org> bzr-2.2.2.ebuild, + +files/bzr-2.2.2-python-2.7.patch: + Fix support for Python 2.7, taken from upstream, reported by Alessandro + Guido <alessandro.guido+bugzilla AT gmail DOT com> in bug 347555 27 Nov 2010; Christian Faulhammer <fauli@gentoo.org> -bzr-2.0.4.ebuild, -bzr-2.2.0.ebuild: diff --git a/dev-vcs/bzr/bzr-2.2.2.ebuild b/dev-vcs/bzr/bzr-2.2.2.ebuild index 718119df0654..5575976e3ab6 100644 --- a/dev-vcs/bzr/bzr-2.2.2.ebuild +++ b/dev-vcs/bzr/bzr-2.2.2.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2010 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-vcs/bzr/bzr-2.2.2.ebuild,v 1.1 2010/11/27 10:48:28 fauli Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-vcs/bzr/bzr-2.2.2.ebuild,v 1.2 2010/12/07 07:55:27 fauli Exp $ EAPI="3" PYTHON_DEPEND="2" @@ -49,6 +49,11 @@ SITEFILE="71bzr-gentoo.el" src_prepare() { distutils_src_prepare + # Fix for changed behaviour of Python 2.7, integrated into Bazaar + # 2.3, might be a regression in Python, see + # https://bugs.launchpad.net/bzr/+bug/612096 + # http://psf.upfronthosting.co.za/roundup/tracker/issue8194 + epatch "${FILESDIR}"/${PN}-2.2.2-python-2.7.patch # Don't regenerate .c files from .pyx when pyrex is found. epatch "${FILESDIR}/${PN}-2.2.0-no-pyrex-citon.patch" # Don't run lock permission tests when running as root diff --git a/dev-vcs/bzr/files/bzr-2.2.2-python-2.7.patch b/dev-vcs/bzr/files/bzr-2.2.2-python-2.7.patch new file mode 100644 index 000000000000..88e67e0c2580 --- /dev/null +++ b/dev-vcs/bzr/files/bzr-2.2.2-python-2.7.patch @@ -0,0 +1,40 @@ +=== modified file 'bzrlib/transport/http/_urllib2_wrappers.py' +--- bzrlib/transport/http/_urllib2_wrappers.py 2010-05-08 05:56:28 +0000 ++++ bzrlib/transport/http/_urllib2_wrappers.py 2010-09-15 02:43:44 +0000 +@@ -75,6 +75,26 @@ + ) + + ++class addinfourl(urllib2.addinfourl): ++ '''Replacement addinfourl class compatible with python-2.7's xmlrpclib ++ ++ In python-2.7, xmlrpclib expects that the response object that it receives ++ has a getheader method. httplib.HTTPResponse provides this but ++ urllib2.addinfourl does not. Add the necessary functions here, ported to ++ use the internal data structures of addinfourl. ++ ''' ++ ++ def getheader(self, name, default=None): ++ if self.headers is None: ++ raise httplib.ResponseNotReady() ++ return self.headers.getheader(name, default) ++ ++ def getheaders(self): ++ if self.headers is None: ++ raise httplib.ResponseNotReady() ++ return self.headers.items() ++ ++ + class _ReportingFileSocket(object): + + def __init__(self, filesock, report_activity=None): +@@ -656,7 +676,7 @@ + r = response + r.recv = r.read + fp = socket._fileobject(r, bufsize=65536) +- resp = urllib2.addinfourl(fp, r.msg, req.get_full_url()) ++ resp = addinfourl(fp, r.msg, req.get_full_url()) + resp.code = r.status + resp.msg = r.reason + resp.version = r.version + |