150 lines
4.5 KiB
RPMSpec
150 lines
4.5 KiB
RPMSpec
|
%define realversion %(echo %version | tr -d .)
|
||
|
Name: libcryptopp0
|
||
|
Version: 5.6.2
|
||
|
Release: 6mamba
|
||
|
Summary: Free C++ class library of cryptographic schemes
|
||
|
Group: System/Libraries
|
||
|
Vendor: openmamba
|
||
|
Distribution: openmamba
|
||
|
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
|
||
|
URL: https://cryptopp.com/
|
||
|
Source: http://downloads.sourceforge.net/project/cryptopp/cryptopp/%{version}/cryptopp%{realversion}.zip
|
||
|
Patch0: libcryptopp-5.6.2-gnumakefile.patch
|
||
|
Patch1: libcryptopp-5.6.1-gcc-4.7.patch
|
||
|
Patch2: libcryptopp-5.6.1-libcryptopp-CXXFLAGS.patch
|
||
|
License: Public domain
|
||
|
## AUTOBUILDREQ-BEGIN
|
||
|
BuildRequires: glibc-devel
|
||
|
BuildRequires: libgcc
|
||
|
BuildRequires: libstdc++6-devel
|
||
|
## AUTOBUILDREQ-END
|
||
|
BuildRequires: unzip
|
||
|
BuildRequires: gcc-c++
|
||
|
BuildRequires: hd2u
|
||
|
#%ifarch x86_64
|
||
|
#Provides: libcryptopp.so()(64bit)
|
||
|
#%else
|
||
|
#Provides: libcryptopp.so
|
||
|
#%endif
|
||
|
|
||
|
%description
|
||
|
Crypto++ Library is a free C++ class library of cryptographic schemes.
|
||
|
Currently the library consists of the following, some of which are other people's code, repackaged into classes.
|
||
|
One purpose of Crypto++ is to act as a repository of public domain (not copyrighted) source code. Although the library is copyrighted as a compilation, the individual files in it (except for a few exceptions listed in the license) are in the public domain.
|
||
|
|
||
|
%package devel
|
||
|
Group: Development/Libraries
|
||
|
Summary: Files for development of applications which will use %{name}
|
||
|
Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release}
|
||
|
|
||
|
%description devel
|
||
|
Crypto++ Library is a free C++ class library of cryptographic schemes.
|
||
|
Currently the library consists of the following, some of which are other people's code, repackaged into classes.
|
||
|
This package contains the header files and static libraries for Crypto++.
|
||
|
|
||
|
%package tools
|
||
|
Summary: Programs for manipulating %{name} routines
|
||
|
Group: Development/Tools
|
||
|
Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release}
|
||
|
|
||
|
%description tools
|
||
|
Crypto++ Library is a free C++ class library of cryptographic schemes.
|
||
|
Currently the library consists of the following, some of which are other people's code, repackaged into classes.
|
||
|
This package contains programs for manipulating %{name} routines.
|
||
|
|
||
|
%debug_package
|
||
|
|
||
|
%prep
|
||
|
%setup -q -c -n %{name}-%{version}
|
||
|
# All files have ^M end of lines, fix that for the makefile patch to apply
|
||
|
find . -type f -exec dos2unix {} \;
|
||
|
%patch0 -p1
|
||
|
|
||
|
|
||
|
%build
|
||
|
%make LIBDIR=%{_lib} \
|
||
|
CXXFLAGS+="%{optflags} -fPIC -std=c++03"
|
||
|
|
||
|
%install
|
||
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
||
|
%makeinstall LIBDIR=%{_lib}
|
||
|
|
||
|
install -d -m0755 %{buildroot}%{_libdir}/pkgconfig
|
||
|
cat > %{buildroot}%{_libdir}/pkgconfig/cryptopp0.pc << _EOF
|
||
|
prefix=%{_prefix}
|
||
|
exec_prefix=%{_libexecdir}
|
||
|
libdir=%{_libdir}
|
||
|
|
||
|
Name: libcryptopp0
|
||
|
Description: A free C++ class library of cryptographic schemes
|
||
|
Version: 5.6.2
|
||
|
URL: http://www.cryptopp.com
|
||
|
Requires:
|
||
|
Conflicts:
|
||
|
Libs: -lcryptopp
|
||
|
Libs.private:
|
||
|
Cflags:
|
||
|
_EOF
|
||
|
|
||
|
%clean
|
||
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
||
|
|
||
|
%pre
|
||
|
if [ $1 -gt 1 ]; then
|
||
|
[ -L %{_includedir}/cryptopp ] || {
|
||
|
mkdir -p %{_includedir}/crypto++
|
||
|
mv %{_includedir}/cryptopp/* %{_includedir}/crypto++/
|
||
|
rmdir %{_includedir}/cryptopp
|
||
|
}
|
||
|
fi
|
||
|
:
|
||
|
|
||
|
%post -p /sbin/ldconfig
|
||
|
%postun -p /sbin/ldconfig
|
||
|
|
||
|
%files
|
||
|
%defattr(-,root,root,0755)
|
||
|
%{_libdir}/libcryptopp.so.*
|
||
|
%{_libdir}/libcrypto++.so.*
|
||
|
|
||
|
%files devel
|
||
|
%defattr(-,root,root,0755)
|
||
|
%{_includedir}/cryptopp
|
||
|
%dir %{_includedir}/crypto++
|
||
|
%{_includedir}/crypto++/*.h
|
||
|
%{_libdir}/libcryptopp.a
|
||
|
%{_libdir}/libcryptopp.so
|
||
|
%{_libdir}/libcrypto++.a
|
||
|
%{_libdir}/libcrypto++.la
|
||
|
%{_libdir}/libcrypto++.so
|
||
|
%{_libdir}/pkgconfig/cryptopp0.pc
|
||
|
|
||
|
#%files tools
|
||
|
#%defattr(-,root,root,0755)
|
||
|
#%{_bindir}/cryptest
|
||
|
|
||
|
%changelog
|
||
|
* Thu Jun 24 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 5.6.2-6mamba
|
||
|
- move libcryptopp.so to devel package
|
||
|
|
||
|
* Wed Jun 23 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 5.6.2-5mamba
|
||
|
- legacy package
|
||
|
|
||
|
* Sat Apr 30 2016 Silvan Calarco <silvan.calarco@mambasoft.it> 5.6.2-4mamba
|
||
|
- add pkg-config file
|
||
|
|
||
|
* Fri Jan 29 2016 Silvan Calarco <silvan.calarco@mambasoft.it> 5.6.2-3mamba
|
||
|
- rebuilt with gcc 5.3.0
|
||
|
|
||
|
* Mon Aug 19 2013 Silvan Calarco <silvan.calarco@mambasoft.it> 5.6.2-2mamba
|
||
|
- %pre: fix /usr/include/cryptopp directory becoming a symlink
|
||
|
|
||
|
* Mon Aug 19 2013 Silvan Calarco <silvan.calarco@mambasoft.it> 5.6.2-1mamba
|
||
|
- update to 5.6.2
|
||
|
|
||
|
* Wed Oct 24 2012 Silvan Calarco <silvan.calarco@mambasoft.it> 5.6.1-1mamba
|
||
|
- update to 5.6.1
|
||
|
|
||
|
* Thu Aug 21 2008 gil <puntogil@libero.it> 5.5.2-1mamba
|
||
|
- added patch
|