File claws-mail.spec of Package claws-mail

#
# spec file for package claws-mail (Version 3.7.2)
#
# Copyright (c) 2009 SUSE LINUX Products 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/
#

# norootforbuild


Name:           claws-mail
Version:        3.7.2
Release:        3
License:        GPL v3 or later
Group:          Productivity/Networking/Email/Clients
Url:            http://www.claws-mail.org/
Summary:        A lightweight and highly configurable email client
Source0:        http://prdownloads.sourceforge.net/sylpheed-claws/%{name}-%{version}.tar.bz2
Patch0:         claws-mail-python.diff
Patch1:         claws-mail-desktop.diff
# PATCH-FIX-UPSTREAM claws-mail-3.8.1-procmime-vuln.patch bnc#784463 -- NULL pointer derefence while processing email content. 
Patch2:         claws-mail-3.8.1-procmime-vuln.patch
BuildRequires:  NetworkManager-devel
BuildRequires:  compface
BuildRequires:  db-devel
BuildRequires:  enchant-devel
BuildRequires:  gettext
BuildRequires:  gmp-devel
BuildRequires:  gnutls-devel
BuildRequires:  gpgme-devel
BuildRequires:  gtk2-devel
BuildRequires:  libetpan-devel >= 0.57
BuildRequires:  openldap2-devel
BuildRequires:  pilot-link-devel
BuildRequires:  pkgconfig
BuildRequires:  startup-notification-devel
BuildRequires:  update-desktop-files
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Requires:       pinentry-gtk2
Requires:       %{name}-lang = %{version}
Provides:       sylpheed-claws
Obsoletes:      sylpheed-claws

%description
Claws Mail (previously known as Sylpheed-Claws) is a lightweight and
highly configurable email client and news reader based on the GTK+ GUI
toolkit, it runs on the X Window System.

Claws Mail is free software distributed under the GNU GPL.

To run Claws Mail use 'claws-mail' on the command line.

When claws-mail is executed for the first time a configuration 'Wizard'
will appear prompting you for the minimum information necessary to
create a new account.

%package devel
License:        GPL v2 or later
Summary:        A lightweight and highly configurable email client
Group:          Productivity/Networking/Email/Clients
Provides:       claws-mail:/usr/include/claws-mail/main.h
Requires:       claws-mail = %{version}
Requires:       enchant-devel
Requires:       glib2-devel
Requires:       gnutls-devel
Requires:       gpgme-devel
Requires:       gtk2-devel
Requires:       libetpan-devel
Requires:       openldap2-devel

%description devel
Claws Mail (previously known as Sylpheed-Claws) is a lightweight and
highly configurable email client and news reader based on the GTK+ GUI
toolkit, it runs on the X Window System.

Claws Mail is free software distributed under the GNU GPL.

To run Claws Mail use 'claws-mail' on the command line.

When claws-mail is executed for the first time a configuration 'Wizard'
will appear prompting you for the minimum information necessary to
create a new account.

%lang_package
%prep
%setup -q
%patch0
%patch1
%patch2 -p1

%build
%configure \
        --docdir=%{_datadir}/claws-mail \
        --disable-static \
        --enable-ldap \
        --enable-ipv6 \
        --enable-openssl \
        --enable-jpilot \
        --enable-spamassassin-plugin \
        --enable-dillo-viewer-plugin \
        --enable-trayicon-plugin \
        --enable-pgpcore-plugin \
        --enable-pgpmime-plugin \
        --enable-pgpinline-plugin \
        --disable-demo-plugin \
        --enable-crash-dialog \
        --enable-startup-notification \
        --enable-compface \
        --enable-libetpan
%__make %{?jobs:-j%jobs}

%install
%makeinstall
# Clean up
%__rm %{buildroot}%{_libdir}/claws-mail/plugins/*.la
# install desktop file
%suse_update_desktop_file -G "Email client" claws-mail
# we want to have the icon installed in /usr/share/pixmaps
%__mkdir_p %{buildroot}%{_datadir}/pixmaps/
%__cp claws-mail-64x64.png %{buildroot}%{_datadir}/pixmaps/
%__rm -rf %{buildroot}%{_datadir}/icons
# Tools
%__cp -r tools %{buildroot}%{_datadir}/%{name}
%__rm %{buildroot}%{_datadir}/claws-mail/tools/Makefile*
%__mv %{buildroot}%{_datadir}/claws-mail/tools/README ./README.tools
# fixing permissions
%__chmod 755 %{buildroot}%{_datadir}/claws-mail/tools/*
%__chmod 644 %{buildroot}%{_datadir}/claws-mail/tools/multiwebsearch.conf
%__chmod 644 %{buildroot}%{_datadir}/claws-mail/tools/ca-certificates.crt
%find_lang %{name}

%clean
%__rm -rf %{buildroot}

%files
%defattr(-,root,root)
%doc ABOUT-NLS AUTHORS COPYING ChangeLog INSTALL NEWS README README.tools RELEASE_NOTES TODO
%{_bindir}/claws-mail
%{_bindir}/sylpheed-claws
%dir %{_libdir}/claws-mail
%dir %{_libdir}/claws-mail/plugins
%{_libdir}/claws-mail/plugins/*.so
%{_libdir}/claws-mail/plugins/*.deps
%{_datadir}/applications/claws-mail.desktop
%{_mandir}/man1/claws-mail.1.gz
%{_datadir}/pixmaps/claws-mail-64x64.png
%dir %{_datadir}/claws-mail
%doc %{_datadir}/claws-mail/RELEASE_NOTES
%dir %{_datadir}/claws-mail/manual
%dir %{_datadir}/claws-mail/manual/en
%dir %{_datadir}/claws-mail/manual/es
%dir %{_datadir}/claws-mail/manual/fr
%dir %{_datadir}/claws-mail/manual/pl
%doc %{_datadir}/claws-mail/manual/*/claws-mail-manual.*
%dir %{_datadir}/claws-mail/tools
%dir %{_datadir}/claws-mail/tools/kdeservicemenu
%{_datadir}/claws-mail/tools/*.sh
%{_datadir}/claws-mail/tools/*.pl
%{_datadir}/claws-mail/tools/*.py
%{_datadir}/claws-mail/tools/*.conf
%{_datadir}/claws-mail/tools/ca-certificates.crt
%{_datadir}/claws-mail/tools/tb2claws-mail
%{_datadir}/claws-mail/tools/u*
%{_datadir}/claws-mail/tools/kdeservicemenu/*

%files devel
%defattr(-,root,root)
%{_includedir}/claws-mail/
%{_libdir}/pkgconfig/claws-mail.pc

%files lang -f %{name}.lang

%changelog
openSUSE Build Service is sponsored by