From 2a9f58be7d8a8b3c6acdf275d9fb36709c8c9be3 Mon Sep 17 00:00:00 2001 From: Miloslav Trmac Date: Apr 26 2007 23:05:18 +0000 Subject: - Make m2xmlrpclib work with Python 2.5 Resolves: #237902 --- diff --git a/m2crypto-0.17-xmlrpc.patch b/m2crypto-0.17-xmlrpc.patch new file mode 100644 index 0000000..49fc6cd --- /dev/null +++ b/m2crypto-0.17-xmlrpc.patch @@ -0,0 +1,13 @@ +--- /usr/lib/python2.4/site-packages/M2Crypto/m2xmlrpclib.py 2006-03-20 20:26:28.000000000 +0100 ++++ m2crypto-0.17/M2Crypto/m2xmlrpclib.py 2007-04-27 00:12:51.000000000 +0200 +@@ -14,7 +14,9 @@ + + user_agent = "M2Crypto_XMLRPC/%s - %s" % (__version__, Transport.user_agent) + +- def __init__(self, ssl_context=None): ++ def __init__(self, ssl_context=None, *args, **kw): ++ if getattr(Transport, '__init__', None) is not None: ++ Transport.__init__(self, *args, **kw) + if ssl_context is None: + self.ssl_ctx=SSL.Context('sslv23') + else: diff --git a/m2crypto.spec b/m2crypto.spec index a547bb7..9909d44 100644 --- a/m2crypto.spec +++ b/m2crypto.spec @@ -3,10 +3,11 @@ Summary: Support for using OpenSSL in python scripts Name: m2crypto Version: 0.17 -Release: 1 +Release: 2 Source0: http://wiki.osafoundation.org/pub/Projects/MeTooCrypto/m2crypto-%{version}.tar.gz Patch0: m2crypto-0.17-timeouts.patch Patch1: m2crypto-0.17-Py_ssize_t.patch +Patch2: m2crypto-0.17-xmlrpc.patch License: BSDish Group: System Environment/Libraries URL: http://wiki.osafoundation.org/bin/view/Projects/MeTooCrypto @@ -22,6 +23,7 @@ This package allows you to call OpenSSL functions from python scripts. %setup -q %patch0 -p1 %patch1 -p1 -b .Py_ssize_t +%patch2 -p1 -b .xmlrpc # Red Hat opensslconf.h #includes an architecture-specific file, but SWIG # doesn't follow the #include. @@ -71,6 +73,10 @@ rm -rf $RPM_BUILD_ROOT %{python_sitearch}/M2Crypto %changelog +* Fri Apr 27 2007 Miloslav Trmac - 0.17-2 +- Make m2xmlrpclib work with Python 2.5 + Resolves: #237902 + * Wed Jan 17 2007 Miloslav Trmac - 0.17-1 - Update to m2crypto-0.17 - Update for Python 2.5