diff --git a/cryptopp-x86-disable-sse2.patch b/cryptopp-x86-disable-sse2.patch new file mode 100644 index 0000000..6cde9f0 --- /dev/null +++ b/cryptopp-x86-disable-sse2.patch @@ -0,0 +1,10 @@ +--- config.h 2010-08-09 14:22:42.000000000 +0300 ++++ config.h 2011-01-23 00:44:28.000000000 +0200 +@@ -1,3 +1,7 @@ ++#ifndef __x86_64__ ++#define CRYPTOPP_DISABLE_SSE2 ++#endif ++ + #ifndef CRYPTOPP_CONFIG_H + #define CRYPTOPP_CONFIG_H + diff --git a/cryptopp.spec b/cryptopp.spec index 06d4f90..289e22b 100644 --- a/cryptopp.spec +++ b/cryptopp.spec @@ -12,6 +12,8 @@ Patch1: cryptopp-5.6.1-s390.patch # Debian patch installs TestVectors and TestData in /usr/share/cryptopp/ # http://groups.google.com/group/cryptopp-users/browse_thread/thread/6fe2192340f07e5d Patch2: cryptopp-data-files-location.patch +# Enable SSE2 only on x86_64 +Patch3: cryptopp-x86-disable-sse2.patch BuildRequires: doxygen, autoconf, libtool BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -61,16 +63,11 @@ rm -f GNUmakefile %patch0 -p1 %patch1 -p1 -b .s390 %patch2 -p1 +%patch3 autoreconf --verbose --force --install perl -pi -e 's/\r$//g' License.txt Readme.txt %build -%ifnarch x86_64 -# Does not build with PIC by default on x86, see -# http://groups.google.com/group/cryptopp-users/browse_thread/thread/d639907b0b1816b9 -export CXXFLAGS="$RPM_OPT_FLAGS -DCRYPTOPP_DISABLE_SSE2" -%endif - %configure --disable-static make %{?_smp_mflags} @@ -130,6 +127,9 @@ rm -rf $RPM_BUILD_ROOT %changelog +* Sun Jan 23 2011 Alexey Kurov - 5.6.1-3 +- patch config.h for enable SSE2 only on x86_64 + * Thu Oct 21 2010 Alexey Kurov - 5.6.1-2 - add -DCRYPTOPP_DISABLE_SSE2 to CXXFLAGS instead of config.h for non-x86_64 (rhbz#645169) - install TestVectors and TestData in cryptopp-progs