Accepting request 535455 from home:alarrosa:branches:devel:languages:python
- Update to 0.27.0 * Fix licence: it is MIT, not BSD * At least minimal support of SNI in httpslib. * Small bugfixes and cleanups. * More effort to make build system more robust. * Restore m2.rsa_set_e() and m2.rsa_set_n(). * Make sure that every exceptional return throws and exception and viceversa. - Add patch fix-build-python3.diff to let it build with python3 - Add patch fix-openssl-include-path.diff to fix openssl include path (the code already includes the openssl/ part) - Create a new package python-M2Crypto-doc for documentation since rpmlint was complaining around 75% of the package was documentation. OBS-URL: https://build.opensuse.org/request/show/535455 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-M2Crypto?expand=0&rev=45
This commit is contained in:
parent
eae7642470
commit
8e1366d91b
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:5cae7acc0b34821f8c0ddf6665e482893fe1f198ad6379e61ffa9d8e65f5c199
|
|
||||||
size 1116587
|
|
3
M2Crypto-0.27.0.tar.gz
Normal file
3
M2Crypto-0.27.0.tar.gz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:82317459d653322d6b37f122ce916dc91ddcd9d1b814847497ac796c4549dd68
|
||||||
|
size 1119288
|
16
fix-build-python3.diff
Normal file
16
fix-build-python3.diff
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
Index: M2Crypto-0.27.0/setup.py
|
||||||
|
===================================================================
|
||||||
|
--- M2Crypto-0.27.0.orig/setup.py
|
||||||
|
+++ M2Crypto-0.27.0/setup.py
|
||||||
|
@@ -48,7 +48,10 @@ def _get_additional_includes():
|
||||||
|
stdout=subprocess.PIPE,
|
||||||
|
stderr=subprocess.PIPE)
|
||||||
|
_, err = pid.communicate()
|
||||||
|
- err = [line.lstrip() for line in err.split('\n') if line and line[0] == ' ']
|
||||||
|
+ if sys.version_info[0] == 2:
|
||||||
|
+ err = [line.lstrip() for line in err.split('\n') if line and line[0] == ' ']
|
||||||
|
+ else:
|
||||||
|
+ err = [line.lstrip() for line in err.split(b'\n') if line and line[0] == b' ']
|
||||||
|
return err
|
||||||
|
|
||||||
|
|
13
fix-openssl-include-path.diff
Normal file
13
fix-openssl-include-path.diff
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
Index: M2Crypto-0.27.0/setup.py
|
||||||
|
===================================================================
|
||||||
|
--- M2Crypto-0.27.0.orig/setup.py
|
||||||
|
+++ M2Crypto-0.27.0/setup.py
|
||||||
|
@@ -159,7 +164,7 @@ class _M2CryptoBuildExt(build_ext.build_
|
||||||
|
|
||||||
|
if platform.system() == "Linux":
|
||||||
|
self.include_dirs += _get_additional_includes()
|
||||||
|
- inc_openssl_dir = '/usr/include/openssl'
|
||||||
|
+ inc_openssl_dir = '/usr/include/'
|
||||||
|
if inc_openssl_dir not in self.include_dirs:
|
||||||
|
self.include_dirs.append(inc_openssl_dir)
|
||||||
|
log.debug('self.include_dirs = %s', self.include_dirs)
|
@ -1,3 +1,19 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Oct 18 07:13:58 UTC 2017 - alarrosa@suse.com
|
||||||
|
|
||||||
|
- Update to 0.27.0
|
||||||
|
* Fix licence: it is MIT, not BSD
|
||||||
|
* At least minimal support of SNI in httpslib.
|
||||||
|
* Small bugfixes and cleanups.
|
||||||
|
* More effort to make build system more robust.
|
||||||
|
* Restore m2.rsa_set_e() and m2.rsa_set_n().
|
||||||
|
* Make sure that every exceptional return throws and exception and viceversa.
|
||||||
|
- Add patch fix-build-python3.diff to let it build with python3
|
||||||
|
- Add patch fix-openssl-include-path.diff to fix openssl include path
|
||||||
|
(the code already includes the openssl/ part)
|
||||||
|
- Create a new package python-M2Crypto-doc for documentation since rpmlint
|
||||||
|
was complaining around 75% of the package was documentation.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Sep 26 12:32:25 UTC 2017 - michael@stroeder.com
|
Tue Sep 26 12:32:25 UTC 2017 - michael@stroeder.com
|
||||||
|
|
||||||
|
@ -22,13 +22,17 @@
|
|||||||
%define oldpython python
|
%define oldpython python
|
||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
Name: python-M2Crypto
|
Name: python-M2Crypto
|
||||||
Version: 0.26.4
|
Version: 0.27.0
|
||||||
Release: 0
|
Release: 0
|
||||||
Url: https://gitlab.com/m2crypto/m2crypto
|
Url: https://gitlab.com/m2crypto/m2crypto
|
||||||
Summary: Crypto and SSL toolkit for Python
|
Summary: Crypto and SSL toolkit for Python
|
||||||
License: MIT and ZPL-2.0 and BSD-3-Clause
|
License: MIT and ZPL-2.0 and BSD-3-Clause
|
||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
Source: https://pypi.io/packages/source/M/M2Crypto/M2Crypto-%{version}.tar.gz
|
Source: https://pypi.io/packages/source/M/M2Crypto/M2Crypto-%{version}.tar.gz
|
||||||
|
# PATCH-FIX-UPSTREAM fix-build-python3.diff -- Fixes a str/bytes issue when building with python3
|
||||||
|
Patch0: fix-build-python3.diff
|
||||||
|
# PATCH-FIX-OPENSUSE fix-openssl-include-path.diff -- Fixes include path for openssl
|
||||||
|
Patch1: fix-openssl-include-path.diff
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
BuildRequires: %{python_module devel}
|
BuildRequires: %{python_module devel}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
@ -67,8 +71,28 @@ HMAC'ing AuthCookies for web session management. FTP/TLS client and
|
|||||||
server. S/MIME. ZServerSSL: A HTTPS server for Zope. ZSmime: An S/MIME
|
server. S/MIME. ZServerSSL: A HTTPS server for Zope. ZSmime: An S/MIME
|
||||||
messenger for Zope.
|
messenger for Zope.
|
||||||
|
|
||||||
|
%package -n %{name}-doc
|
||||||
|
Summary: Documentation for the Crypto and SSL toolkit for Python
|
||||||
|
Group: Development/Libraries/Python
|
||||||
|
BuildArch: noarch
|
||||||
|
Requires: %{name} = %{version}
|
||||||
|
|
||||||
|
%description -n %{name}-doc
|
||||||
|
M2Crypto is a crypto and SSL toolkit for Python featuring the following:
|
||||||
|
|
||||||
|
RSA, DSA, DH, HMACs, message digests, symmetric ciphers (including
|
||||||
|
AES). SSL functionality to implement clients and servers. HTTPS
|
||||||
|
extensions to Python's httplib, urllib, and xmlrpclib. Unforgeable
|
||||||
|
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.
|
||||||
|
|
||||||
|
Documentation for the Crypto and SSL toolkit for Python
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n M2Crypto-%{version}
|
%setup -q -n M2Crypto-%{version}
|
||||||
|
%patch0 -p1
|
||||||
|
%patch1 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
export CFLAGS="%{optflags}"
|
export CFLAGS="%{optflags}"
|
||||||
@ -77,6 +101,7 @@ export CFLAGS="%{optflags}"
|
|||||||
%install
|
%install
|
||||||
%python_install
|
%python_install
|
||||||
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
||||||
|
%fdupes %{buildroot}%{_docdir}
|
||||||
|
|
||||||
%if %{with tests}
|
%if %{with tests}
|
||||||
%check
|
%check
|
||||||
@ -86,7 +111,10 @@ export CFLAGS="%{optflags}"
|
|||||||
%files %{python_files}
|
%files %{python_files}
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%doc CHANGES LICENCE README.rst
|
%doc CHANGES LICENCE README.rst
|
||||||
%doc doc/
|
|
||||||
%{python_sitearch}/*
|
%{python_sitearch}/*
|
||||||
|
|
||||||
|
%files -n %{name}-doc
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%doc doc/*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Loading…
Reference in New Issue
Block a user