# -*- mode: RPM-SPEC; coding: utf-8 -*-
%def_without debug
%def_without xprint
%def_with branding
%def_with nspr
%def_with nss
%def_without libxul
%def_with mozldap
%if_with debug
%set_strip_method none
%endif # debug
Summary: Mozilla Thunderbird is a redesign of the Mozilla mail component.
Summary(ru_RU.UTF-8): Mozilla Thunderbird - это реинкарнация почтовой компоненты Mozilla
Name: %tbird_name
Version: %tbird_version
Release: %tbird_release
License: MPL/GPL
Group: Networking/Mail
URL: http://www.mozilla.org/projects/thunderbird/
Packager: Alexey Gladkov <legion@altlinux.ru>
Source0: %name-source.tar
Source1: %name-icons.tar
Source2: %name.userContent.css
Source3: %name.desktop
Source5: .mozconfig-thunderbird
Source6: thunderbird-mailto
Source7: %name-build-scripts.tar
Source8: fix_headers.sh
Source9: thunderbird-midration.sh
Patch3: thunderbird-1.5-embedding-linker-fix.patch
Patch4: thunderbird-alt-url-handler.patch
Patch5: thunderbird-alt-pref-fix.patch
Patch6: 01_locale.patch
Patch7: thunderbird-alt-extensions-dir.patch
Patch8: firefox-1.5.0.1-alt-asm-directive.patch
Patch9: firefox-alt-install-paths-fix.patch
Patch10: firefox-alt-system-nspr-flags.patch
# https://bugzilla.mozilla.org/show_bug.cgi?id=345134
Patch11: thunderbird-gcc-4.1-fix.patch
Patch12: firefox-nopangoxft.patch
Patch14: thunderbird-alt-libs-fix.patch
Patch15: thunderbird-alt-with-system-mozldap.patch
Patch16: thunderbird-fix-nss-libs.patch
Patch17: thunderbird-fix-startup.patch
Patch18: thunderbird-path.patch
Patch20: thunderbird-fix-375292.patch
BuildRequires(pre): rpm-build-thunderbird
# Automatically added by buildreq on Fri Mar 24 2006
BuildRequires: doxygen gcc-c++ imake libfreetype-devel libgtk+2-devel libIDL-devel libjpeg-devel
BuildRequires: libpng-devel libXinerama-devel libXp-devel libXt-devel libXft-devel libXext-devel makedepend
BuildRequires: unzip xorg-cf-files zip chrpath browser-plugins-npapi-devel
BuildRequires: libnspr-devel nss-utils libnss-devel libnss-devel-static mozldap-devel
%{?_with_xprint:Requires: xorg-x11-xprt}
Requires: gtk+2 >= 2.2.0 url_handler >= 0.2.1-alt2 freetype2 browser-plugins-npapi
Conflicts: thunderbird-enigmail < 0.84.2
Conflicts: thunderbird-ru < 0.7.2
Obsoletes: thunderbird-calendar
Provides: mailclient
Conflicts: thunderbird < 1.5
BuildRequires: autoconf_2.13
%set_autoconf_version 2.13
%description
Mail/news client based on the Mozilla web browser. The mail/news
client supports IMAP, POP, and NNTP and has an easy to use interface.
%description -l ru_RU.UTF-8
Почтовая/новостная программа на базе браузера Web Mozilla.
Программа поддерживает протоколы IMAP, POP, NNTP и имеет
легкий в использовании интерфейс.
%package devel
Requires: %name = %version-%release
Summary: Mozilla Thunderbird development files
Group: Development/Other
%description devel
Mozilla Thunderbird development files
%prep
%setup -q -n %name-%version -c
%setup -q -n %name-%version/mozilla -T -D -a1
%setup -q -n %name-%version/mozilla -T -D -a7
%patch3 -p1 -b .fix3
%patch4 -p1 -b .fix4
%patch5 -p1 -b .fix5
%patch6 -p1 -b .fix6
%patch7 -p1 -b .fix7
%patch8 -p1 -b .fix8
%patch9 -p1 -b .fix9
%patch10 -p1 -b .fix10
#patch12 -p1 -b .fix12
%patch14 -p1 -b .fix14
%patch15 -p1 -b .fix15
%patch16 -p1 -b .fix16
%patch17 -p1 -b .fix17
%patch18 -p1 -b .fix18
#patch20 -p1 -b .fix20
%build
%add_optflags %optflags_shared
%add_findprov_lib_path %tbird_prefix
subst 's|AC_CONFIG_AUX_DIR(\${srcdir}/build/autoconf)|AC_CONFIG_AUX_DIR(build/autoconf)|' configure.in
%__autoconf
# Add fake RPATH
rpath="/$(printf %%s '%tbird_prefix' |tr '[:print:]' '_')"
export LDFLAGS="$LDFLAGS -Wl,-rpath,$rpath"
export LIBIDL_CONFIG=/usr/bin/libIDL-config-2
%configure \
--disable-mathml \
--disable-activex \
--disable-activex-scripting \
--disable-tests \
--disable-oji \
--disable-plugins \
--disable-necko-disk-cache \
--disable-installer \
--disable-updater \
--disable-profilesharing \
--disable-freetype2 \
--disable-elf-dynstr-gc \
--enable-xft \
--enable-reorder \
--enable-single-profile \
--enable-crypto \
--enable-extensions=default \
--enable-necko-protocols=http,file,jar,viewsource,res,data \
--enable-image-decoders=default,-xbm \
--enable-application=mail \
\
--includedir=%_includedir \
--enable-default-toolkit=gtk2 \
--enable-optimize="-O2" \
%if_with debug
--disable-strip \
--enable-debug \
--enable-debug-modules \
--enable-logrefcnt \
--enable-debugger-info-modules \
--enable-detect-webshell-leaks \
%else
--enable-strip \
--disable-debug \
%endif # debug
%if_with xprint
--enable-xprint \
--disable-postscript \
%else
--disable-xprint \
%endif # xprint
%if_with branding
--enable-branding \
--enable-official-branding \
%endif
\
%if_with nspr
--with-system-nspr \
%endif # nspr
\
%if_with nss
--with-system-nss \
%endif # nss
\
%if_with libxul
--enable-libxul \
%endif # libxul
\
%if_with mozldap
--enable-ldap \
--with-system-ldap \
%else
--disable-ldap \
%endif # mozldap
\
--with-system-jpeg \
--with-system-png \
--with-system-mng \
--with-system-zlib \
--with-pthreads \
#
%make_build
%install
%__mkdir_p \
%buildroot/%tbird_arch_extensionsdir \
%buildroot/%tbird_noarch_extensionsdir \
%buildroot/%tbird_componentsdir/myspell \
#
%makeinstall \
idldir=%buildroot/%tbird_idldir \
includedir=%buildroot/%tbird_includedir \
mozappdir=%buildroot/%tbird_prefix \
#
%SOURCE8 %_includedir %buildroot/%tbird_includedir %tbird_name
# RSS fix
%__cp -rfL dist/bin/isp/* %buildroot/%tbird_prefix/isp/
# copy default *.css
%__install -D -m 644 %SOURCE2 %buildroot/%tbird_defaultsdir/profile/chrome/userContent.css
# install menu file
%__install -m 755 -d %buildroot/%_datadir/applications
%__cp %SOURCE3 %buildroot/%_datadir/applications/%name.desktop
%__install -m 755 %SOURCE9 %buildroot/%tbird_initd/S00thunderbird-midration.sh
# icons
%__install -D -m 644 tbird-48.png %buildroot/%_liconsdir/%name.png
%__install -D -m 644 tbird-32.png %buildroot/%_niconsdir/%name.png
%__install -D -m 644 tbird-16.png %buildroot/%_miconsdir/%name.png
# url_handler script
cat>%buildroot/%tbird_prefix/%tbird_name-mailto<<EOF
#!/bin/sh -e
arg="\$*"
[ "\${arg%%%%:*}" = "mailto" ] || arg="mailto:\$arg"
%tbird_exec "\$arg"
EOF
chmod +x %buildroot/%tbird_prefix/%tbird_name-mailto
%__tar -xC "%buildroot/%tbird_prefix" -f %SOURCE7
%if_without nspr
# We must rename some file to remove comflicts between Mozilla, Firefox and Thunderbird pckages.
find %buildroot/%_datadir/aclocal -type f -execdir %__mv -f \{\} %tbird_name-\{\} \;
%endif
# make devel source packege to build extensions
%make clean
%__mkdir_p %buildroot/%tbird_usrsrc
%__subst 's,/.*/mozilla\(/\|\$\),/ZZZ\1,g' ./config/autoconf.mk
%__tar -jcf %buildroot/%_usrsrc/%name/sources.tar.bz2 \
./makemake.sh find_install.sh \
./build \
./config \
./mail \
./mailnews \
./mozilla-config.h
# Add real RPATH
rpath="/$(printf %%s '%tbird_prefix' |tr '[:print:]' '_')"
find "%buildroot/%tbird_prefix" -type f |
while read f; do
%__file "$f" | grep -qs ELF || continue
if chrpath -l "$f" | fgrep -qs "RPATH=$rpath"; then
chrpath -r "%tbird_prefix" "$f"
fi
done
%pre
if [ -L "%_libdir/%name" ]; then
d="$(readlink -ev "%_libdir/%name" 2>/dev/null)" &&
rm -rf -- "%_libdir/%name" "$d" ||:
fi
if [ -L "%_datadir/%name" ]; then
d="$(readlink -ev "%_datadir/%name" 2>/dev/null)" &&
rm -rf -- "%_datadir/%name" "$d" ||:
fi
%preun
if [ "$1" = "0" ]; then
[ ! -d "%tbird_arch_extensionsdir" ] || %__rm -rf "%tbird_arch_extensionsdir"
[ ! -d "%tbird_noarch_extensionsdir" ] || %__rm -rf "%tbird_noarch_extensionsdir"
[ ! -d "%tbird_updatesdir" ] || %__rm -rf "%tbird_updatesdir"
fi
%files
%tbird_exec
%tbird_libdir
%tbird_datadir
%defattr(0644,root,root,0755)
%_datadir/applications/%name.desktop
%_niconsdir/%name.png
%_miconsdir/%name.png
%_liconsdir/%name.png
%exclude %tbird_libdir/regxpcom
%exclude %tbird_libdir/xpcshell
%exclude %tbird_libdir/xpicleanup
%exclude %tbird_libdir/xpidl
%exclude %tbird_libdir/xpt_dump
%exclude %tbird_libdir/xpt_link
%files devel
%_bindir/%name-config
%tbird_libdir/regxpcom
%tbird_libdir/xpcshell
%tbird_libdir/xpicleanup
%tbird_libdir/xpidl
%tbird_libdir/xpt_dump
%tbird_libdir/xpt_link
%tbird_includedir
%tbird_idldir
%_libdir/pkgconfig/*
%tbird_usrsrc
%if_with nss
%exclude %_libdir/pkgconfig/%name-nss.pc
%endif
%if_with nspr
%exclude %_libdir/pkgconfig/%name-nspr.pc
%else
%_datadir/aclocal/*
%endif
%changelog
* Wed Apr 29 2009 Anton Farygin <rider@altlinux.ru> 2.0.0.21-alt0.M50.3
- really build new version
- update_menus removed
* Sun Mar 22 2009 Michael Shigorin <mike@altlinux.org> 2.0.0.21-alt0.M50.2
- rebuilt (libXext)
- fixed typo in a patch name
* Sat Mar 21 2009 Michael Shigorin <mike@altlinux.org> 2.0.0.21-alt0.M50.1
- New version (2.0.0.21) built for M50
- Fixed:
+ MFSA 2009-10 Upgrade PNG library to fix memory safety hazards
+ MFSA 2009-09 XML data theft via RDFXMLDataSource and cross-domain redirect
+ MFSA 2009-07 Crashes with evidence of memory corruption (rv:1.9.0.7)
+ MFSA 2009-01 Crashes with evidence of memory corruption (rv:1.9.0.6)
- Thunderbird 2.0.0.20 release got skipped
- Fixed in Thunderbird 2.0.0.19
+ MFSA 2008-68 XSS and JavaScript privilege escalation
+ MFSA 2008-67 Escaped null characters ignored by CSS parser
+ MFSA 2008-66 Errors parsing URLs with leading whitespace and control characters
+ MFSA 2008-65 Cross-domain data theft via script redirect error message
+ MFSA 2008-64 XMLHttpRequest 302 response disclosure
+ MFSA 2008-61 Information stealing via loadBindingDocument
+ MFSA 2008-60 Crashes with evidence of memory corruption (rv:1.9.0.5/1.8.1.19)
- updated BuildRequires (libXext-devel missing)
* Mon Nov 24 2008 Alexey Gladkov <legion@altlinux.ru> 2.0.0.18-alt1
- New version (2.0.0.18)
- Fixed:
+ MFSA 2008-59 Script access to .documentURI and .textContent in mail
+ MFSA 2008-58 Parsing error in E4X default namespace
+ MFSA 2008-56 nsXMLHttpRequest::NotifyEventListeners() same-origin violation
+ MFSA 2008-55 Crash and remote code execution in nsFrameManager
+ MFSA 2008-52 Crashes with evidence of memory corruption (rv:1.9.0.4/1.8.1.18)
+ MFSA 2008-50 Crash and remote code execution via __proto__ tampering
+ MFSA 2008-48 Image stealing via canvas and HTTP redirect
* Tue Nov 18 2008 Alexey Gladkov <legion@altlinux.ru> 2.0.0.17-alt1
- New version (2.0.0.17)
- Fixed:
+ MFSA 2008-46 Heap overflow when canceling newsgroup message
+ MFSA 2008-44 resource: traversal vulnerabilities
+ MFSA 2008-43 BOM characters stripped from JavaScript before execution
+ MFSA 2008-42 Crashes with evidence of memory corruption (rv:1.9.0.2/1.8.1.17)
+ MFSA 2008-41 Privilege escalation via XPCnativeWrapper pollution
+ MFSA 2008-38 nsXMLDocument::OnChannelRedirect() same-origin violation
+ MFSA 2008-37 UTF-8 URL stack buffer overflow
+ MFSA 2008-34 Remote code execution by overflowing CSS reference counter
+ MFSA 2008-33 Crash and remote code execution in block reflow
+ MFSA 2008-31 Peer-trusted certs can use alt names to spoof
+ MFSA 2008-29 Faulty .properties file results in uninitialized memory being used
+ MFSA 2008-26 Buffer length checks in MIME processing
+ MFSA 2008-25 Arbitrary code execution in mozIJSSubScriptLoader.loadSubScript()
+ MFSA 2008-24 Chrome script loading from fastload file
+ MFSA 2008-21 Crashes with evidence of memory corruption (rv:1.8.1.15)
* Thu Jul 17 2008 Alexey Gladkov <legion@altlinux.ru> 2.0.0.14-alt2
- Bugfix build.
- Dont use LD_LIBRARY_PATH in startup scripts.
* Sun May 11 2008 Alexey Gladkov <legion@altlinux.ru> 2.0.0.14-alt1
- New version (2.0.0.14)
- Fixed:
+ MFSA 2008-15 Crashes with evidence of memory corruption (rv:1.8.1.13)
+ MFSA 2008-14 JavaScript privilege escalation and arbitrary code execution
* Sun Mar 02 2008 Alexey Gladkov <legion@altlinux.ru> 2.0.0.12-alt1
- New version (2.0.0.12)
- Fixed:
+ MFSA 2008-12 Heap buffer overflow in external MIME bodies
+ MFSA 2008-05 Directory traversal via chrome: URI
+ MFSA 2008-03 Privilege escalation, XSS, Remote Code Execution
+ MFSA 2008-01 Crashes with evidence of memory corruption (rv:1.8.1.12)
+ MFSA 2007-36 URIs with invalid %-encoding mishandled by Windows
+ MFSA 2007-29 Crashes with evidence of memory corruption (rv:1.8.1.8)
+ MFSA 2007-27 Unescaped URIs passed to external programs
+ MFSA 2007-26 Privilege escalation through chrome-loaded about:blank windows
* Thu Aug 02 2007 Alexey Gladkov <legion@altlinux.ru> 2.0.0.6-alt1
- New version (2.0.0.6)
- Fixed:
+ MFSA 2007-27 Unescaped URIs passed to external programs
+ MFSA 2007-26 Privilege escalation through chrome-loaded about:blank windows
* Fri Jul 20 2007 Alexey Gladkov <legion@altlinux.ru> 2.0.0.5-alt1
- New version (2.0.0.5)
- Fixed:
+ MFSA 2007-23 Remote code execution by launching Firefox from Internet Explorer
+ MFSA 2007-18 Crashes with evidence of memory corruption
* Fri Jun 29 2007 Alexey Gladkov <legion@altlinux.ru> 2.0.0.4-alt1
- New version (2.0.0.4)
- Fix normal icons.
- Fixed:
+ MFSA 2007-15 Security Vulnerability in APOP Authentication
+ MFSA 2007-12 Crashes with evidence of memory corruption (rv:1.8.0.12/1.8.1.4)
* Sun Apr 22 2007 Alexey Gladkov <legion@altlinux.ru> 2.0.0.0-alt1
- New version (2.0.0.0)
- Many bugfixes (see http://weblogs.mozillazine.org/rumblingedge/archives/2007/03/tb_2.html).
- Add RSS files (again).
* Tue Feb 27 2007 Alexey Gladkov <legion@altlinux.ru> 2.0-alt1.b2
- New version (2.0 Beta 2)
* Thu Nov 23 2006 Alexey Gladkov <legion@altlinux.ru> 1.5.0.8-alt1
- New version (1.5.0.8)
- Remove version specific paths.
- Add %%pre script.
- Improvements to product stability.
- Fixed:
+ MFSA 2006-67 Running Script can be recompiled
+ MFSA 2006-66 RSA signature forgery (variant)
+ MFSA 2006-65 Crashes with evidence of memory corruption (rv:1.8.0.8)
+ MFSA 2006-64 Crashes with evidence of memory corruption (rv:1.8.0.7)
+ MFSA 2006-63 JavaScript execution in mail via XBL
+ MFSA 2006-60 RSA Signature Forgery
+ MFSA 2006-59 Concurrency-related vulnerability
+ MFSA 2006-58 Auto-Update compromise through DNS and SSL spoofing
+ MFSA 2006-57 JavaScript Regular Expression Heap Corruption
* Thu Aug 17 2006 Alexey Gladkov <legion@altlinux.ru> 1.5.0.5-alt1
- New version (1.5.0.5)
- Build with MozLDAP support.
- Improvements to product stability.
- Fixed:
+ MFSA 2006-55 Crashes with evidence of memory corruption (rv:1.8.0.5)
+ MFSA 2006-54 XSS with XPCNativeWrapper(window).Function(...)
+ MFSA 2006-53 UniversalBrowserRead privilege escalation
+ MFSA 2006-52 PAC privilege escalation using Function.prototype.call
+ MFSA 2006-51 Privilege escalation using named-functions and redefined "new Object()"
+ MFSA 2006-50 JavaScript engine vulnerabilities
+ MFSA 2006-49 Heap buffer overwrite on malformed VCard
+ MFSA 2006-48 JavaScript new Function race condition
+ MFSA 2006-47 Native DOM methods can be hijacked across domains
+ MFSA 2006-46 Memory corruption with simultaneous events
+ MFSA 2006-44 Code execution through deleted frame reference
* Tue May 02 2006 Alexey Gladkov <legion@altlinux.ru> 1.5.0.2-alt1
- New bugfix version.
- Improvements to product stability.
- Fixed:
+ MFSA 2006-28 Security check of js_ValueToFunctionObject() can be circumvented;
+ MFSA 2006-27 Table Rebuilding Code Execution Vulnerability;
+ MFSA 2006-26 Mail Multiple Information Disclosure;
+ MFSA 2006-25 Privilege escalation through Print Preview;
+ MFSA 2006-24 Privilege escalation using crypto.generateCRMFRequest;
+ MFSA 2006-22 CSS Letter-Spacing Heap Overflow Vulnerability;
+ MFSA 2006-21 JavaScript execution in mail when forwarding in-line;
+ MFSA 2006-20 Crashes with evidence of memory corruption (rv:1.8.0.2);
+ MFSA 2006-08 "AnyName" entrainment and access control hazard;
+ MFSA 2006-07 Read beyond buffer while parsing XML;
+ MFSA 2006-06 Integer overflows in E4X, SVG and Canvas;
+ MFSA 2006-05 Localstore.rdf XML injection through XULDocument.persist();
+ MFSA 2006-04 Memory corruption via QueryInterface on Location, Navigator objects;
+ MFSA 2006-02 Changing postion:relative to static corrupts memory;
+ MFSA 2006-01 JavaScript garbage-collection hazards.
* Fri Mar 24 2006 Alexey Gladkov <legion@altlinux.ru> 1.5-alt2
- bugfix build.
- share extension directory fix.
* Tue Feb 21 2006 Alexey Gladkov <legion@altlinux.ru> 1.5-alt1
- new version 1.5
- build with rpm-build-thunderbird (external build macros)
- Build with system NSS and NSPR.
- Buildrequires updated for xorg-7.0
- directory /usr/share/thunderbird-@version@/extensions was added to extensions search path .
* this location is controled by the option extensions.dir.extensions .
- Startup script rewritten. Now it is single script.
* command line shortcut added: altmail:MAILLIST
(example: "altmail:devel" -> mailto:devel@list.altlinux.org).
- LDAP support disabled.
- firsttime script removed
- NoX patch removed
* Wed Aug 24 2005 Alexey Gladkov <legion@altlinux.ru> 1.0.6-alt2
- packaging bugfix.
- rpm mascros bugfix.
- The script is added for switching language after installation/removal
of a localization package.
- Bug: #6204, #6254 fixed.
* Mon Aug 15 2005 Alexey Gladkov <legion@altlinux.ru> 1.0.6-alt1
- new version.
- firsttime script added.
* Wed May 11 2005 Alexey Gladkov <legion@altlinux.ru> 1.0.2-alt1
- new version;
- RSS missing files add;
* Tue Feb 01 2005 Alexey Gladkov <legion@altlinux.ru> 1.0-alt4
- update patch thunderbird-1.0-20050201-alt-nox.patch
* uninstall-global-theme command-line option was added;
* update-register command-line option was added;
- thunderbird-1.0-alt-rpm-scripts.tar.bz2 bugfix;
* Thu Jan 27 2005 Alexey Gladkov <legion@altlinux.ru> 1.0-alt3
- fix crush when comiling with gcc3.4 .
* Wed Jan 19 2005 Alexey Gladkov <legion@altlinux.ru> 1.0-alt2
- Rebuilt with libstdc++.so.6.
* Thu Jan 06 2005 Alexey Gladkov <legion@altlinux.ru> 1.0-alt1
- new version;
- new extension load scheme;
- uninstall-global-extension option fixed;
- add RPATH=%%_libdir/%%fullname to the all binares;
- rpm macros was updated;
- %%post_ldconfig and %postun_ldconfig was removed.
- icons updated (thx shrek@);
* Tue Jul 16 2004 Alexey Morozov <morozov@altlinux.org> 0.7.2-alt2
- new version (0.7.2)
- rpm macros file is splitted to base and devel parts
- Russian spec translation
- A patch to handle external URLs w/ url_handler
- Requirements cleanup
* Fri May 07 2004 Alexey Gladkov <legion@altlinux.ru> 0.6-alt1
- New version;
- Splash screen added;
- Default userContent.css added;
- Offline extension added by default;
- Confilct between mozilla-like devel packages was removed.
* Wed Feb 11 2004 Alexey Gladkov <legion@altlinux.ru> 0.5-alt1
- New version.
* Tue Jan 13 2004 Alexey Gladkov <legion@altlinux.ru> 0.4-alt4
- Spec changes.
* Fri Dec 26 2003 Alexey Gladkov <legion@altlinux.ru> 0.4-alt3
- first build for ALT Linux.
- rpm macro added.
- new scheme loading extensions added (thx force@)
- Spec modifications.