From adb5c7cfa8fada2337774e6b22930ec2f15031cd Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Dec 02 2010 10:20:24 +0000 Subject: Patch for python 2.7 --- diff --git a/python-boto-1.9b-python27.patch b/python-boto-1.9b-python27.patch new file mode 100644 index 0000000..2cd3963 --- /dev/null +++ b/python-boto-1.9b-python27.patch @@ -0,0 +1,27 @@ +From 6760075073c34d6dddb7e13b80dfa8d09f0f4f79 Mon Sep 17 00:00:00 2001 +From: Mitch.Garnaat +Date: Tue, 6 Jul 2010 22:33:07 +0000 +Subject: [PATCH] Kludge the existing kludge to handle httplib differences. Fixes issue 408. + +--- + boto/connection.py | 3 ++- + 1 files changed, 2 insertions(+), 1 deletions(-) + +diff --git a/boto/connection.py b/boto/connection.py +index c5779e2..71942f1 100644 +--- a/boto/connection.py ++++ b/boto/connection.py +@@ -252,8 +252,9 @@ class AWSAuthConnection(object): + # versions, it would append ":443" to the hostname sent + # in the Host header and so we needed to make sure we + # did the same when calculating the V2 signature. In 2.6 ++ # (and higher!) + # it no longer does that. Hence, this kludge. +- if sys.version[:3] == "2.6" and port == 443: ++ if sys.version[:3] in ('2.6', '2.7') and port == 443: + signature_host = self.host + else: + signature_host = '%s:%d' % (self.host, port) +-- +1.7.3.1 + diff --git a/python-boto.spec b/python-boto.spec index d22c076..e408d38 100644 --- a/python-boto.spec +++ b/python-boto.spec @@ -4,13 +4,14 @@ Summary: A simple lightweight interface to Amazon Web Services Name: python-boto Version: 1.9b -Release: 4%{?dist} +Release: 5%{?dist} License: MIT Group: Development/Languages URL: http://code.google.com/p/%{pkgname}/ Source: http://boto.googlecode.com/files/%{pkgname}-%{version}.tar.gz Patch0: python-boto-1.9b-image.patch Patch1: python-boto-1.9b-prefix.patch +Patch2: python-boto-1.9b-python27.patch BuildRequires: python-devel, python-setuptools-devel BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -26,6 +27,7 @@ use, lightweight wrapper around the Amazon services. %setup -q -n %{pkgname}-%{version} %patch0 -p1 -b .image %patch1 -p1 -b .prefix +%patch2 -p1 -b .python27 %build %{__python} setup.py build @@ -50,6 +52,9 @@ rm -rf $RPM_BUILD_ROOT %{python_sitelib}/* %changelog +* Thu Dec 02 2010 Lubomir Rintel 1.9b-5 +- Apply a patch for python 2.7 support (#659248) + * Thu Nov 18 2010 Robert Scheck 1.9b-4 - Added patch to fix parameter of build_list_params() (#647005)