File libvmime_zarafa7.spec of Package libvmime_zarafa7

#
# spec file for package libvmime_zarafa7
#
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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/
#


Name:           libvmime_zarafa7
%define lname	libvmime_zarafa7-0
Summary:        Library for working with MIME messages and IMAP/POP/SMTP
License:        GPL-3.0+
Group:          Development/Libraries/C and C++
Version:        0.9.1+svn603
Release:        0
Url:            http://vmime.sf.net/

#Svn-Clone:	https://vmime.svn.sourceforge.net/svnroot/vmime/trunk
Source:         libvmime-%{version}sotag.tar.bz2
Source2:        spice_source.sh
Source3:        libvmime-%{version}.tar.bz2
Source4:        readme.txt
Source5:        build.collax
Source6:        debian.docs
Source7:        libvmime-sotag.diff
Source8:        manual-sotag.xdiff
Source9:        vmime-all4debian.diff
Patch1:         libvmime-nodatetime.diff
Patch3:         vmime-0.8.1-charset-catch.diff
Patch4:         vmime-0.9.2-header-value-on-next-line.diff
Patch5:         vmime-mixed-qp-in-parameter.diff
Patch6:         vmime-0.9.2-qp-in-buffers.diff
Patch7:         vmime-noansiflag.patch
Patch9:         09-vmime-phf-stop-on-whitespace.diff
Patch10:        10-vmime-backport-mailboxList-parser-29954e5.diff
Patch11:        11-vmime-disable-rfc2231.diff
Patch12:        12-vmime-ignore-multiple-colons-in-headers.diff
Patch13:        13-vmime-ignore-newlines.diff
Patch14:        14-vmime-remove-setlocale.diff
Patch15:        15-vmime-wrongly-padded-B64-words.diff
Patch16:        16-vmime-x-uuencode.diff
Patch17:        17-vmime-avoid-unneeded-conversion.diff
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  autoconf
BuildRequires:  automake
BuildRequires:  gcc-c++
BuildRequires:  libtool
BuildRequires:  pkgconfig
BuildRequires:  postfix
%if 0%{?fedora_version} || 0%{?redhat_version} || 0%{?centos_version}
# Somehow it's not drawn in
BuildRequires:  python
%endif
BuildRequires:  xz
%if 0%{?suse_version} >= 1100
BuildRequires:  gettext-tools
BuildRequires:  libselinux-devel
%else
%if 0%{?suse_version} > 0
BuildRequires:  gnutls-devel
%endif
%endif
%if 0%{?fedora_version} > 0 || 0%{?redhat_version} || 0%{?centos_version}
BuildRequires:  gettext
BuildRequires:  gnutls-devel
%endif

%description
VMime is a powerful C++ class library for working with MIME messages
and Internet messaging services like IMAP, POP or SMTP.

With VMime you can parse, generate and modify messages, and also
connect to store and transport services to receive or send messages
over the Internet. The library offers all the features to build a
complete mail client.

%package -n %lname
Summary:        Library for working with MIME messages and IMAP/POP/SMTP
Group:          System/Libraries

%description -n %lname
VMime is a powerful C++ class library for working with MIME messages
and Internet messaging services like IMAP, POP or SMTP.

With VMime you can parse, generate and modify messages, and also
connect to store and transport services to receive or send messages
over the Internet. The library offers all the features to build a
complete mail client.

%package devel
Summary:        Library for working with MIME messages and IMAP/POP/SMTP
Group:          Development/Libraries/C and C++
Requires:       %lname = %version
Conflicts:      libvmime-devel

%description devel
VMime is a powerful C++ class library for working with MIME messages
and Internet messaging services like IMAP, POP or SMTP.

With VMime you can parse, generate and modify messages, and also
connect to store and transport services to receive or send messages
over the Internet. The library offers all the features to build a
complete mail client.

%prep
%setup -qn vmime
%patch -P 1 -P 3 -P 4 -P 5 -P 6 -P 7 -p1
%patch -P 9 -P 10 -P 11 -P 12 -P 13 -P 14 -P 15 -P 16 -P 17 -p1

%build
export CFLAGS="%optflags -DVMIME_ALWAYS_GENERATE_7BIT_PARAMETER=1";
export CXXFLAGS="$CFLAGS";
# sendmail's awesome location.
export PATH="$PATH:/usr/sbin";
%configure --disable-static --disable-sasl --disable-tls
make %{?_smp_mflags};

%install
b="%buildroot";
make install DESTDIR="$b" docdir="%_docdir/%name";
find "$b" -type f -name "*.la" -delete;
ln -sfv libvmime_zarafa7.so "$b/%_libdir/libvmime.so"
mv -v "$b/%_libdir/pkgconfig"/{vmime_zarafa7.pc,vmime.pc}

%check
make check;

%post -n %lname -p /sbin/ldconfig

%postun -n %lname -p /sbin/ldconfig

%files -n %lname
%defattr(-,root,root)
%_libdir/%{name}*.so.*

%files devel
%defattr(-,root,root)
%doc %_docdir/%name
%_includedir/*
%_libdir/libvmime*.so
%_libdir/pkgconfig/*.pc

%changelog
openSUSE Build Service is sponsored by