2011-01-25 09:06:12 +00:00
|
|
|
#
|
|
|
|
|
# spec file for package libcryptopp
|
|
|
|
|
#
|
2017-01-28 16:37:57 +00:00
|
|
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
2011-01-25 09:06:12 +00:00
|
|
|
#
|
|
|
|
|
# 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/
|
|
|
|
|
#
|
|
|
|
|
|
2012-03-18 18:07:05 +00:00
|
|
|
|
2013-03-01 18:39:52 +00:00
|
|
|
%define major 5
|
|
|
|
|
%define minor 6
|
2016-09-14 16:45:39 +00:00
|
|
|
%define patch 4
|
2013-03-01 18:39:52 +00:00
|
|
|
|
2011-01-25 09:06:12 +00:00
|
|
|
Name: libcryptopp
|
2012-10-16 07:24:00 +00:00
|
|
|
# When updating, remember to update cryptopp.pc and baselibs.conf as well.
|
2013-03-01 18:39:52 +00:00
|
|
|
Version: %{major}.%{minor}.%{patch}
|
2012-02-06 00:02:57 +00:00
|
|
|
Release: 0
|
2013-03-01 18:39:52 +00:00
|
|
|
%define pkg_version %{major}%{minor}%{patch}
|
2012-02-06 00:02:57 +00:00
|
|
|
# There is no upstream interface version information.
|
|
|
|
|
# Therefore we need unique basenames:
|
2016-09-14 16:45:39 +00:00
|
|
|
%define soname %{major}_%{minor}
|
2017-01-28 16:37:57 +00:00
|
|
|
Summary: Cryptographic library for C++
|
2013-03-01 18:39:52 +00:00
|
|
|
License: BSL-1.0
|
2011-01-25 09:06:12 +00:00
|
|
|
Group: Development/Libraries/C and C++
|
2012-02-06 00:02:57 +00:00
|
|
|
Url: http://www.cryptopp.com
|
2013-03-01 18:39:52 +00:00
|
|
|
Source: http://www.cryptopp.com/cryptopp%{pkg_version}.zip
|
2014-08-21 13:24:16 +00:00
|
|
|
Source1: baselibs.conf
|
2011-10-14 15:26:48 +00:00
|
|
|
Source2: cryptopp.pc
|
2012-10-16 07:24:00 +00:00
|
|
|
# PATCH-FEATURE-OPENSUSE libcryptopp-shared.patch -- improve shared library creation
|
2011-10-14 15:26:48 +00:00
|
|
|
Patch1: libcryptopp-shared.patch
|
2014-08-21 13:08:26 +00:00
|
|
|
# PATCH-BUILDFIX-OPENSUSE 0001-disable_os_rng_test.patch sfalken@opensuse.org -- disable OS Random Number Generator test
|
|
|
|
|
Patch4: 0001-disable_os_rng_test.patch
|
2011-10-14 15:26:48 +00:00
|
|
|
BuildRequires: gcc-c++
|
|
|
|
|
BuildRequires: pkg-config
|
2013-03-01 18:39:52 +00:00
|
|
|
BuildRequires: unzip
|
2011-01-25 09:06:12 +00:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%description
|
2017-01-28 16:37:57 +00:00
|
|
|
The Crypto++ library is a C++ class library of cryptographic schemes.
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%package -n %{name}%{soname}
|
2011-01-25 09:06:12 +00:00
|
|
|
Summary: Cryptographic Library for C++
|
|
|
|
|
Group: System/Libraries
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%description -n %{name}%{soname}
|
2017-01-28 16:37:57 +00:00
|
|
|
The Crypto++ library provides authenticated encryption, stream and
|
|
|
|
|
block ciphers, block cipher operation modes, message authentication
|
|
|
|
|
codes, hash functions, PKI crypto, key agreement schemes and elliptic
|
|
|
|
|
curve crypto.
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%package -n %{name}-devel
|
2017-01-28 16:37:57 +00:00
|
|
|
Summary: Development files for libcryptopp, a cryptographic library for C++
|
2011-01-25 09:06:12 +00:00
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
|
Requires: %{name}%{soname} = %{version}
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%description -n %{name}-devel
|
2017-01-28 16:37:57 +00:00
|
|
|
The Crypto++ library is a C++ class library of cryptographic schemes.
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q -c "%{name}-%{version}"
|
2013-03-01 18:39:52 +00:00
|
|
|
%patch1 -p1
|
2014-08-21 13:08:26 +00:00
|
|
|
%patch4 -p1
|
2016-09-14 16:45:39 +00:00
|
|
|
#mv config.recommend config.h
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%build
|
2011-10-14 15:26:48 +00:00
|
|
|
make %{?_smp_mflags} \
|
2017-01-28 16:37:57 +00:00
|
|
|
CXXFLAGS="-DNDEBUG %{optflags} -fPIC" \
|
2011-10-14 15:26:48 +00:00
|
|
|
CXX="g++" \
|
2017-01-29 12:01:39 +00:00
|
|
|
all
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%install
|
2011-10-14 15:26:48 +00:00
|
|
|
make \
|
2012-10-16 07:24:00 +00:00
|
|
|
DESTDIR=%{buildroot} \
|
2010-08-09 22:30:27 +00:00
|
|
|
PREFIX="%{_prefix}" \
|
2016-09-14 16:45:39 +00:00
|
|
|
LIBDIR="%{_libdir}" \
|
2012-10-16 07:24:00 +00:00
|
|
|
LIBSUFFIX="-%{version}" \
|
2010-08-09 22:30:27 +00:00
|
|
|
install
|
2016-09-14 16:45:39 +00:00
|
|
|
rm -rf "%{buildroot}%{_bindir}" %{buildroot}%{_datadir}/cryptopp
|
2011-10-14 15:26:48 +00:00
|
|
|
mkdir %{buildroot}%{_libdir}/pkgconfig/
|
|
|
|
|
cp %{SOURCE2} %{buildroot}%{_libdir}/pkgconfig/
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%check
|
2016-09-14 16:45:39 +00:00
|
|
|
LD_LIBRARY_PATH=%{buildroot}%{_libdir} make test
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%post -n %{name}%{soname} -p /sbin/ldconfig
|
|
|
|
|
%postun -n %{name}%{soname} -p /sbin/ldconfig
|
|
|
|
|
|
|
|
|
|
%files -n %{name}%{soname}
|
|
|
|
|
%defattr(-,root,root)
|
2016-09-14 16:45:39 +00:00
|
|
|
%{_libdir}/libcryptopp.so.%{major}.*
|
2010-08-09 22:30:27 +00:00
|
|
|
|
|
|
|
|
%files -n %{name}-devel
|
|
|
|
|
%defattr(-,root,root)
|
2010-12-16 23:45:58 +00:00
|
|
|
%doc License.txt Readme.txt
|
2010-08-09 22:30:27 +00:00
|
|
|
%{_includedir}/cryptopp
|
|
|
|
|
%{_libdir}/libcryptopp.so
|
2011-10-14 15:26:48 +00:00
|
|
|
%{_libdir}/pkgconfig/cryptopp.pc
|
2011-07-11 08:35:56 +00:00
|
|
|
|
2011-01-25 09:06:12 +00:00
|
|
|
%changelog
|