Resolves: #1913613 (Disable DII (and ImageMagic dependency) for RHEL 9)
This commit is contained in:
parent
8c99f9a94d
commit
aa52f8376a
34
libpst.spec
34
libpst.spec
@ -3,6 +3,12 @@
|
|||||||
%define __python %{__python3}
|
%define __python %{__python3}
|
||||||
%endif
|
%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
|
Summary: Utilities to convert Outlook .pst files to other formats
|
||||||
Name: libpst
|
Name: libpst
|
||||||
Version: 0.6.75
|
Version: 0.6.75
|
||||||
@ -13,7 +19,11 @@ Source: %{url}/packages/%{name}-%{version}.tar.gz
|
|||||||
|
|
||||||
BuildRequires: make
|
BuildRequires: make
|
||||||
BuildRequires: libtool gcc-c++
|
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}
|
%if 0%{?use_python3}
|
||||||
BuildRequires: python3 python3-devel boost-python3 boost-python3-devel
|
BuildRequires: python3 python3-devel boost-python3 boost-python3-devel
|
||||||
@ -22,19 +32,30 @@ Requires: boost-python3
|
|||||||
BuildRequires: python-devel
|
BuildRequires: python-devel
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
Requires: ImageMagick%{?_isa} libgsf gettext
|
Requires: libgsf gettext
|
||||||
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
|
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_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)")}
|
%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
||||||
|
|
||||||
|
|
||||||
|
%if 0%{with_dii}
|
||||||
%description
|
%description
|
||||||
The Libpst utilities include readpst which can convert email messages
|
The Libpst utilities include readpst which can convert email messages
|
||||||
to both mbox and MH mailbox formats, pst2ldif which can convert the
|
to both mbox and MH mailbox formats, pst2ldif which can convert the
|
||||||
contacts to .ldif format for import into ldap databases, and pst2dii
|
contacts to .ldif format for import into ldap databases, and pst2dii
|
||||||
which can convert email messages to the DII load file format used by
|
which can convert email messages to the DII load file format used by
|
||||||
Summation.
|
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
|
%package libs
|
||||||
@ -113,6 +134,11 @@ libpst utilities.
|
|||||||
%build
|
%build
|
||||||
autoreconf -fiv
|
autoreconf -fiv
|
||||||
%configure --enable-libpst-shared \
|
%configure --enable-libpst-shared \
|
||||||
|
%if 0%{with_dii}
|
||||||
|
--enable-dii \
|
||||||
|
%else
|
||||||
|
--disable-dii \
|
||||||
|
%endif
|
||||||
--with-boost-python=boost_python%{python3_version_nodots}
|
--with-boost-python=boost_python%{python3_version_nodots}
|
||||||
%if 0%{?use_python3}
|
%if 0%{?use_python3}
|
||||||
%make_build
|
%make_build
|
||||||
@ -132,6 +158,10 @@ make DESTDIR=$RPM_BUILD_ROOT install
|
|||||||
find %{buildroot} -name '*.la' -or -name '*.a' | xargs rm -f
|
find %{buildroot} -name '*.la' -or -name '*.a' | xargs rm -f
|
||||||
mv %{buildroot}%{_datadir}/doc/%{name}-%{version} %{buildroot}%{_datadir}/doc/%{name}
|
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}
|
%if 0%{?use_python3}
|
||||||
%ldconfig_scriptlets libs
|
%ldconfig_scriptlets libs
|
||||||
|
Loading…
Reference in New Issue
Block a user