Gentoo Archives: gentoo-commits

From: "Raul Porcel (armin76)" <armin76@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in mail-client/mozilla-thunderbird: mozilla-thunderbird-2.0.0.22.ebuild ChangeLog
Date: Wed, 24 Jun 2009 15:45:09
Message-Id: E1MJUeo-0007qm-TC@stork.gentoo.org
1 armin76 09/06/24 15:45:06
2
3 Modified: ChangeLog
4 Added: mozilla-thunderbird-2.0.0.22.ebuild
5 Log:
6 Version bump
7 (Portage version: 2.1.6.13/cvs/Linux ia64)
8
9 Revision Changes Path
10 1.292 mail-client/mozilla-thunderbird/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-client/mozilla-thunderbird/ChangeLog?rev=1.292&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-client/mozilla-thunderbird/ChangeLog?rev=1.292&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-client/mozilla-thunderbird/ChangeLog?r1=1.291&r2=1.292
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/mail-client/mozilla-thunderbird/ChangeLog,v
19 retrieving revision 1.291
20 retrieving revision 1.292
21 diff -u -r1.291 -r1.292
22 --- ChangeLog 1 May 2009 23:59:26 -0000 1.291
23 +++ ChangeLog 24 Jun 2009 15:45:06 -0000 1.292
24 @@ -1,6 +1,12 @@
25 # ChangeLog for mail-client/mozilla-thunderbird
26 # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/mail-client/mozilla-thunderbird/ChangeLog,v 1.291 2009/05/01 23:59:26 nirbheek Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/mail-client/mozilla-thunderbird/ChangeLog,v 1.292 2009/06/24 15:45:06 armin76 Exp $
29 +
30 +*mozilla-thunderbird-2.0.0.22 (24 Jun 2009)
31 +
32 + 24 Jun 2009; Raúl Porcel <armin76@g.o>
33 + +mozilla-thunderbird-2.0.0.22.ebuild:
34 + Version bump
35
36 01 May 2009; Nirbheek Chauhan <nirbheek@g.o>
37 mozilla-thunderbird-2.0.0.21:
38
39
40
41 1.1 mail-client/mozilla-thunderbird/mozilla-thunderbird-2.0.0.22.ebuild
42
43 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-client/mozilla-thunderbird/mozilla-thunderbird-2.0.0.22.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/mail-client/mozilla-thunderbird/mozilla-thunderbird-2.0.0.22.ebuild?rev=1.1&content-type=text/plain
45
46 Index: mozilla-thunderbird-2.0.0.22.ebuild
47 ===================================================================
48 # Copyright 1999-2009 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/mail-client/mozilla-thunderbird/mozilla-thunderbird-2.0.0.22.ebuild,v 1.1 2009/06/24 15:45:06 armin76 Exp $
51
52 WANT_AUTOCONF="2.1"
53
54 inherit flag-o-matic toolchain-funcs eutils mozconfig-2 mozilla-launcher makeedit multilib mozextension autotools
55
56 PATCH="${PN}-2.0.0.22-patches-0.1"
57 LANGS="af be bg ca cs da de el en-GB en-US es-AR es-ES eu fi fr ga-IE he hu it ja ko lt mk nb-NO nl nn-NO pa-IN pl pt-BR pt-PT ru sk sl sv-SE tr uk zh-CN zh-TW"
58 NOSHORTLANGS="en-GB es-AR pt-BR zh-TW"
59
60 DESCRIPTION="Thunderbird Mail Client"
61 HOMEPAGE="http://www.mozilla.com/en-US/thunderbird/"
62
63 KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
64 SLOT="0"
65 LICENSE="|| ( MPL-1.1 GPL-2 LGPL-2.1 )"
66 IUSE="ldap crypt bindist mozdom replytolist"
67
68 MOZ_URI="http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/${PV}"
69 SRC_URI="${MOZ_URI}/source/thunderbird-${PV}-source.tar.bz2
70 mirror://gentoo/${PATCH}.tar.bz2"
71
72 # These are in
73 #
74 # http://releases.mozilla.org/pub/mozilla.org/thunderbird/releases/${MY_PV}/linux-i686/xpi/
75 #
76 # for i in $LANGS $SHORTLANGS; do wget $i.xpi -O ${P}-$i.xpi; done
77 for X in ${LANGS} ; do
78 if [ "${X}" != "en" ] && [ "${X}" != "en-US" ]; then
79 SRC_URI="${SRC_URI}
80 linguas_${X/-/_}? ( http://dev.gentooexperimental.org/~armin76/dist/${P}-xpi/${P}-${X}.xpi )"
81 fi
82 IUSE="${IUSE} linguas_${X/-/_}"
83 # english is handled internally
84 if [ "${#X}" == 5 ] && ! has ${X} ${NOSHORTLANGS}; then
85 if [ "${X}" != "en-US" ]; then
86 SRC_URI="${SRC_URI}
87 linguas_${X%%-*}? ( http://dev.gentooexperimental.org/~armin76/dist/${P}-xpi/${P}-${X}.xpi )"
88 fi
89 IUSE="${IUSE} linguas_${X%%-*}"
90 fi
91 done
92
93 RDEPEND=">=www-client/mozilla-launcher-1.56
94 >=dev-libs/nss-3.11.5
95 >=dev-libs/nspr-4.6.5-r1"
96
97 PDEPEND="crypt? ( >=x11-plugins/enigmail-0.95.7-r5 )
98 replytolist? ( x11-plugins/replytolist )"
99
100 S="${WORKDIR}/mozilla"
101
102 # Needed by src_compile() and src_install().
103 # Would do in pkg_setup but that loses the export attribute, they
104 # become pure shell variables.
105 export MOZ_CO_PROJECT=mail
106 export BUILD_OFFICIAL=1
107 export MOZILLA_OFFICIAL=1
108
109 linguas() {
110 local LANG SLANG
111 for LANG in ${LINGUAS}; do
112 if has ${LANG} en en_US; then
113 has en ${linguas} || linguas="${linguas:+"${linguas} "}en"
114 continue
115 elif has ${LANG} ${LANGS//-/_}; then
116 has ${LANG//_/-} ${linguas} || linguas="${linguas:+"${linguas} "}${LANG//_/-}"
117 continue
118 elif [[ " ${LANGS} " == *" ${LANG}-"* ]]; then
119 for X in ${LANGS}; do
120 if [[ "${X}" == "${LANG}-"* ]] && \
121 [[ " ${NOSHORTLANGS} " != *" ${X} "* ]]; then
122 has ${X} ${linguas} || linguas="${linguas:+"${linguas} "}${X}"
123 continue 2
124 fi
125 done
126 fi
127 ewarn "Sorry, but ${PN} does not support the ${LANG} LINGUA"
128 done
129 }
130
131 pkg_setup(){
132 if ! built_with_use x11-libs/cairo X; then
133 eerror "Cairo is not built with X useflag."
134 eerror "Please add 'X' to your USE flags, and re-emerge cairo."
135 die "Cairo needs X"
136 fi
137
138 if ! built_with_use --missing true x11-libs/pango X; then
139 eerror "Pango is not built with X useflag."
140 eerror "Please add 'X' to your USE flags, and re-emerge pango."
141 die "Pango needs X"
142 fi
143
144 if ! use bindist; then
145 elog "You are enabling official branding. You may not redistribute this build"
146 elog "to any users on your network or the internet. Doing so puts yourself into"
147 elog "a legal problem with Mozilla Foundation"
148 elog "You can disable it by emerging ${PN} _with_ the bindist USE-flag"
149 fi
150
151 use moznopango && warn_mozilla_launcher_stub
152 }
153
154 src_unpack() {
155 unpack thunderbird-${PV}-source.tar.bz2 ${PATCH}.tar.bz2
156
157 linguas
158 for X in ${linguas}; do
159 [[ ${X} != "en" ]] && xpi_unpack "${P}-${X}.xpi"
160 done
161 if [[ ${linguas} != "" && ${linguas} != "en" ]]; then
162 elog "Selected language packs (first will be default): ${linguas}"
163 fi
164
165 # Apply our patches
166 cd "${S}" || die "cd failed"
167 EPATCH_SUFFIX="patch" \
168 EPATCH_FORCE="yes" \
169 epatch "${WORKDIR}"/patch
170
171 eautoreconf
172 }
173
174 src_compile() {
175 declare MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
176
177 ####################################
178 #
179 # mozconfig, CFLAGS and CXXFLAGS setup
180 #
181 ####################################
182
183 mozconfig_init
184 mozconfig_config
185
186 # tb-specific settings
187 mozconfig_use_enable ldap
188 mozconfig_use_enable ldap ldap-experimental
189 mozconfig_annotate '' --with-default-mozilla-five-home=${MOZILLA_FIVE_HOME}
190 mozconfig_annotate '' --with-user-appdir=.thunderbird
191 mozconfig_annotate '' --with-system-nspr
192 mozconfig_annotate '' --with-system-nss
193
194 # Bug 223375, 217805
195 # Breaks builds with gcc-4.3
196 if [[ $(gcc-version) == "4.3" ]]; then
197 mozconfig_annotate 'gcc-4.3 breaks builds' --disable-optimize
198 fi
199
200 # Bug #72667
201 if use mozdom; then
202 mozconfig_annotate '' --enable-extensions=default,inspector
203 else
204 mozconfig_annotate '' --enable-extensions=default
205 fi
206
207 if ! use bindist; then
208 mozconfig_annotate '' --enable-official-branding
209 fi
210
211 # Finalize and report settings
212 mozconfig_final
213
214 if [[ $(gcc-major-version) -lt 4 ]]; then
215 append-cxxflags -fno-stack-protector
216 fi
217
218 ####################################
219 #
220 # Configure and build
221 #
222 ####################################
223
224 CPPFLAGS="${CPPFLAGS}" \
225 CC="$(tc-getCC)" CXX="$(tc-getCXX)" LD="$(tc-getLD)" \
226 econf || die
227
228 # This removes extraneous CFLAGS from the Makefiles to reduce RAM
229 # requirements while compiling
230 edit_makefiles
231
232 emake || die
233 }
234
235 src_install() {
236 declare MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
237
238 # Most of the installation happens here
239 dodir "${MOZILLA_FIVE_HOME}"
240 cp -RL "${S}"/dist/bin/* "${D}"/"${MOZILLA_FIVE_HOME}"/ || die "cp failed"
241
242 linguas
243 for X in ${linguas}; do
244 [[ ${X} != "en" ]] && xpi_install "${WORKDIR}"/"${P}-${X}"
245 done
246
247 local LANG=${linguas%% *}
248 if [[ ${LANG} != "" && ${LANG} != "en" ]]; then
249 ebegin "Setting default locale to ${LANG}"
250 sed -i "s:pref(\"general.useragent.locale\", \"en-US\"):pref(\"general.useragent.locale\", \"${LANG}\"):" \
251 "${D}"${MOZILLA_FIVE_HOME}/defaults/pref/all-thunderbird.js \
252 "${D}"${MOZILLA_FIVE_HOME}/defaults/pref/all-l10n.js
253 eend $? || die "sed failed to change locale"
254 fi
255
256 # Create directory structure to support portage-installed extensions.
257 # See update_chrome() in mozilla-launcher
258 keepdir ${MOZILLA_FIVE_HOME}/chrome.d
259 keepdir ${MOZILLA_FIVE_HOME}/extensions.d
260 cp "${D}"${MOZILLA_FIVE_HOME}/chrome/installed-chrome.txt \
261 "${D}"${MOZILLA_FIVE_HOME}/chrome.d/0_base-chrome.txt
262
263 # Create /usr/bin/thunderbird
264 install_mozilla_launcher_stub thunderbird ${MOZILLA_FIVE_HOME}
265
266 if ! use bindist; then
267 doicon "${FILESDIR}"/icon/thunderbird-icon.png
268 domenu "${FILESDIR}"/icon/${PN}.desktop
269 else
270 doicon "${FILESDIR}"/icon/thunderbird-icon-unbranded.png
271 newmenu "${FILESDIR}"/icon/${PN}-unbranded.desktop \
272 ${PN}.desktop
273 fi
274
275 # Install files necessary for applications to build against thunderbird
276 elog "Installing includes and idl files..."
277 cp -LfR "${S}"/dist/include "${D}"/"${MOZILLA_FIVE_HOME}" || die "cp failed"
278 cp -LfR "${S}"/dist/idl "${D}"/"${MOZILLA_FIVE_HOME}" || die "cp failed"
279
280 # Dirty hack to get some applications using this header running
281 dosym "${MOZILLA_FIVE_HOME}"/include/necko/nsIURI.h \
282 "${MOZILLA_FIVE_HOME}"/include/nsIURI.h
283
284 # Warn user that remerging enigmail is neccessary on USE=crypt
285 use crypt && ewarn "Please remerge x11-plugins/enigmail after updating ${PN}."
286 }
287
288 pkg_postinst() {
289 declare MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
290
291 # This should be called in the postinst and postrm of all the
292 # mozilla, mozilla-bin, firefox, firefox-bin, thunderbird and
293 # thunderbird-bin ebuilds.
294 update_mozilla_launcher_symlinks
295 }
296
297 pkg_postrm() {
298 declare MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
299
300 update_mozilla_launcher_symlinks
301 }