Sophie

Sophie

distrib > Mageia > 7 > i586 > by-pkgid > 2eea4dbd50149482d664e2a827e695bb > files > 6

botan2-2.9.0-2.1.mga7.src.rpm

%global major_version 9
%define dlname Botan
%define botan_ver 2

%define libname %mklibname botan2_ %{major_version}
%define devname %mklibname botan2 -d

Name:           botan2
Version:        2.9.0
%define subrel  1
Release:        %mkrel 2
Summary:        Crypto and TLS for C++11
Group:          System/Libraries
License:        BSD
URL:            https://botan.randombit.net/
Source0:        https://botan.randombit.net/releases/%{dlname}-%{version}.tgz#!/%{name}-%{version}.tgz
Patch0:         01-remove-rpath-gcc.patch
Patch1:         02-fix-wrong-script-interpreter.patch
Patch2:         0001-Make-CBC-padding-constant-time.patch
Patch3:         0002-Fix-for-ASan.patch

BuildRequires:  gcc-c++
BuildRequires:  python2dist(sphinx)
BuildRequires:  pkgconfig(python3)
BuildRequires:  pkgconfig(bzip2)
BuildRequires:  pkgconfig(zlib)
BuildRequires:  pkgconfig(openssl)
BuildRequires:  python3dist(docutils)
BuildRequires:  python3dist(sphinx)
Requires:       python3

%description
Botan is a BSD-licensed crypto library written in C++. It provides a
wide variety of basic cryptographic algorithms, X.509 certificates and
CRLs, PKCS \#10 certificate requests, a filter/pipe message processing
system, and a wide variety of other features, all written in portable
C++. The API reference, tutorial, and examples may help impart the
flavor of the library. This is the current stable release branch 2.x
of Botan.

%package        -n %{devname}
Summary:        Development files for %{name}
Group:          Development/C++
Requires:       %{name} = %{version}-%{release}
Requires:       %{libname} = %{version}-%{release}
Provides:       %{name}-devel = %{version}-%{release}
Obsoletes:      %{name}-devel < 2.6.0-6

%description    -n %{devname}
The %{devname} package contains libraries and header files for
developing applications that use %{name}.

%package        -n %{libname}
Summary:        Library files for %{name}
Group:          System/Libraries
Requires:       %{name} = %{version}-%{release}
Conflicts:      %{name} < 2.6.0-6

%description    -n %{libname}
The %{libname} package contains library files for %{name}.


%package        doc
Summary:        Documentation for %{name}
Group:          Documentation
BuildArch:      noarch

%description    doc
Documentation for %{name}.

This package contains HTML documentation for %{name}.


%package -n python3-%{name}
Summary:        Python3 bindings for %{name}
Group:          Development/Python
%{?python_provide:%python_provide python3-%{name}}

%description -n python3-%{name}
This package contains the Python3 binding for %{name}.


%prep
%autosetup -p1 -n %{dlname}-%{version}

%build
# we have the necessary prerequisites, so enable optional modules
%global enable_modules bzip2,zlib,openssl

./configure.py \
        --prefix=%{_prefix} \
        --libdir=%{_lib} \
        --docdir=%{_docdir} \
        --cc=gcc \
        --os=linux \
        --cpu=%{_arch} \
        --enable-modules=%{enable_modules} \
        --with-python-version=%{python3_version} \
        --with-sphinx \
	--disable-static-library \
        --with-debug-info

%make_build

%install
%make_install \
     INSTALL_CMD_EXEC="install -p -m 755" \
     INSTALL_CMD_DATA="install -p -m 644"

chmod 755 %{buildroot}%{python3_sitearch}/botan2.py

find %{buildroot} -name '*.a' -delete

%check
LD_LIBRARY_PATH=%{buildroot}%{_libdir} ./botan-test

%files
%license license.txt
%{_bindir}/botan
%{_mandir}/man1/*

%files -n %{libname}
%{_libdir}/libbotan-%{botan_ver}.so.%{major_version}{,.*}

%files -n %{devname}
%license license.txt
%{_includedir}/botan-2/
%{_libdir}/libbotan-%{botan_ver}.so
%{_libdir}/pkgconfig/botan-%{botan_ver}.pc

%files doc
%license license.txt
%{_docdir}/botan-%{version}/

%files -n python3-%{name}
%license license.txt
%{python3_sitearch}/%{name}.py
%{python3_sitearch}/__pycache__/*


%changelog
* Wed Jul 15 2020 daviddavid <daviddavid> 2.9.0-2.1.mga7
+ Revision: 1606323
- backport patches for security issue rhbz#1849743 (CBC padding side channel) from 2.14.0 (mga#26955)

* Mon Jan 07 2019 kekepower <kekepower> 2.9.0-2.mga7
+ Revision: 1351021
- Rebuild for Python 3.7

* Sat Jan 05 2019 kekepower <kekepower> 2.9.0-1.mga7
+ Revision: 1349281
- Update to version 2.9.0

* Sun Oct 28 2018 daviddavid <daviddavid> 2.8.0-2.mga7
+ Revision: 1326405
- add some missing Group
- fix some description and summary
- fix some Conflicts, Obsoletes, Provides
+ kekepower <kekepower>
- Requires appropriate sub packages

* Sun Oct 28 2018 kekepower <kekepower> 2.8.0-1.mga7
+ Revision: 1326389
- Update to version 2.8.0
- Create proper sub pacakges for dev and libs

* Fri Sep 21 2018 umeabot <umeabot> 2.6.0-5.mga7
+ Revision: 1295632
- Mageia 7 Mass Rebuild

* Tue Aug 07 2018 wally <wally> 2.6.0-4.mga7
+ Revision: 1248827
- add back pycache

* Fri Jul 06 2018 daviddavid <daviddavid> 2.6.0-3.mga7
+ Revision: 1242164
- update files list (no more __pycache__ reference)

* Fri May 25 2018 shlomif <shlomif> 2.6.0-2.mga7
+ Revision: 1232167
- fix owned dirs as reported by youri
- New version 2.6.0
+ kekepower <kekepower>
- imported package botan2