Merged update from upstream sources

This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/libpst.git#214c311751a712e9f1bf70b251829a6e3ecf02d7
This commit is contained in:
DistroBaker 2021-02-02 21:38:50 +00:00
parent ce882976d8
commit 87c9ac6c88

View File

@ -3,17 +3,27 @@
%define __python %{__python3}
%endif
%if 0%{?rhel} >= 9
%global with_dii 0
%else
%global with_dii 1
%endif
Summary: Utilities to convert Outlook .pst files to other formats
Name: libpst
Version: 0.6.75
Release: 7.1%{?dist}
Release: 9%{?dist}
License: GPLv2+
URL: http://www.five-ten-sg.com/%{name}/
Source: %{url}/packages/%{name}-%{version}.tar.gz
BuildRequires: make
BuildRequires: libtool gcc-c++
BuildRequires: ImageMagick gd-devel zlib-devel boost-devel libgsf-devel gettext-devel
BuildRequires: gd-devel zlib-devel boost-devel libgsf-devel gettext-devel
%if 0%{with_dii}
BuildRequires: ImageMagick
%endif
%if 0%{?use_python3}
BuildRequires: python3 python3-devel boost-python3 boost-python3-devel
@ -22,19 +32,30 @@ Requires: boost-python3
BuildRequires: python-devel
%endif
Requires: ImageMagick%{?_isa} libgsf gettext
Requires: libgsf gettext
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
%if 0%{with_dii}
Requires: ImageMagick%{?_isa}
%endif
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
%if 0%{with_dii}
%description
The Libpst utilities include readpst which can convert email messages
to both mbox and MH mailbox formats, pst2ldif which can convert the
contacts to .ldif format for import into ldap databases, and pst2dii
which can convert email messages to the DII load file format used by
Summation.
%else
%description
The Libpst utilities include readpst which can convert email messages
to both mbox and MH mailbox formats, pst2ldif which can convert the
contacts to .ldif format for import into ldap databases.
%endif
%package libs
@ -113,6 +134,11 @@ libpst utilities.
%build
autoreconf -fiv
%configure --enable-libpst-shared \
%if 0%{with_dii}
--enable-dii \
%else
--disable-dii \
%endif
--with-boost-python=boost_python%{python3_version_nodots}
%if 0%{?use_python3}
%make_build
@ -132,6 +158,10 @@ make DESTDIR=$RPM_BUILD_ROOT install
find %{buildroot} -name '*.la' -or -name '*.a' | xargs rm -f
mv %{buildroot}%{_datadir}/doc/%{name}-%{version} %{buildroot}%{_datadir}/doc/%{name}
# Remove pst2dii man page, when it's not built
%if !0%{with_dii}
rm %{buildroot}%{_mandir}/man1/pst2dii.1*
%endif
%if 0%{?use_python3}
%ldconfig_scriptlets libs
@ -182,6 +212,12 @@ mv %{buildroot}%{_datadir}/doc/%{name}-%{version} %{buildroot}%{_datadir}/doc/%{
%changelog
* Tue Feb 02 2021 Milan Crha <mcrha@redhat.com> - 0.6.75-9
- Resolves: #1913613 (Disable DII (and ImageMagic dependency) for RHEL 9)
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.75-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Fri Jan 22 2021 Jonathan Wakely <jwakely@redhat.com> - 0.6.75-7
- Rebuilt for Boost 1.75