# # spec file for package libmcrypt # # Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: libmcrypt Version: 2.5.8 Release: 222.7 Summary: Data Encryption Library License: GPL-2.0+ and LGPL-2.1+ Group: System/Libraries Url: http://mcrypt.sourceforge.net/ Source: https://sourceforge.net/projects/mcrypt/files/Libmcrypt/%{version}/%{name}-%{version}.tar.gz Source1: ftp://ftp.st.ryukoku.ac.jp/pub/security/tool/mcrypt/libmcrypt/modules/%{name}-idea-0.9.tar.gz Source2: https://sourceforge.net/projects/mcrypt/files/Libmcrypt/Production/%{name}-mars-0.9.tar.gz Source3: https://sourceforge.net/projects/mcrypt/files/Libmcrypt/Production/%{name}-rc6-0.9.tar.gz Source4: https://sourceforge.net/projects/mcrypt/files/Libmcrypt/Production/%{name}-skipjack-0.9.tar.gz Patch0: %{name}-%{version}.diff Patch1: %{name}-%{version}-notdynamic.diff Patch2: %{name}-%{version}-uninitialized.diff Patch3: %{name}-%{version}-prototypes.diff BuildRequires: autoconf BuildRequires: automake BuildRequires: gcc-c++ BuildRequires: libtool BuildRoot: %{_tmppath}/%{name}-%{version}-build %description Libmcrypt is a data encryption library. The library is thread safe and provides encryption and decryption functions. This version of the library supports many encryption algorithms and encryption modes. Supported algorithms include SERPENT, RIJNDAEL, 3DES, GOST, SAFER+, CAST-256, RC2, XTEA, 3WAY, TWOFISH, BLOWFISH, ARC. FOUR, and WAKE. %package devel Summary: Development Package for Libmcrypt Group: Development/Libraries/C and C++ Requires: libmcrypt = %{version} %description devel Files needed for software development using libmcrypt. %prep %setup -q -a 1 -a 2 -a 3 -a 4 %patch0 %patch1 %patch2 %patch3 %build libtoolize --force # add algorithms for m in idea mars rc6 skipjack; do cp libmcrypt-$m-*/modules/algorithms/*.[ch] modules/algorithms sed -e "s/^EXTRA_DIST = /EXTRA_DIST = $m.h /" \ -e "s/^EXTRA_LTLIBRARIES = /EXTRA_LTLIBRARIES = $m.la /" \ modules/algorithms/Makefile.am >modules/algorithms/Makefile.am2 mv modules/algorithms/Makefile.am2 modules/algorithms/Makefile.am echo "${m}_la_SOURCES = $m.c" >> modules/algorithms/Makefile.am echo "${m}_la_LDFLAGS = -module -avoid-version -rpath \$(pkglibdir)" >> modules/algorithms/Makefile.am done # remove algorithms which do not work remove_module() { cd modules/algorithms; for mname in $*; do sed -e "/${mname//-/_}_la/d" -e "s/${mname}.h//" -e "s/${mname}.la//" Makefile.am > Makefile.am2; mv Makefile.am2 Makefile.am done cd - for mname in $*; do sed -e "s/${mname}//" configure.in > configure.in.2 mv configure.in.2 configure.in done } # big endian architectures %ifarch sparc ppc ppc64 s390 s390x mips remove_module panama rc6 %endif # 64bit architectures and s390 %ifarch alpha ia64 s390 remove_module cast-256 mars rc6 %endif rm -f acinclude.m4 autoreconf -fi %configure \ --enable-static make %{?_smp_mflags} %install make DESTDIR=%{buildroot} install %{?_smp_mflags} # do not ship these rm %{buildroot}%{_libdir}/libmcrypt.la %check make check %{?_smp_mflags} || : %files %defattr(-, root, root) %{_libdir}/libmcrypt.so.* %files devel %defattr(-, root, root) %doc AUTHORS ChangeLog KNOWN-BUGS NEWS README THANKS TODO doc/README.* %doc doc/example.c %{_bindir}/* %{_datadir}/aclocal/* %{_includedir}/* %{_libdir}/libmcrypt.a %{_libdir}/libmcrypt.so %{_mandir}/man3/* %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %changelog * Thu Mar 19 2015 astieger@suse.com - Add source URLs for all files - use verbatim upstream files * Thu Feb 26 2015 mpluskal@suse.com - Cleanup spec file with spec-cleaner - Use source url - Update dependencies * Sat Jan 12 2013 coolo@suse.com - remove suse_update_config * Sat Nov 19 2011 coolo@suse.com - add libtool as buildrequire to avoid implicit dependency * Sun Oct 31 2010 jengelh@medozas.de - Use %%_smp_mflags * Tue Nov 3 2009 coolo@novell.com - updated patches to apply with fuzz=0 * Wed Jan 16 2008 prusnak@suse.cz - fix uninitialized variables (uninitialized.diff) - fix prototypes in DES and TripleDES algorithms (prototypes.diff) * Sun Aug 12 2007 crrodriguez@suse.de - run ldconfig - remove libtool archive with empty dependency_libs - remove obsolete/bogus/unversioned Provides and Obsoletes. * Fri May 4 2007 prusnak@suse.cz - updated to 2.6.8 (maintenance update) - cleaned spec file - dropped obsolete patches: * libmcrypt-2.5.7-automake.diff (included in update) - disabled 'make check' in build for now * Wed Jan 25 2006 mls@suse.de - converted neededforbuild to BuildRequires * Sun Jan 18 2004 ro@suse.de - fix libmcrypt.m4 for current automake * Fri Jan 9 2004 schwab@suse.de - Remove useless acinclude.m4. * Thu Sep 25 2003 schwab@suse.de - Fix remove_module. * Thu Jul 24 2003 tcrhak@suse.cz - update to version 2.5.7 * Tue Jan 21 2003 meissner@suse.de - Also remove the ignored algorithms from configure so that it builds on non Intel 32bit again. * Fri Jan 10 2003 tcrhak@suse.cz - disabled dynamic loading for idea, mars, rc6 and skipjack; this is the default for modules within the main tarball for security reasons * Mon Jan 6 2003 tcrhak@suse.cz - update to version 2.5.5 * Thu Dec 19 2002 tcrhak@suse.cz - update to version 2.5.4 * Tue Sep 17 2002 ro@suse.de - removed bogus self-provides * Fri Aug 16 2002 kukuk@suse.de - Move libmcrypt.la to main package to make libtools dlopen happy. * Mon Aug 5 2002 prehak@suse.cz - update to version 2.5.2 - fixed includes in mars module algorithm * Tue Jun 18 2002 meissner@suse.de - do not build panama, rc6 for ppc64 either. * Fri Apr 26 2002 tcrhak@suse.cz - added prototype of mcrypt_check_version to mcrypt.h (necessary for mcrypt to configure on ia64) - added description of mcrypt_check_version to mcrypt.3 - don't build panama and rc6 for s390x * Thu Apr 25 2002 coolo@suse.de - use %%_libdir - added mips to big endian architectures * Mon Feb 25 2002 tcrhak@suse.cz - moved *.la from the devel to the main package; needed by mcrypt_list_algorithms() and mcrypt_list_modes() * Tue Jan 29 2002 cihlar@suse.cz - added /usr/bin/* and /usr/share/aclocal/* to %%files * Fri Jan 25 2002 cihlar@suse.cz - updated libmcrypt to version 2.4.20 - updated all modules to version 0.9 - removed obsolete patches for rc6 and mars - run suse_update_config always - added "make check" - fixed lists of algorithms which do not work on each architecture - compile with $RPM_OPT_FLAGS also on ia64 * Thu Aug 23 2001 schwab@suse.de - Fix integration of MARS and RC6. - Compile with -O1 on ia64 to workaround compiler bug. - Update libltdl directory. - Configure with --enable-static to get static modules. * Wed Aug 8 2001 cihlar@suse.cz - completed MODULES list - fix to work only with existing modules from MODULES * Mon Jul 16 2001 kukuk@suse.de - Build all modules on SPARC again * Wed Jun 27 2001 pblaha@suse.cz - update on 2.4.15 - fix problem with make static lib * Mon Mar 26 2001 pblaha@suse.cz - update on 2.4.10 * Thu Feb 1 2001 pblaha@suse.cz - update on 2.4.9 * Wed Jan 24 2001 pblaha@suse.cz - update on 2.4.8 * Tue Nov 21 2000 pblaha@suse.cz - update on 2.4.7 * Wed Sep 13 2000 fober@suse.de - for s390: %%%%suse_update_config in %%%%setup - removed mars idea rc6 cast-256 on s390 - removed wake on s390: this one is especially strange: its only modes: line in the test says ,,failed'', yet the algorithm-lines say ,,ok''! * Mon Jun 26 2000 uli@suse.de - removed rc6 and idea for PPC * Sun Jun 4 2000 kukuk@suse.de - Remove algorithms which does not work correctly on SPARC * Fri May 26 2000 bubnikv@suse.cz - sorted * Mon Apr 17 2000 bubnikv@suse.cz - added addon cipher algorithms - some cipher algorithms do not work correctly on axp, those are removed from package on axp * Fri Apr 7 2000 bubnikv@suse.cz - new package (version 2.4.2)