%define desktop_file_utils_version 0.9 %define nspr_version 4.6 %define nss_version 3.10 %define cairo_version 1.0 %define official_branding 1 Summary: Mozilla Thunderbird mail/newsgroup client Name: thunderbird Version: 2.0.0.6 Release: 1%{?dist} URL: http://www.mozilla.org/projects/thunderbird/ License: MPL Group: Applications/Internet %if %{official_branding} Source0: thunderbird-%{version}-source.tar.bz2 Source1: thunderbird-langpacks-%{version}-20070811.tar.bz2 %else Source0: thunderbird-%{version}%{?beta}-source.tar.bz2 Source1: thunderbird-langpacks-%{version}%{?beta}-20070606.tar.bz2 %endif Source9: thunderbird-mozconfig.fc4 Source10: thunderbird-mozconfig Source11: thunderbird-mozconfig-branded Source12: thunderbird-remi-default-prefs.js Source20: thunderbird.desktop Source21: thunderbird.sh.in Source22: thunderbird.png Source30: thunderbird-open-browser.sh Source100: find-external-requires # Build patches Patch1: firefox-2.0-link-layout.patch Patch2: firefox-1.0-prdtoa.patch Patch4: firefox-1.5.0.10-with-system-nss.patch Patch5: thunderbird-1.5-visibility.patch Patch6: firefox-1.5.0.10-nss-system-nspr.patch Patch10: thunderbird-0.7.3-psfonts.patch Patch11: thunderbird-0.7.3-gnome-uriloader.patch # customization patches Patch24: thunderbird-2.0-default-applications.patch Patch25: thunderbird-1.1-software-update.patch # local bugfixes Patch40: firefox-1.5-bullet-bill.patch Patch41: firefox-2.0.0.4-undo-uriloader.patch Patch42: firefox-1.1-uriloader.patch # font system fixes Patch81: firefox-1.5-nopangoxft.patch Patch82: firefox-1.5-pango-mathml.patch Patch83: firefox-1.5-pango-cursor-position.patch Patch84: firefox-2.0-pango-printing.patch Patch85: firefox-1.5-pango-cursor-position-more.patch Patch86: firefox-1.5-pango-justified-range.patch Patch87: firefox-1.5-pango-underline.patch Patch88: firefox-1.5-xft-rangewidth.patch Patch89: firefox-2.0-pango-ligatures.patch # Other Patch102: firefox-1.5-theme-change.patch Patch103: thunderbird-1.5-profile-migrator.patch Patch104: firefox-1.5-dnd-nograb.patch # Remi Patch200: thunderbird-2.0.0.4-suse-visibility.patch %if %{official_branding} # Required by Mozilla Corporation %else # Not yet approved by Mozillla Corporation %endif BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) %if "%{?fedora}" > "4" Requires: nspr >= %{nspr_version} Requires: nss >= %{nss_version} %endif Requires: cairo >= %{cairo_version} BuildRequires: cairo-devel >= %{cairo_version} BuildRequires: libpng-devel, libjpeg-devel, gtk2-devel BuildRequires: zlib-devel, gzip, zip, unzip %if "%{?fedora}" > "4" BuildRequires: nspr-devel >= %{nspr_version} BuildRequires: nss-devel >= %{nss_version} %endif BuildRequires: libIDL-devel BuildRequires: desktop-file-utils BuildRequires: tcsh BuildRequires: freetype-devel %if "%{?fedora}" > "4" BuildRequires: libXt-devel BuildRequires: libXrender-devel %endif Requires: desktop-file-utils >= %{desktop_file_utils_version} Obsoletes: MozillaThunderbird, thunderbird2 %define mozappdir %{_libdir}/thunderbird-%{version} AutoProv: 0 %define _use_internal_dependency_generator 0 %define __find_requires %{SOURCE100} %description Mozilla Thunderbird is a standalone mail and newsgroup client. #=============================================================================== %prep echo CIBLE = %{name}-%{version}-%{release} [ -f %{SOURCE1} ] || exit 1 %setup -q -n mozilla %patch1 -p1 -b .link-layout %patch2 -p0 #%patch4 -p1 #%patch5 -p1 -b .visibility #%patch6 -p1 %ifnarch i386 %patch200 -p0 -b .visibility %endif %patch10 -p1 -b .psfonts %patch11 -p1 -b .gnome-uriloader %patch24 -p1 -b .default-applications #%patch25 -p0 -b .software-update %patch40 -p1 %patch41 -p1 %patch42 -p0 %if "%{?fedora}" > "4" # font system fixes %patch81 -p1 -b .nopangoxft #%patch82 -p1 -b .pango-mathml %patch83 -p1 -b .pango-cursor-position %patch84 -p0 -b .pango-printing %patch85 -p1 -b .pango-cursor-position-more %patch86 -p1 -b .pango-justified-range %patch87 -p1 -b .pango-underline %patch88 -p1 -b .nopangoxft2 %patch89 -p1 -b .pango-ligatures pushd gfx/src/ps # This sort of sucks, but it works for now. ln -s ../gtk/nsFontMetricsPango.h . ln -s ../gtk/nsFontMetricsPango.cpp . ln -s ../gtk/mozilla-decoder.h . ln -s ../gtk/mozilla-decoder.cpp . popd %endif %patch102 -p0 -b .theme-change %patch103 -p1 -b .profile-migrator #%patch104 -p1 -b .dnd-nograb %if %{official_branding} # Required by Mozilla Corporation %else # Not yet approved by Mozillla Corporation %endif %{__rm} -f .mozconfig %if "%{?fedora}" > "4" %{__cp} %{SOURCE10} .mozconfig %else %{__cp} %{SOURCE9} .mozconfig %endif %if %{official_branding} %{__cat} %{SOURCE11} >> .mozconfig %endif #=============================================================================== %build # Build with -Os as it helps the browser; also, don't override mozilla's warning # level; they use -Wall but disable a few warnings that show up _everywhere_ MOZ_OPT_FLAGS=$(echo $RPM_OPT_FLAGS | %{__sed} -e 's/-O2/-Os/' -e 's/-Wall//') export RPM_OPT_FLAGS=$MOZ_OPT_FLAGS export PREFIX='%{_prefix}' export LIBDIR='%{_libdir}' %ifarch ppc ppc64 s390 s390x %define moz_make_flags -j1 %else %define moz_make_flags %{?_smp_mflags} %endif export LDFLAGS="-Wl,-rpath,%{mozappdir}" export MAKE="gmake %{moz_make_flags}" make -f client.mk build #=============================================================================== %install %{__rm} -rf $RPM_BUILD_ROOT DESTDIR=$RPM_BUILD_ROOT make install %{__mkdir_p} $RPM_BUILD_ROOT{%{_libdir},%{_bindir},%{_datadir}/applications} %{__install} -p -D %{SOURCE22} $RPM_BUILD_ROOT%{_datadir}/pixmaps/%{name}.png desktop-file-install --vendor mozilla \ --dir $RPM_BUILD_ROOT%{_datadir}/applications \ --add-category Network \ --add-category Email \ %{SOURCE20} # set up the thunderbird start script %{__cat} %{SOURCE21} | %{__sed} -e 's,TBIRD_VERSION,%{version},g' > \ $RPM_BUILD_ROOT%{_bindir}/thunderbird %{__chmod} 755 $RPM_BUILD_ROOT/%{_bindir}/thunderbird install -m755 %{SOURCE30} $RPM_BUILD_ROOT/%{mozappdir}/open-browser.sh %{__sed} -i -e 's|LIBDIR|%{_libdir}|g' $RPM_BUILD_ROOT/%{mozappdir}/open-browser.sh # set up our default preferences %{__cat} %{SOURCE12} | %{__sed} -e 's,THUNDERBIRD_RPM_VR,%{version}-%{release},g' \ -e 's,COMMAND,%{mozappdir}/open-browser.sh,g' > \ $RPM_BUILD_ROOT/rh-default-prefs %{__cp} $RPM_BUILD_ROOT/rh-default-prefs $RPM_BUILD_ROOT/%{mozappdir}/greprefs/all-remi.js %{__cp} $RPM_BUILD_ROOT/rh-default-prefs $RPM_BUILD_ROOT/%{mozappdir}/defaults/pref/all-remi.js %{__rm} $RPM_BUILD_ROOT/rh-default-prefs %{__rm} -f $RPM_BUILD_ROOT%{_bindir}/thunderbird-config cd $RPM_BUILD_ROOT%{mozappdir}/chrome find . -name "*" -type d -maxdepth 1 -exec %{__rm} -rf {} \; cd - %{__mkdir_p} $RPM_BUILD_ROOT%{mozappdir}/chrome/icons/default/ %{__cp} other-licenses/branding/%{name}/default.xpm \ $RPM_BUILD_ROOT%{mozappdir}/chrome/icons/default/ %{__cp} other-licenses/branding/%{name}/default.xpm \ $RPM_BUILD_ROOT%{mozappdir}/icons/ # own mozilla plugin dir (#135050) %{__mkdir_p} $RPM_BUILD_ROOT%{_libdir}/mozilla/plugins # Install langpacks %{__mkdir_p} $RPM_BUILD_ROOT%{mozappdir}/extensions %{__tar} xjf %{SOURCE1} >%{name}.lang for langpack in `ls thunderbird-langpacks/*.xpi`; do language=`basename $langpack .xpi` extensiondir=$RPM_BUILD_ROOT%{mozappdir}/extensions/langpack-$language@thunderbird.mozilla.org %{__mkdir_p} $extensiondir unzip $langpack -d $extensiondir find $extensiondir -type f | xargs chmod 644 echo "%lang(${language/-/_}) %{mozappdir}/extensions/langpack-$language@thunderbird.mozilla.org" >>%{name}.lang tmpdir=`mktemp -d %{name}.XXXXXXXX` langtmp=$tmpdir/%{name}/langpack-$language %{__mkdir_p} $langtmp jarfile=$extensiondir/chrome/$language.jar unzip $jarfile -d $langtmp find $langtmp -type f | xargs chmod 644 %{__rm} -rf $jarfile cd $langtmp zip -r -D $jarfile locale %{__rm} -rf locale cd - %{__rm} -rf $tmpdir done %{__rm} -rf thunderbird-langpacks # Copy over the LICENSE install -c -m 644 LICENSE $RPM_BUILD_ROOT%{mozappdir} # ghost files touch $RPM_BUILD_ROOT%{mozappdir}/components/compreg.dat touch $RPM_BUILD_ROOT%{mozappdir}/components/xpti.dat # RC - provide account type [ -f $RPM_BUILD_ROOT%{mozappdir}/isp/gmail.rdf ] || \ install -m 644 mailnews/base/ispdata/gmail.rdf $RPM_BUILD_ROOT%{mozappdir}/isp/ [ -f $RPM_BUILD_ROOT%{mozappdir}/isp/movemail.rdf ] || \ install -m 644 mailnews/base/ispdata/movemail.rdf $RPM_BUILD_ROOT%{mozappdir}/isp/ [ -f $RPM_BUILD_ROOT%{mozappdir}/isp/rss.rdf ] || \ install -m 644 mail/extensions/newsblog/rss.rdf $RPM_BUILD_ROOT%{mozappdir}/isp/ rm -rf $RPM_BUILD_ROOT%{mozappdir}/isp/en-US %clean %{__rm} -rf $RPM_BUILD_ROOT dist/bin/ %pre echo "WARNING : This %{name} RPM is not an offical Fedora build and it" echo "overrides the official one. Don't file bugs on Fedora Project." %post update-desktop-database %{_datadir}/applications %postun update-desktop-database %{_datadir}/applications %files -f %{name}.lang %defattr(-,root,root,-) %attr(755,root,root) %{_bindir}/thunderbird %attr(644,root,root) %{_datadir}/applications/mozilla-thunderbird.desktop %attr(644,root,root) %{_datadir}/pixmaps/thunderbird.png %dir %{mozappdir} %{mozappdir}/LICENSE %{mozappdir}/chrome %{mozappdir}/components %{mozappdir}/defaults %{mozappdir}/dictionaries %dir %{mozappdir}/extensions %{mozappdir}/extensions/{972ce4c6-7e08-4474-a285-3208198ce6fd} %{mozappdir}/greprefs %{mozappdir}/icons %{mozappdir}/init.d %{mozappdir}/isp %{mozappdir}/mozilla-xremote-client %{mozappdir}/open-browser.sh %{mozappdir}/regxpcom %{mozappdir}/res %{mozappdir}/run-mozilla.sh %{mozappdir}/thunderbird-bin %{mozappdir}/updater %{mozappdir}/*.so %exclude %{_includedir}/%{name}-%{version} %exclude %{_datadir}/idl/%{name}-%{version} %exclude %{_libdir}/pkgconfig/*.pc %exclude %{mozappdir}/TestGtkEmbed %exclude %{mozappdir}/xpidl %exclude %{mozappdir}/xpcshell %exclude %{mozappdir}/xpt_dump %exclude %{mozappdir}/xpt_link %exclude %{mozappdir}/xpicleanup %if "%{?fedora}" == "4" %exclude %{mozappdir}/*.chk %exclude %{_datadir}/aclocal/nspr.m4 %endif #=============================================================================== %changelog * Sat Aug 11 2007 Remi Collet 2.0.0.6-1.fc#.remi - rebuild * Wed Aug 8 2007 Christopher Aillon 2.0.0.6-1 - Update to 2.0.0.6 - Own the application directory (#244901) * Fri Jul 20 2007 Remi Collet 2.0.0.5-1.fc#.remi - 2.0.0.5 final * Fri Jun 15 2007 Remi Collet 2.0.0.4-1.fc#.remi - 2.0.0.4 final * Wed Jun 06 2007 Remi Collet 2.0.0.4-0.rc1.fc7.remi - F7 build, rewind release, out enigmail * Sat May 05 2007 Remi Collet 2.0.0.0-1.fc7.remi - F7 build, rewind release, out enigmail - use %%lang for langpacks * Sat May 05 2007 Remi Collet 2.0.0.0-3.fc#.remi - ppc build - bug : enigmail still in thunderbird package * Sun Apr 22 2007 Remi Collet 2.0.0.0-2.fc#.remi - add gmail, movemail and rss account wizard * Thu Apr 19 2007 Christopher Aillon 2.0.0.0-1 - Update to 2.0.0.0 Final * Thu Apr 19 2007 Remi Collet 2.0.0.0-1.fc#.remi - changes from rawhide SRPM - update to 2.0.0.0 final - split enigmail and update to 0.95.0 * Fri Apr 13 2007 Christopher Aillon 2.0.0.0-0.5.rc1 - Fix the desktop file - Clean up the files list - Remove the default client stuff from the pref window * Thu Apr 12 2007 Christopher Aillon 2.0.0.0-0.4.rc1 - Rebuild into Fedora * Wed Apr 11 2007 Christopher Aillon 2.0.0.0-0.3.rc1 - Update langpacks * Fri Apr 06 2007 Remi Collet 2.0.0.0-0.4.rc1.fc6.remi - change desktop entry name * Fri Apr 06 2007 Remi Collet 2.0.0.0-0.3.rc1.fc6.remi - update to 2.0.0.0rc1 * Thu Apr 5 2007 Christopher Aillon 2.0.0.0-0.2.rc1 - Build option tweaks - Bring the install section to parity with Firefox's * Thu Apr 5 2007 Christopher Aillon 2.0.0.0-0.1.rc1 - Update to 2.0.0.0 RC1 * Thu Mar 08 2007 Remi Collet 2.0-0.2.b2.fc6.remi - update to enigmail 0.94.3 (security update) * Sun Jan 28 2007 Remi Collet 2.0-0.1.b2.fc6.remi - First 2.0b2 build * Sun Jan 28 2007 Remi Collet 1.5.0.9-3.fc6.remi.1 - add upstream dnd-nograb.patch * Sat Jan 27 2007 Remi Collet 1.5.0.9-3.fc6.remi - update enigmail-0.94.2 * Sun Dec 24 2006 Remi Collet 1.5.0.9-2.fc6.remi - add enigmail, thanks Suse. * Thu Dec 21 2006 Behdad Esfahbod 1.5.0.9-5 - Added firefox-1.5-pango-underline.patch * Thu Dec 21 2006 Remi Collet 1.5.0.9-1.fc4.remi - rebuild for FC4 from official FC6 SRPM. * Wed Dec 20 2006 Behdad Esfahbod 1.5.0.9-4 - Added firefox-1.5-pango-justified-range.patch * Tue Dec 19 2006 Behdad Esfahbod 1.5.0.9-3 - Added firefox-1.5-pango-cursor-position-more.patch * Tue Dec 19 2006 Christopher Aillon 1.5.0.9-1 - Update to 1.5.0.9 - Take firefox's pango fixes - Don't offer to import...nothing. * Wed Nov 8 2006 Remi Collet 1.5.0.8-1.fc4.remi - rebuild for FC4 from official FC5 SRPM. * Tue Nov 7 2006 Christopher Aillon 1.5.0.8-1 - Update to 1.5.0.8 - Allow choosing of download directory - Take the user to the correct directory from the Download Manager. - Patch to add support for printing via pango from Behdad. - Sync up default invisible character with GTK+ * Sat Sep 16 2006 Remi Collet 1.5.0.7-1.fc4.remi - rebuild for FC4 from official FC5 SRPM. * Wed Sep 13 2006 Christopher Aillon - 1.5.0.7-1 - Update to 1.5.0.7 * Tue Aug 08 2006 Kai Engert - 1.5.0.5-1.1 - Update to 1.5.0.5 - Use dist tag * Fri Jun 27 2006 Remi Collet - 1.5.0.5-1.fc{4,5}.remi - Update to 1.5.0.5 (32 langpacks, new : ga-IE) * Mon Jun 12 2006 Kai Engert - 1.5.0.4-1.1.fc5 - Update to 1.5.0.4 - Fix desktop-file-utils requires * Fri Jun 02 2006 Remi Collet - 1.5.0.4-1.fc{4,5}.remi - Update to 1.5.0.4 * Thu Apr 20 2006 Remi Collet - 1.5.0.2-1.fc5.remi - rebuild for FC5 and for FUN * Thu Apr 20 2006 Remi Collet - 1.5.0.2-1.fc4.remi - Update to 1.5.0.2 * Wed Apr 19 2006 Christopher Aillon - 1.5.0.2-1.1.fc5 - Update to 1.5.0.2 * Sat Mar 04 2006 Remi Collet - 1.5-3.fc4.remi - rebuild for FC4 - provide a default icon, see #177823 * Fri Feb 10 2006 Christopher Aillon - 1.5-3 - Add dumpstack.patch - Improve the langpack install stuff * Tue Feb 07 2006 Jesse Keating - 1.5-2.1 - rebuilt for new gcc4.1 snapshot and glibc changes * Fri Jan 27 2006 Christopher Aillon - 1.5-2 - Add some langpacks back in - Stop providing MozillaThunderbird * Thu Jan 12 2006 Christopher Aillon - 1.5-1 - Official 1.5 release is out * Thu Jan 12 2006 Remi Collet - 1.5-1.fc4.remi - Update to 1.5 (finale) * Fri Dec 23 2005 Remi Collet - 1.5-0.2.fc4.remi - Update to 1.5 rc2 * Sun Dec 18 2005 Remi Collet - 1.5-0.1.fc4.remi - rebuild for FC4 - disable system nspr * Mon Nov 28 2005 Christopher Aillon - 1.5-0.5.1.rc1 - Fix issue with popup dialogs and other actions causing lockups * Sat Nov 5 2005 Christopher Aillon 1.5-0.5.0.rc1 - Update to 1.5 rc1 * Sat Oct 8 2005 Christopher Aillon 1.5-0.5.0.beta2 - Update to 1.5 beta2 * Wed Sep 28 2005 Christopher Aillon 1.5-0.5.0.beta1 - Update to 1.5 beta1 - Bring the install phase of the spec file up to speed