thunderbird.spec revision 10550
8109N/A#
8109N/A# Copyright (c) Sun Microsystems, Inc.
8109N/A#
8109N/A# Owner: davelam
8109N/A#
8109N/A
8109N/A#####################################
8109N/A## Package Information Section ##
8109N/A#####################################
8109N/A
8109N/AName: thunderbird
8109N/ASummary: Mozilla Thunderbird Standalone E-mail and Newsgroup Client
8109N/AVersion: 2.0
8109N/A%define tarball_version 2.0.0.0
8109N/ARelease: 1
8109N/ACopyright: MPL/LGPL
8109N/AGroup: Applications/Internet
8109N/ADistribution:Java Desktop System
8109N/AVendor: Sun Microsystems, Inc.
8109N/ASource: http://ftp.mozilla.org/pub/mozilla.org/%{name}/releases/%{tarball_version}/source/%{name}-%{tarball_version}-source.tar.bz2
8109N/ASource1: thunderbird-icon.png
8109N/ASource2: thunderbird.desktop
8109N/A%define with_lightning %{?!_without_lightning:1}%{?_without_lightning:0}
8109N/A%if %with_lightning
8109N/A%define lightning_version 0.3.1
8109N/ASource3: http://releases.mozilla.org/pub/mozilla.org/calendar/lightning/releases/0.3.1/source/lightning-%{lightning_version}.source.tar.bz2
8109N/A%endif
8109N/ASource4: thunderbird.cfg
8109N/A
8109N/A
8109N/A# owner:davelam date:2005-08-22 type:branding
8109N/A# change install dir from 'name-version' to 'name'
8109N/APatch1: mozilla-01-change-install-dir.diff
8109N/A
8109N/A# owner:davelam date:2006-04-14 type:branding
8109N/A# change startup script to support multi-language
8109N/APatch2: thunderbird-08-locale.diff
8109N/A
8109N/A# owner:davelam date:2005-09-01 type:branding
8109N/A# let moz patch checker support S10 and S11
8109N/APatch3: mozilla-02-no-patch-checker.diff
8109N/A
8109N/A# owner:davelam date:2005-09-05 type:branding
8109N/A# remove gtar specific options
8109N/APatch4: mozilla-05-common-tar-option.diff
8109N/A
8109N/A# owner:davelam date:2006-04-29 type:branding
8109N/A# let firefox use system bundled nss,nspr
8109N/APatch5: thunderbird-09-no-nss-nspr.diff
8109N/A
8109N/A# owner:davelam date:2006-07-07 type:branding
8109N/A# comment LD_LIBRARY_PATH setting
8109N/APatch6: mozilla-07-no-ldlibpath.diff
8109N/A
8109N/A# owner:davelam date:2006-09-07 type:branding
8109N/A# remove moz patch checker from package
8109N/APatch7: thunderbird-10-no-pkg-files.diff
8109N/A
8109N/A# owner:hawklu date:2007-03-21 type:bug
8109N/APatch8: thunderbird-13-ldap-crash.diff
8109N/A
8109N/A# owner:hawklu date:2007-04-27 type:branding
8109N/A# bugster:6542910
8109N/APatch9: thunderbird-14-disable-online-update.diff
8109N/A
8110N/AURL: http://www.sun.com/software/javadesktopsystem/
8110N/A
8109N/ABuildRoot: %{_tmppath}/%{name}-%{tarball_version}-build
8109N/APrefix: /usr
8109N/AProvides: webclient
8109N/AAutoreqprov: on
8109N/A
8109N/A#####################################
8109N/A## Package Defines Section ##
8109N/A#####################################
8109N/A
8109N/A%define _unpackaged_files_terminate_build 0
8109N/A%define _tbdir %{_libdir}/%{name}
8109N/A
8109N/A#####################################
8109N/A## Package Requirements Section ##
8109N/A#####################################
8109N/A
8109N/ABuildRequires: libpng-devel
8109N/ABuildRequires: libjpeg
8109N/ABuildRequires: zlib-devel
8109N/ABuildRequires: zip
8109N/ABuildRequires: perl
8109N/ABuildRequires: autoconf
8109N/ABuildRequires: libIDL-devel
8109N/ABuildRequires: glib2-devel
8109N/ABuildRequires: gtk2-devel
8109N/APrereq: fileutils perl
8109N/APrereq: /usr/bin/killall
8109N/A
8109N/A#####################################
8109N/A## Package Description Section ##
8109N/A#####################################
8109N/A
8109N/A%description
8109N/AMozilla Thunderbird is a standalone e-mail and newsgroup client
8109N/Athat can be used as a companion to Mozilla Firefox or by itself.
8109N/A
8109N/A#####################################
8110N/A## Package Preparation Section ##
8110N/A#####################################
8109N/A
8109N/A%prep
8109N/A
8109N/A%setup -q -c -n %{name}
8109N/Acd ..
8109N/A/bin/mv %{name} %{name}.tmp.$$
8109N/A/bin/mv %{name}.tmp.$$/mozilla %{name}
8109N/Arm -rf %{name}.tmp.$$
8109N/A%if %with_lightning
8109N/A/usr/sfw/bin/gtar -jxf %{SOURCE3} \
8109N/A mozilla/calendar \
8109N/A mozilla/extensions/lightning
8109N/Achmod -Rf a+rX,g-w,o-w mozilla
8109N/Arm -rf %{name}/calendar
8109N/Arm -rf %{name}/extensions/lightning
8109N/Amv mozilla/calendar %{name}/
8109N/Amv mozilla/extensions/lightning %{name}/extensions/
8109N/Arm -rf mozilla
8110N/A%endif
8109N/A
8110N/Acd %{name}
8110N/A%patch1 -p1
8110N/A%patch2 -p1
8110N/A%ifos solaris
8110N/A%patch3 -p1
8110N/A%patch4 -p1
8110N/A%patch5 -p1
8110N/A%patch6 -p1
8110N/A%patch7 -p1
8110N/A%endif
8110N/A%patch8 -p1
8110N/A%patch9 -p1
8110N/A
8110N/A#####################################
8110N/A## Package Build Section ##
8110N/A#####################################
8110N/A
8110N/A%build
8110N/A
8110N/A%ifos linux
8110N/Aif [ -x /usr/bin/getconf ]; then
8110N/A CPUS=`getconf _NPROCESSORS_ONLN`
8110N/Afi
8110N/A%else
8110N/A CPUS=`/usr/sbin/psrinfo | grep on-line | wc -l | tr -d ' '`
8110N/A%endif
8110N/Aif test "x$CPUS" = "x" -o $CPUS = 0; then
8110N/A CPUS=1
8110N/Afi
8110N/A
8110N/Acat << "EOF" > .mozconfig
8110N/A. $topsrcdir/mail/config/mozconfig
8110N/Amk_add_options BUILD_OFFICIAL=1
8110N/Amk_add_options MOZILLA_OFFICIAL=1
8110N/Aac_add_options --prefix=%{_prefix}
8110N/Aac_add_options --libdir=%{_libdir}
8110N/Aac_add_options --mandir=%{_mandir}
8110N/Aac_add_options --enable-xft
8110N/Aac_add_options --enable-default-toolkit=gtk2
8110N/Aac_add_options --disable-static
8110N/Aac_add_options --enable-shared
8110N/Aac_add_options --enable-official-branding
8110N/Aac_add_options --disable-updater
8110N/Aac_add_options --disable-tests
8110N/Aac_add_options --disable-freetype2
8110N/Aac_add_options --disable-auto-deps
8110N/Aac_add_options --disable-debug
8110N/AEOF
8109N/A
8109N/A%if %with_lightning
8109N/Aecho "ac_add_options --enable-extensions=default,lightning" >> .mozconfig
8109N/A%endif
8109N/A
8109N/ABUILD_OFFICIAL=1
8109N/AMOZILLA_OFFICIAL=1
8109N/AMOZ_PKG_FORMAT=BZ2
8109N/APKG_SKIP_STRIP=1
8109N/A#CFLAGS=
8109N/A#CXXFLAGS=
8109N/Aexport BUILD_OFFICIAL MOZILLA_OFFICIAL MOZ_PKG_FORMAT PKG_SKIP_STRIP CFLAGS CXXFLAGS
8109N/A
8109N/A./configure
8109N/Amake export
8109N/A# FIXME: disabled parallel build as it seems to break the build sometimes
8109N/Amake libs
8109N/A
8109N/Acd xpinstall/packager
8109N/Amake
8109N/A
8109N/A%install
8109N/A/bin/rm -rf $RPM_BUILD_ROOT
8109N/A
8109N/ABUILDDIR=`pwd`
8109N/A/bin/mkdir -p $RPM_BUILD_ROOT%{_libdir}
8109N/Acd $RPM_BUILD_ROOT%{_libdir}
8109N/A/usr/bin/bzip2 -dc $BUILDDIR/dist/thunderbird-*.tar.bz2 | /bin/tar -xf -
8109N/A
8109N/A/bin/mkdir -p $RPM_BUILD_ROOT%{_bindir}
8109N/A/bin/ln -s ../lib/thunderbird/thunderbird $RPM_BUILD_ROOT%{_bindir}/thunderbird
8109N/A
8109N/A/bin/mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications
8109N/A/bin/mkdir -p $RPM_BUILD_ROOT%{_datadir}/pixmaps
8109N/Ainstall -c -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{_datadir}/pixmaps/thunderbird-icon.png
8109N/Ainstall -c -m 644 %{SOURCE2} $RPM_BUILD_ROOT%{_datadir}/applications/thunderbird.desktop
8109N/A
8109N/A# install the man page
8109N/A#/bin/mkdir -p $RPM_BUILD_ROOT%{_mandir}/man1
8109N/A#install -c -m 644 %{SOURCE4} $RPM_BUILD_ROOT%{_mandir}/man1/thunderbird.1
8109N/A
8109N/A#/bin/cat %{SOURCE3} | /usr/bin/sed -e 's,FFDIR,%{_tbdir},g' > \
8110N/A# $RPM_BUILD_ROOT%{_tbdir}/thunderbird-rebuild-databases
8110N/A#/bin/chmod 755 $RPM_BUILD_ROOT%{_tbdir}/thunderbird-rebuild-databases
8110N/A
8110N/A# remove the empty directories
8110N/A# cpu/sparcv8plus/libnspr_flt4.so is not packaged
8110N/A# since we use system bundled version of nss/nspr
8110N/A%ifarch sparc
8111N/Armdir $RPM_BUILD_ROOT%{_tbdir}/cpu/sparcv8plus
8110N/Armdir $RPM_BUILD_ROOT%{_tbdir}/cpu
8110N/A%endif
8110N/A
8110N/A# create symbol link libnssckbi.so -> /usr/lib/mps/libnssckbi.so
8109N/A# to fix bug CR#6459752
8109N/Aln -s ../mps/libnssckbi.so $RPM_BUILD_ROOT%{_tbdir}/libnssckbi.so
8109N/A
8109N/A# install thunderbird.cfg
8109N/Ainstall -c -m 644 %{SOURCE4} $RPM_BUILD_ROOT%{_tbdir}/thunderbird.cfg
8109N/A
8109N/A# remove local dictionary and share the one that delivered
8109N/A# by myspell-dictionary
8109N/Arm -f $RPM_BUILD_ROOT%{_tbdir}/dictionaries/en-US.dic
8109N/Arm -f $RPM_BUILD_ROOT%{_tbdir}/dictionaries/en-US.aff
8109N/Armdir $RPM_BUILD_ROOT%{_tbdir}/dictionaries
8109N/A
8109N/A%clean
8109N/A/bin/rm -rf $RPM_BUILD_ROOT
8109N/A
8109N/A#########################################
8109N/A## Package Post[Un] Install Section ##
8110N/A#########################################
8110N/A
8110N/A%post
8109N/A# run ldconfig before regxpcom
8109N/A/sbin/ldconfig >/dev/null 2>/dev/null
8109N/A
8109N/A%postun
8109N/A/sbin/ldconfig >/dev/null 2>/dev/null
8109N/A
8109N/A%preun
8110N/A
8110N/A#####################################
8110N/A## Package Files Section ##
8110N/A#####################################
8110N/A
8110N/A%files
8110N/A%defattr(-,root,root)
8110N/A%dir %{_tbdir}
8110N/A%{_tbdir}/*
8110N/A%{_bindir}/thunderbird
8110N/A#%{_mandir}/man1/*
8110N/A%{_datadir}/applications/%{name}.desktop
8110N/A%{_datadir}/pixmaps/%{name}-icon.png
8110N/A
8110N/A%changelog
8110N/A* Mon Apr 30 2007 - dave.lin@sun.com
8110N/A- remove local dictionary and use the one delivered by myspell-dictionary(CR6218511)
8110N/A* Thu Apr 27 2007 - brian.lu@sun.com
8110N/A- add patch to grey out "Check for Updates" in Thunderbird menu since it's not supported
8110N/A* Sat Apr 21 2007 - dave.lin@sun.com
8110N/A- Bump to 2.0.0.0
8110N/A* Thu Apr 12 2007 - dave.lin@sun.com
8110N/A- bump to 2.0.0.0rc1, removed the patches thunderbird-11-drag-and-drop.diff,
8110N/A thunderbird-12-defaultAccount.diff which are upstreamed in this release
8110N/A* Thu Apr 12 2007 - dave.lin@sun.com
8110N/A- disable update feature in Thunderbird menu since it's not supported
8109N/A on Solaris so far(CR#6542910)
8109N/A* Wed Mar 23 2007 - brian.lu@sun.com
8109N/A- Fix the bug CR6535724:Thunderbird crashes with LDAP in snv 60
8109N/A* Mon Mar 12 2007 - brian.lu@sun.com
8109N/A- Fix the bug CR6530327
8109N/A* Sat Mar 10 2007 - dougs@truemail.co.th
8109N/A- Fixed URL for lightning
8109N/A* Sat Mar 03 2007 - dave.lin@sun.com
8110N/A- bump lightning version to 0.3.1
8110N/A* Thu Feb 01 2007 - brian.lu@sun.com
8110N/A- fix drag and drop crashing bug CR6519257
8110N/A- bugzilla id 367203. The patch has been put into upstream
8110N/A* Sun Jan 28 2007 - laca@sun.com
8110N/A- add full download url for lightning
8109N/A* Fri Jan 26 2007 - dave.lin@sun.com
8110N/A- enable lightning extension(0.3) in Thunderbird
8110N/A* Wed Jan 24 2007 - dave.lin@sun.com
8110N/A- bump version to 2.0b2
8109N/A* Thu Dec 28 2006 - dave.lin@sun.com
8109N/A- change the patch type to branding for some patches in patch comments
8110N/A- bump version to 2.0b1 and remove mozilla-03-s11s-smkfl.diff,
8109N/A mozilla-04-s11x-smkfl.diff since they're upstreamed in that branch
8110N/A* Fri Nov 17 2006 - dave.lin@sun.com
8109N/A- add patch comments
8109N/A* Mon Nov 13 2006 - dave.lin@sun.com
8110N/A- change the version to 1.5.0.8 since 2.0a1 could not be able to integrated
8109N/A into SNV, and add patches mozilla-03-s11s-smkfl.diff, mozilla-04-s11x-smkfl.diff
8109N/A back because they're not upstreamed in the branch that for Thunderbird 1.5.x
8109N/A* Thu Sep 07 2006 - dave.lin@sun.com
8109N/A- add patch thunderbird-10-no-pkg-files.diff to remove patch checker scripts
8109N/A since it's unnecessary to deliver them with the bundled version
8109N/A- change the version 2.0a1 to 2.0 to comply WOS integration rules
8109N/A- re-organize the patch list
8109N/A* Mon Aug 28 2006 - dave.lin@sun.com
8109N/A- create symbol link libnssckbi.so -> /usr/lib/mps/libnssckbi.so
8109N/A to fix bug CR#6459752
8109N/A* Tue Aug 08 2006 - dave.lin@sun.com
8109N/A- bump version to 2.0a1
8109N/A- remove the patch mozilla-03-s11s-smkfl.diff, mozilla-04-s11x-smkfl.diff
8109N/A which have been fixed in 2.0a1
8109N/A- change to xpinstall/packager to run the make to generate the binary tarball
8109N/A* Mon Jul 31 2006 - dave.lin@sun.com
8110N/A- bump to 1.5.0.5
8109N/A* Fri Jul 07 2006 - dave.lin@sun.com
8109N/A- add patch mozilla-07-no-ldlibpath.diff to remove the LD_LIBRARY_PATH in
8109N/A- change to "disable-static, enable-shared" per Brian Lu
8109N/A* Wed Jun 21 2006 - dave.lin@sun.com
8109N/A- remove patch thunderbird-07-ldap-prefs.diff to fix bug CR#6344861
8109N/A* Fri Jun 02 2006 - dave.lin@sun.com
8109N/A- bump src version to 1.5.0.4
8109N/A* Sat Apr 29 2006 - halton.huo@sun.com
8109N/A- Add patch thunderbird-09-no-nss-nspr.diff to not deliver the nss,nspr
8109N/A* Fri Apr 27 2006 - damien.carbery@sun.com
8109N/A- Remove patch 9 as it is not in svn and breaks build.
8109N/A* Fri Apr 27 2006 - dave.lin@sun.com
8109N/A- change to not deliver the devel pkg
8109N/A- add patch thunderbird-09-no-nss-nspr.diff to not deliver the nss,nspr
8109N/A libraries, and use firefox's instead
8109N/A- remove patch mozilla-06-skip-strip.diff, use another simple way to skip
8109N/A strip instead, setting PKG_SKIP_STRIP=1
8109N/A* Fri Apr 21 2006 - dave.lin@sun.com
8110N/A- bump to 1.5.0.2, remove patch 06 thunderbird-06-save-all-attach.diff,
8110N/A which is already upstreamed
8110N/A* Fri Apr 14 2006 - dave.lin@sun.com
8109N/A- add patch mozilla-06-skip-strip.diff to make no stripped libraries
8109N/A- add patch firefox-13-locale.diff to make firefox automatically
8109N/A pick up locale setting from user environment and start up in
8110N/A that locale
8109N/A* Thu Apr 13 2006 - dave.lin@sun.com
8109N/A- Changed the installation location from "/usr/sfw/lib" to "/usr/lib"
8110N/A on Solaris
8109N/A
8109N/A* Fri Mar 10 2006 -halton.huo@sun.com
8109N/A- Add patch thunderbird-06-save-all-attach.diff to fix 6373061.
8109N/A- Add patch thunderbird-07-ldap-prefs.diff to fix CR6344861.
8109N/A
8109N/A* Tue Jan 17 2006 - dave.lin@sun.com
8109N/A- Bump tarball version to 1.5
8109N/A- add two configure options --enable-static, --disable-shared
8109N/A- to get rid of intermedia shared libraries
8109N/A- disable parallel build option
8109N/A
8109N/A* Tue Nov 08 2005 - dave.lin@sun.com
8109N/A- Bump tarball version to 1.5rc1
8109N/A- Remove the patch mozilla-07-bz307041.diff since it's upstreamed in 1.5rc1 already
8110N/A
8109N/A* Thu Nov 1 2005 - laca@sun.com
8109N/A- change version to numeric and introduce %tarball_version
8109N/A
8109N/A* Fri Oct 21 2005 - <halton.huo@sun.com>
8109N/A- Bump to 1.5b2.
8109N/A- Add patch 307041 from bugzilla.
8109N/A
8109N/A* Mon Sep 26 2005 - <halton.huo@sun.com>
8109N/A- Bump to 1.5b1.
8109N/A- Move dir mozilla to thunderbird after tarball unpacking.
8109N/A
8109N/A* Thu Sep 08 2005 - damien.carbery@sun.com
8109N/A- Change BuildPrereq to BuildRequires, a format that build-gnome2 understands.
8109N/A
8109N/A* Mon Sep 05 2005 - Dave Lin <dave.lin@sun.com>
8109N/A- Add patches to remove the specific gtar options
8109N/A- Set MOZ_PKG_FORMAT=BZ2 to keep consistent of tarball
8109N/A format between linux and solaris
8109N/A
8109N/A* Fri Sep 02 2005 - damien.carbery@sun.com
8109N/A- Change gtar to tar and rework tar command.
8109N/A
8109N/A* Mon Aug 22 2005 - Dave Lin <dave.lin@sun.com>
8109N/A- initial version of the spec file created
8109N/A
8110N/A