From 37e0f202d8d011bd2bca08373f3923dd7a2e2077 Mon Sep 17 00:00:00 2001 From: Paul Howarth Date: Jan 25 2018 15:47:09 +0000 Subject: log() not available in libgmp, need libm too --- diff --git a/python-crypto-2.6.1-link.patch b/python-crypto-2.6.1-link.patch new file mode 100644 index 0000000..7fe65b5 --- /dev/null +++ b/python-crypto-2.6.1-link.patch @@ -0,0 +1,13 @@ +log() function not available in libgmp, need libm too + +--- setup.py ++++ setup.py +@@ -349,7 +349,7 @@ kw = {'name':"pycrypto", + # _fastmath (uses GNU mp library) + Extension("Crypto.PublicKey._fastmath", + include_dirs=['src/','/usr/include/'], +- libraries=['gmp'], ++ libraries=['gmp','m'], + sources=["src/_fastmath.c"]), + + # Hash functions diff --git a/python-crypto.spec b/python-crypto.spec index 71982f2..24640df 100644 --- a/python-crypto.spec +++ b/python-crypto.spec @@ -10,7 +10,7 @@ Summary: Cryptography library for Python Name: python-crypto Version: 2.6.1 -Release: 19%{?dist} +Release: 20%{?dist} # Mostly Public Domain apart from parts of HMAC.py and setup.py, which are Python License: Public Domain and Python URL: http://www.pycrypto.org/ @@ -19,6 +19,7 @@ Patch0: python-crypto-2.4-optflags.patch Patch1: python-crypto-2.4-fix-pubkey-size-divisions.patch Patch2: pycrypto-2.6.1-CVE-2013-7459.patch Patch3: pycrypto-2.6.1-unbundle-libtomcrypt.patch +Patch4: python-crypto-2.6.1-link.patch BuildRequires: coreutils BuildRequires: findutils BuildRequires: gcc @@ -71,6 +72,9 @@ This is the Python 3 build of the package. rm -rf src/libtom %patch3 +# log() not available in libgmp, need libm too +%patch4 + # setup.py doesn't run 2to3 on pct-speedtest.py cp pct-speedtest.py pct-speedtest3.py 2to3 -wn pct-speedtest3.py @@ -109,8 +113,11 @@ PYTHONPATH=%{buildroot}%{python3_sitearch} %{__python3} pct-speedtest3.py %{python3_sitearch}/pycrypto-%{version}-py3.*.egg-info %changelog +* Thu Jan 25 2018 Paul Howarth - 2.6.1-20 +- log() not available in libgmp, need libm too + * Mon Oct 23 2017 Simone Caronni - 2.6.1-19 -- Rebuild for libtomcrypt update. +- Rebuild for libtomcrypt update * Tue Sep 05 2017 Igor Gnatenko - 2.6.1-18 - Depend on %%{_bindir}/2to3 instead of python2-tools