File gmime.spec of Package gmime
#
# spec file for package gmime (Version 2.2.23)
#
# Copyright (c) 2008 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: gmime
BuildRequires: glib-sharp2 glib2-devel gtk-doc gtk-sharp2 gtk-sharp2-gapi mono-devel zlib-devel
Version: 2.2.23
Release: 1
Url: http://spruce.sourceforge.net/gmime/
Group: Productivity/Networking/Email/Utilities
License: LGPL v2.1 or later; Public Domain, Freeware; X11/MIT
Summary: MIME Library Utilities
Source: %{name}-%{version}.tar.bz2
Patch: gmime-cflags.patch
# PATCH-FIX-OPENSUSE gmime-no-off_t.patch bnc344662 bgo501830
Patch: gmime-no-off_t.patch
Patch3: gmime-monoreq.patch
Patch4: gmime-gacutil-bootstrap.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Requires: libgmime-2_0-3 = %{version}
%description
GMime is a set of utilities for parsing and creating messages using the
Multipurpose Internet Mail Extension (MIME).
Authors:
--------
Jeffrey Stedfast <fejj@gnome.org>
%package -n libgmime-2_0-3
License: LGPL v2.1 or later; Public Domain, Freeware; X11/MIT
Group: Development/Libraries/C and C++
Summary: MIME Library
Requires: %{name} >= %{version}
%description -n libgmime-2_0-3
GMime is a set of utilities for parsing and creating messages using the
Multipurpose Internet Mail Extension (MIME).
Authors:
--------
Jeffrey Stedfast <fejj@gnome.org>
%package sharp
License: LGPL v2.1 or later; Public Domain, Freeware; X11/MIT
Group: Development/Libraries/Other
Summary: MIME Library Mono Bindings
Requires: libgmime-2_0-3 = %{version} gtk-sharp2 glib-sharp2
%description sharp
GMime is a set of utilities for parsing and creating messages using the
Multipurpose Internet Mail Extension (MIME).
Authors:
--------
Jeffrey Stedfast <fejj@gnome.org>
%package devel
License: LGPL v2.1 or later; Public Domain, Freeware; X11/MIT
Group: Development/Libraries/C and C++
Summary: MIME Library
Requires: libgmime-2_0-3 = %{version} glib2-devel zlib-devel glibc-devel
%description devel
GMime is a set of utilities for parsing and creating messages using the
Multi-purpose Internet Mail Extension (MIME).
Authors:
--------
Jeffrey Stedfast <fejj@ximian.com>
%package doc
License: LGPL v2.1 or later; Public Domain, Freeware; X11/MIT
Group: Development/Libraries/C and C++
Summary: MIME Library documentation
%description doc
GMime is a set of utilities for parsing and creating messages using the
Multipurpose Internet Mail Extension (MIME).
This package contains additional documentation for the main package.
Authors:
--------
Jeffrey Stedfast <fejj@ximian.com>
%define __find_requires env sh -c 'filelist=($(cat)) && { printf "%s\\n" "${filelist[@]}" | /usr/lib/rpm/find-requires | grep -v "no package provides" ; } '
%prep
%setup -q
# Replace all occurrences of variable sized off_t by goffset:
sed -i "s/off_t/goffset/g;s/OFF_T/G_GINT64_FORMAT/g" */*.[ch]
mv mono/GMime.metadata.in mono/GMime.metadata
# api file is not regenerated during build. Fix it now:
# (And current gtk# does not support goffset yet. If it will not in
# future, change goffset to long in the metadata.)
sed -i s/off_t/long/g mono/gmime-api.raw
# And finally fix all remaining problems related to off_t:
%patch
# fix requires for sharp bindings (GMIME_VERSION != SONAME_VERSION)
%patch3
%patch4
%build
cp /usr/share/gettext/config.rpath .
autoreconf -f -i
export CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing"
%configure\
--disable-static\
--enable-rfc2047-workarounds\
--enable-gtk-doc
make %{?jobs:-j%jobs}
%install
%makeinstall GACUTIL_FLAGS="/package gtk-sharp /root -bootstrap $RPM_BUILD_ROOT%{_prefix}/lib"
# rename to prevent conflict with uu* utils from sharutils
mv $RPM_BUILD_ROOT%{_bindir}/uuencode $RPM_BUILD_ROOT%{_bindir}/gmime-uuencode
mv $RPM_BUILD_ROOT%{_bindir}/uudecode $RPM_BUILD_ROOT%{_bindir}/gmime-uudecode
for FILE in COPYING ; do
MD5SUM=$(md5sum $FILE | sed 's/ .*//')
if test -f /usr/share/doc/licenses/md5/$MD5SUM ; then
ln -sf /usr/share/doc/licenses/md5/$MD5SUM $FILE
fi
done
# Obsolete GNOME1 gnome-config style:
rm $RPM_BUILD_ROOT%{_libdir}/*Conf.sh
%clean
rm -rf $RPM_BUILD_ROOT
%post -n libgmime-2_0-3 -p /sbin/ldconfig
%postun -n libgmime-2_0-3 -p /sbin/ldconfig
%files
%defattr (-, root, root)
# NEWS is empty
%doc AUTHORS COPYING ChangeLog PORTING README TODO
%exclude %{_bindir}/gmime-config
%{_bindir}/*
%files -n libgmime-2_0-3
%defattr (-, root, root)
%{_libdir}/*.so.*
%files sharp
%defattr (-, root, root)
%dir %{_prefix}/lib/mono/gmime-sharp
%dir %{_prefix}/lib/mono/gac/gmime-sharp
%dir %{_prefix}/lib/mono/gac/gmime-sharp/2.2.0.0__677013d4cb5910f0
%{_prefix}/lib/mono/gmime-sharp/gmime-sharp.dll
%{_prefix}/lib/mono/gac/gmime-sharp/2.2.0.0__677013d4cb5910f0/gmime-sharp.dll
%{_prefix}/lib/mono/gac/gmime-sharp/2.2.0.0__677013d4cb5910f0/gmime-sharp.dll.config
# devel files:
%{_datadir}/gapi-2.0/gmime-api.xml
%{_libdir}/pkgconfig/gmime-sharp.pc
%files devel
%defattr (-, root, root)
%{_bindir}/gmime-config
%{_includedir}/gmime-2.0
%{_libdir}/*.*a
%{_libdir}/*.so
%{_libdir}/pkgconfig/gmime-2.0.pc
%files doc
%defattr (-, root, root)
%{_datadir}/gtk-doc/html/*
%changelog
* Fri Oct 17 2008 sbrabec@suse.cz
- Updated to version 2.2.23:
* documentation updated
* New faster method for calculating nearest power of 2.
* New functions backported from 2.3.x:
g_mime_parser_get_headers_begin, g_mime_parser_get_headers_end
* Only ref the message if it is non-NULL.
- Fixed failure in mono binding installation.
* Fri Aug 15 2008 sbrabec@suse.cz
- Updated to version 2.2.22:
* Bug fixes.
* Memory leak fix.
* See ChangeLog for more.
* Tue Apr 01 2008 sbrabec@suse.cz
- Updated to version 2.2.18:
* Bug fixes.
* New minor features.
* Completely rewritten rfc2047_encode_merge_rfc822_words.
* See ChangeLog for more.
- Ported off_t removal patches.
* Mon Mar 31 2008 sbrabec@suse.cz
- Fixed C# ABI corruption in gmime-no-off_t-api.patch (bnc#375195).
* Mon Jan 21 2008 ro@suse.de
- work around problem in mono-find-requires if the sharp bindings
are a subpackage of the one providing the library
* Wed Dec 05 2007 sbrabec@suse.cz
- Removed off_t from the API. Fixes weird CFLAGS forcing gmime's
off_t size to packages using gmime (#344662, GNOME#501830).
* Mon Nov 19 2007 sbrabec@suse.cz
- Updated to version 2.2.11:
* Conditional for building with large file support.
* 64-bit compatibility improvements.
* Changed the license to LGPLv2.
* Minor fixes and improvements.
* Wed Sep 26 2007 joeshaw@suse.de
- Add a patch to fix the Mono bindings when GMime is built with
large file support. (bnc #327589)
* Wed Aug 08 2007 sbrabec@suse.cz
- Fixed dependencies to allow to install more instances of library.
* Wed Aug 08 2007 ro@suse.de
- remove devel dependencies from library package
* Mon Aug 06 2007 sbrabec@suse.cz
- Updated to version 2.2.10:
* Implemented a conditional workaround for broken rfc2047
encodings.
- Enabled large file support and broken rfc2047 workaround.
- Split package according to shared library policy.
- Package gmime-sharp separately.
* Mon Jul 16 2007 sbrabec@suse.cz
- Fixed licenses linking.
* Sun Jul 15 2007 aj@suse.de
- Build sharp files again.
* Fri Jul 13 2007 sbrabec@suse.cz
- Updated to version 2.2.9:
* New functions.
* Bug fixes.
* Memory leak fixes.
* Fri Mar 30 2007 rguenther@suse.de
- Add zlib-devel BuildRequires
* Fri Feb 16 2007 mvaner@suse.cz
- Compare strings properly, not as pointers, bug #225721
- stdin-cmp.patch
* Tue Feb 13 2007 sbrabec@suse.cz
- Do not build unusable static libraries (#238552#c17).
* Tue Feb 06 2007 sbrabec@suse.cz
- Reduced BuildRequires.
* Wed Jan 10 2007 sbrabec@suse.cz
- Spec file cleanup.
* Tue Jan 09 2007 joeshaw@suse.de
- Clean up BuildRequires
* Mon Jan 08 2007 ro@suse.de
- GNOME moved to /usr
* Fri Oct 20 2006 sbrabec@suse.cz
- Update to version 2.2.3:
* Decode the values for Subject, From, Reply-To.
* Code imporvements.
* Bug fixes.
* Mon Oct 16 2006 schwab@suse.de
- Make sure config.rpath is present.
* Fri Mar 17 2006 joeshaw@suse.de
- Update to version 2.2.1. This contains a fix for reading mbox
files in the middle of the last message, which would cause a
tight CPU loop. Fixes bnc #156916 and probably also #156927.
* Thu Feb 16 2006 joeshaw@suse.de
- Update the official tarball from 2.1.18 to 2.1.19. There are
actually no changes to the code at all, since the (now removed)
backported patch contained all the differences between 2.1.18
and 2.1.19. This just makes already fixed bugs like bnc 147515
a lot easier to spot.
* Wed Jan 25 2006 mls@suse.de
- converted neededforbuild to BuildRequires
* Sat Jan 21 2006 joeshaw@suse.de
- Added a patch which backports an important fix from 2.1.19 to
2.1.18.
* Sat Jan 14 2006 gekker@suse.de
- Fixup nfb and requires for new gtk-sharp2-packaging
- Fixup filelist
* Sat Jan 14 2006 joeshaw@suse.de
- Updated to version 2.1.18
* Tue Jan 10 2006 sbrabec@suse.cz
- Updated to version 2.1.17.
* Sun Sep 04 2005 aj@suse.de
- build as non-root.
- Add check-build.sh.
* Sat Aug 20 2005 gekker@suse.de
- Updated to version 2.1.16
- Require gtk-sharp2
* Tue Jul 12 2005 sbrabec@suse.cz
- Updated to version 2.1.15.
* Mon Mar 14 2005 gekker@suse.de
- Add gmime-mono-leak.patch to fix memory leaks.
* Tue Mar 08 2005 gekker@suse.de
- Update to version 2.1.13
* Tue Feb 08 2005 ro@suse.de
- rename uu{en,de}code to avoid conflict with sharutils
(taken from source-provided specfile)
* Mon Feb 07 2005 ro@suse.de
- gtk-doc docu back to /opt/gnome
* Sat Feb 05 2005 gekker@suse.de
- Update to version 2.1.11.
- Enable C# bindings, add deps to neededforbuild
- Change prefix to /usr, for mono to work
* Thu Jan 06 2005 sbrabec@suse.cz
- Updated to version 2.1.9.
* Fri Aug 20 2004 sbrabec@suse.cz
- Updated to unstable version 2.1.7, needed by balsa.
* Fri Aug 20 2004 ke@suse.de
- gmime-doc.patch: Switch to DocBook DTD 4.1; version 3.0 does not
support QANDASET, etc; reported by Stanislav Brabec.
* Thu Aug 19 2004 sbrabec@suse.cz
- New SuSE package, version 2.0.14.