15
0

Accepting request 347783 from home:dstoecker

Update to most recent version.

OBS-URL: https://build.opensuse.org/request/show/347783
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-M2Crypto?expand=0&rev=26
This commit is contained in:
Denisart Benjamin
2015-12-07 22:54:48 +00:00
committed by Git OBS Bridge
parent 05ceb6a754
commit 9efb17b334
6 changed files with 33 additions and 120 deletions

View File

@@ -17,15 +17,15 @@
Name: python-M2Crypto
Version: 0.22.3
Version: 0.22.5
Release: 0
Url: http://chandlerproject.org/bin/view/Projects/MeTooCrypto
Url: https://gitlab.com/m2crypto/m2crypto
Summary: Crypto and SSL toolkit for Python
License: MIT and ZPL-2.0 and BSD-3-Clause
Group: Development/Languages/Python
Source: http://pypi.python.org/packages/source/M/M2Crypto/M2Crypto-%{version}.tar.gz
# PATCH-FIX-UPSTREAM python-M2Crypto-SWIG-3.0.5.patch -- https://github.com/martinpaljak/M2Crypto/issues/60
Patch0: python-M2Crypto-SWIG-3.0.5.patch
# PATCH-FIX-UPSTREAM M2Crypto-0.22.5-SSLv2_link_error.patch -- remove useless reference to SSL version 2
Patch0: M2Crypto-0.22.5-SSLv2_link_error.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: openssl
BuildRequires: openssl-devel
@@ -39,10 +39,8 @@ BuildRequires: swig
%endif
%if 0%{?suse_version}
%py_requires
%if 0%{?suse_version} > 1010
BuildRequires: fdupes
%endif
%endif
%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
Provides: python-m2crypto = %{version}
Obsoletes: python-m2crypto < %{version}
@@ -58,35 +56,21 @@ HMAC'ing AuthCookies for web session management. FTP/TLS client and
server. S/MIME. ZServerSSL: A HTTPS server for Zope. ZSmime: An S/MIME
messenger for Zope.
It currently lives at
http://wiki.osafoundation.org/bin/view/Projects/MeTooCrypto. The
original M2Crypto homepage is at http://sandbox.rulemaker.net/ngps/m2/.
%prep
%setup -n M2Crypto-%{version}
%if 0%{?suse_version} >= 1315
%patch0 -p1
%endif
%build
CFLAGS="%{optflags}" python setup.py build
%install
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
# The SWIG shadow file is not being installed by setup.py
cp SWIG/_m2crypto.py %{buildroot}%{python_sitearch}/M2Crypto/
# install demo files manually
# (otherwise we can't perform %%fdupes on them the right way)
#chmod 0644 demo/{https.howto/get_https,ssl/twistedsslclient,ssl/twistedsslserver,tinderbox/slave,x509/certdata2pem}.py
export DOCDIR=%{buildroot}%{_docdir}/%{name}
mkdir -p $DOCDIR
%fdupes $DOCDIR
install -m 644 README $DOCDIR
%files
%defattr(-,root,root)
%doc %{_docdir}/%{name}
%doc README
%{python_sitearch}/*
%changelog