!1 Cryptopp:开源C++加密方案类库
From: @ustb_atrx Reviewed-by: @zhujianwei001 Signed-off-by: @zhujianwei001
This commit is contained in:
commit
91c85c2407
BIN
CRYPTOPP_8_2_0.tar.gz
Normal file
BIN
CRYPTOPP_8_2_0.tar.gz
Normal file
Binary file not shown.
87
cryptopp.spec
Executable file
87
cryptopp.spec
Executable file
@ -0,0 +1,87 @@
|
||||
%global _version CRYPTOPP_8_2_0
|
||||
Name: cryptopp
|
||||
Version: 8.2.0
|
||||
Release: 1
|
||||
Summary: Crypto++ Library is a free C++ class library of cryptographic schemes
|
||||
|
||||
License: BSL-1.0
|
||||
|
||||
URL: https://www.cryptopp.com/
|
||||
Source0: https://github.com/weidai11/cryptopp/archive/%{_version}.tar.gz
|
||||
|
||||
BuildRequires: gcc make
|
||||
|
||||
%description
|
||||
Crypto++ Library is a free C++ class library of cryptographic schemes.
|
||||
The Crypto++ library was orginally written by Wei Dai. The library is now maintained by several team members and the community.
|
||||
Currently the library contains algorithms like AES, RSA, MD5 etc..
|
||||
|
||||
%package devel
|
||||
Summary: Development files for %{name}
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
This package contains the header files and libraries for developing with %{name}.
|
||||
|
||||
%prep
|
||||
%autosetup -n %{name}-%{_version}
|
||||
|
||||
%build
|
||||
%make_build
|
||||
|
||||
%install
|
||||
# doc
|
||||
mkdir -p %{buildroot}%{_datadir}/%{name}-%{version}/TestData
|
||||
mkdir -p %{buildroot}%{_datadir}/%{name}-%{version}/TestVectors
|
||||
cp -a %{_builddir}/%{name}-%{_version}/TestData/*.dat %{buildroot}%{_datadir}/%{name}-%{version}/TestData
|
||||
cp -a %{_builddir}/%{name}-%{_version}/TestVectors/*.txt %{buildroot}%{_datadir}/%{name}-%{version}/TestVectors
|
||||
|
||||
# lib file
|
||||
mkdir -p %{buildroot}/%{_libdir}
|
||||
cp -a %{_builddir}/%{name}-%{_version}/libcryptopp.a %{buildroot}%{_libdir}/libcryptopp-%{version}.a
|
||||
|
||||
# include file
|
||||
mkdir -p %{buildroot}/%{_includedir}/%{name}
|
||||
cp -a %{_builddir}/%{name}-%{_version}/*.h %{buildroot}/%{_includedir}/%{name}
|
||||
|
||||
# executable file
|
||||
mkdir -p %{buildroot}/%{_bindir}
|
||||
cp -a %{_builddir}/%{name}-%{_version}/cryptest.exe %{buildroot}%{_bindir}
|
||||
|
||||
%clean
|
||||
rm -rf %{buildroot}
|
||||
|
||||
%files
|
||||
%defattr(0644,root,root,0644)
|
||||
%doc History.txt Install.txt Readme.txt
|
||||
%license License.txt
|
||||
%{_datadir}/%{name}-%{version}/TestData/*.dat
|
||||
%{_datadir}/%{name}-%{version}/TestVectors/*.txt
|
||||
%attr(0755,root,root) %{_bindir}/cryptest.exe
|
||||
|
||||
%files devel
|
||||
%defattr(0644,root,root,0644)
|
||||
%{_libdir}/*.a
|
||||
%{_includedir}/%{name}/*.h
|
||||
|
||||
%post devel
|
||||
ln -s %{_libdir}/libcryptopp-%{version}.a %{_libdir}/libcryptopp.a
|
||||
|
||||
%postun devel
|
||||
if [ -h %{_libdir}/libcryptopp.a ]; then
|
||||
rm -f %{_libdir}/libcryptopp.a
|
||||
fi
|
||||
if [ -d %{_includedir}/%{name} ]; then
|
||||
rm -rf %{_includedir}/%{name}
|
||||
fi
|
||||
|
||||
%postun
|
||||
if [ -d %{_datadir}/%{name}-%{version} ]; then
|
||||
rm -rf %{_datadir}/%{name}-%{version}
|
||||
fi
|
||||
|
||||
%changelog
|
||||
* Thu Sep 10 2020 <liurenxu@talkweb.com.cn>
|
||||
- Package init
|
||||
|
||||
|
||||
4
cryptopp.yaml
Normal file
4
cryptopp.yaml
Normal file
@ -0,0 +1,4 @@
|
||||
version_control: github
|
||||
src_repo: weidai11/cryptopp
|
||||
tag_prefix: ^CRYPTOPP_
|
||||
seperator: _
|
||||
Loading…
x
Reference in New Issue
Block a user