Gentoo Archives: gentoo-commits

From: Lars Wendler <polynomial-c@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: www-client/seamonkey/
Date: Wed, 29 Apr 2020 11:00:56
Message-Id: 1588158048.b421f9f9c4d4a2027be7f0f1a6ccc4b4f64720ab.polynomial-c@gentoo
1 commit: b421f9f9c4d4a2027be7f0f1a6ccc4b4f64720ab
2 Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
3 AuthorDate: Wed Apr 29 10:57:06 2020 +0000
4 Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
5 CommitDate: Wed Apr 29 11:00:48 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b421f9f9
7
8 www-client/seamonkey: Bump to version 2.53.2_beta1
9
10 Package-Manager: Portage-2.3.99, Repoman-2.3.22
11 Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
12
13 www-client/seamonkey/Manifest | 3 +
14 www-client/seamonkey/seamonkey-2.53.2_beta1.ebuild | 527 +++++++++++++++++++++
15 2 files changed, 530 insertions(+)
16
17 diff --git a/www-client/seamonkey/Manifest b/www-client/seamonkey/Manifest
18 index c5f8cb56e1a..d605f9c39c8 100644
19 --- a/www-client/seamonkey/Manifest
20 +++ b/www-client/seamonkey/Manifest
21 @@ -4,3 +4,6 @@ DIST seamonkey-2.49.5.source.tar.xz 231748204 BLAKE2B eeae383fabb596fdc25ab3a68f
22 DIST seamonkey-2.53.1-patches-02.tar.xz 73596 BLAKE2B 79136ce3ffb93bd76ada89458df7a1ef360dc59f68716a987a63ed8074963a2673d766d63e99947120fc000e3809377a7bf852feb3f6ea385f52ee1c9a44772a SHA512 80a23c65f4dbef05e3cc16bc4ffe4dd3e8f5312641dc02b5f92de70e322771a702aa9ae486e5e5e5b5a659aec46b5b931dc8c6f575612cbd5e6aaa0c0ee43fe7
23 DIST seamonkey-2.53.1.source-l10n.tar.xz 11423472 BLAKE2B ce577c8fd5ff10fdfe5a9f8725cacf2801ed2d4fc66f9535ec1a57e2a613d87925bbccd1293aef8d86c329a221d6f0a5f694b16c8762e2aceed1b4c60cf5883c SHA512 52bc7d82e935abb67778a6fcdab6a9e6d66a196d0962c59ddddae4ae854e1cd0e923016b13afa55df7a3f3997014fc38e729605d449a170a7ff96b905c7ea084
24 DIST seamonkey-2.53.1.source.tar.xz 290149116 BLAKE2B 613625df9f364550b1456a8f4afad012469e0740d3e084cf2d4e94b22389d2a8de5fa5012bcb8c6139e092054cfd2214d3d93e562a522f76009b6e5e3b5f406d SHA512 67c8a5343070948a88f1184a4f0c6ec720f9d43910165812b05a2a1bed8b698de2860d75b4bbf831f23c750fb521f50afa44ddc13835047f517a1407892ede3f
25 +DIST seamonkey-2.53.2_beta1-patches-01.tar.xz 21672 BLAKE2B cc69f2f48f11698bb24d0e45e292fb1ee67a3b940c96dc43956981adede1f604a443c2e3ca107530601f6f43610c9aedf7dc0e1aa7d8532e70e0bbaf5df6ed03 SHA512 a96b5cf1fde3a7b2f76139eb163715313178ca697532a6cbcd8bc3182f3df92926e50122938035ff0dfb98ecf2cea5b818590fcf363df4ba431d9aa1154640b0
26 +DIST seamonkey-2.53.2_beta1.source-l10n.tar.xz 12116808 BLAKE2B 5650958faaff6fea3a5e395b9fb60f96e529cac5538078e6d4619c300a5653cd4fdb07da2b9228396e75cc27c48956f3c80ed757a5dbb97e49367e1ee24a4916 SHA512 3611f12cae03949b57dc9f7c3e68f6c4f3aa44986507ab38f4d579894eb74ce1209b6ebcc98b53f9b0514b7b57b9cc50e618eb64a2ba2c4d403dfc41460b7a77
27 +DIST seamonkey-2.53.2_beta1.source.tar.xz 291691364 BLAKE2B 9c0be06bbf29009b786a017ea7dbc1ba461ed0277cc18098000a4ec68e5f01c30ea998c44ed0cccb3e27077c0c57f0a8da938937321fc6e530f78d824c815d4e SHA512 9d1aa3323d365e4f5d42da49211a2151e52f00e3b57d061ce02d0b1263497fe4e8f8f944c20d303fb0c4a84b0fd32a10811d5e431923466ef7f91b28313ca715
28
29 diff --git a/www-client/seamonkey/seamonkey-2.53.2_beta1.ebuild b/www-client/seamonkey/seamonkey-2.53.2_beta1.ebuild
30 new file mode 100644
31 index 00000000000..7fa69444d52
32 --- /dev/null
33 +++ b/www-client/seamonkey/seamonkey-2.53.2_beta1.ebuild
34 @@ -0,0 +1,527 @@
35 +# Copyright 1999-2020 Gentoo Authors
36 +# Distributed under the terms of the GNU General Public License v2
37 +
38 +EAPI=6
39 +WANT_AUTOCONF="2.1"
40 +
41 +PYTHON_COMPAT=( python3_{6,7,8} )
42 +PYTHON_REQ_USE='ncurses,sqlite,ssl,threads(+)'
43 +
44 +# This list can be updated with scripts/get_langs.sh from the mozilla overlay
45 +# note - could not roll langpacks for: ca fi
46 +#MOZ_LANGS=(ca cs de en-GB es-AR es-ES fi fr gl hu it ja lt nb-NO nl pl pt-PT
47 +# ru sk sv-SE tr uk zh-CN zh-TW)
48 +MOZ_LANGS=(cs de en-GB es-AR es-ES fr hu it ja lt nl pl pt-PT
49 + ru sk sv-SE zh-CN zh-TW)
50 +
51 +MOZ_PV="${PV/_pre*}"
52 +MOZ_PV="${MOZ_PV/_alpha/a}"
53 +MOZ_PV="${MOZ_PV/_beta/b}"
54 +MOZ_PV="${MOZ_PV/_rc/rc}"
55 +MOZ_PV="${MOZ_PV/_p[0-9]}"
56 +MOZ_P="${P}"
57 +MY_MOZ_P="${PN}-${MOZ_PV}"
58 +
59 +if [[ ${PV} == *_pre* ]] ; then
60 + MOZ_HTTP_URI="https://archive.mozilla.org/pub/${PN}/candidates/${MOZ_PV}-candidates/build${PV##*_pre}"
61 +else
62 + MOZ_HTTP_URI="https://archive.mozilla.org/pub/${PN}/releases/${MOZ_PV}"
63 +fi
64 +
65 +S="${WORKDIR}/${MY_MOZ_P}"
66 +SRC_URI="${MOZ_HTTP_URI}/source/${MY_MOZ_P}.source.tar.xz -> ${P}.source.tar.xz
67 + ${MOZ_HTTP_URI}/source/${MY_MOZ_P}.source-l10n.tar.xz -> ${P}.source-l10n.tar.xz"
68 +
69 +MOZ_GENERATE_LANGPACKS=1
70 +MOZ_L10N_SOURCEDIR="${S}/${P}-l10n"
71 +inherit autotools check-reqs flag-o-matic mozcoreconf-v6 mozextension mozlinguas-v2 nsplugins pax-utils toolchain-funcs xdg-utils
72 +
73 +PATCH="${PN}-2.53.2_beta1-patches-01"
74 +
75 +DESCRIPTION="Seamonkey Web Browser"
76 +HOMEPAGE="http://www.seamonkey-project.org"
77 +KEYWORDS="~amd64 ~ppc64 ~x86"
78 +
79 +SLOT="0"
80 +LICENSE="MPL-2.0 GPL-2 LGPL-2.1"
81 +IUSE="+calendar +chatzilla +crypt dbus debug +gmp-autoupdate +ipc jack minimal
82 +neon pulseaudio +roaming selinux startup-notification system-harfbuzz system-icu
83 +system-jpeg system-libevent system-sqlite system-libvpx test wifi"
84 +RESTRICT="!test? ( test )"
85 +
86 +SRC_URI+="
87 + https://dev.gentoo.org/~polynomial-c/mozilla/patchsets/${PATCH}.tar.xz
88 +"
89 +
90 +ASM_DEPEND=">=dev-lang/yasm-1.1"
91 +
92 +DEPEND="
93 + >=app-text/hunspell-1.5.4:=
94 + dev-libs/atk
95 + >=dev-libs/glib-2.26:2
96 + >=dev-libs/libffi-3.0.10:=
97 + >=dev-libs/nspr-4.23
98 + >=dev-libs/nss-3.47.1
99 + media-libs/fontconfig
100 + >=media-libs/freetype-2.4.10
101 + >=media-libs/libpng-1.6.31:0=[apng]
102 + >=media-libs/mesa-10.2:=
103 + >=sys-libs/zlib-1.2.3
104 + >=x11-libs/cairo-1.10[X]
105 + x11-libs/gdk-pixbuf
106 + >=x11-libs/gtk+-2.18:2
107 + >=x11-libs/gtk+-3.4.0:3
108 + x11-libs/libX11
109 + x11-libs/libXcomposite
110 + x11-libs/libXdamage
111 + x11-libs/libXext
112 + x11-libs/libXfixes
113 + x11-libs/libXrender
114 + x11-libs/libXt
115 + >=x11-libs/pango-1.22.0
116 + >=x11-libs/pixman-0.19.2
117 + media-video/ffmpeg
118 + virtual/freedesktop-icon-theme
119 + dbus? (
120 + >=dev-libs/dbus-glib-0.72
121 + >=sys-apps/dbus-0.60
122 + )
123 + jack? ( virtual/jack )
124 + crypt? ( <x11-plugins/enigmail-2.1.0 )
125 + kernel_linux? ( !pulseaudio? ( media-libs/alsa-lib ) )
126 + pulseaudio? ( || (
127 + media-sound/pulseaudio
128 + >=media-sound/apulse-0.1.9
129 + ) )
130 + startup-notification? ( >=x11-libs/startup-notification-0.8 )
131 + system-harfbuzz? (
132 + >=media-gfx/graphite2-1.3.9-r1
133 + >=media-libs/harfbuzz-1.3.3:0=
134 + )
135 + system-icu? ( >=dev-libs/icu-59.1:= )
136 + system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
137 + system-libevent? ( >=dev-libs/libevent-2.0:0= )
138 + system-libvpx? ( >=media-libs/libvpx-1.5.0:0=[postproc] )
139 + system-sqlite? ( >=dev-db/sqlite-3.19.3:3[secure-delete,debug=] )
140 + wifi? (
141 + kernel_linux? (
142 + >=dev-libs/dbus-glib-0.72
143 + net-misc/networkmanager
144 + >=sys-apps/dbus-0.60
145 + )
146 + )
147 +"
148 +RDEPEND="
149 + ${DEPEND}
150 + selinux? ( sec-policy/selinux-mozilla )
151 +"
152 +# Convert to BDEPEND once the ebuild goes EAPI-7
153 +DEPEND+="
154 + app-arch/unzip
155 + app-arch/zip
156 + dev-lang/perl
157 + sys-apps/findutils
158 + >=sys-devel/binutils-2.16.1
159 + virtual/pkgconfig
160 + >=virtual/rust-1.34.0
161 + amd64? (
162 + ${ASM_DEPEND}
163 + virtual/opengl
164 + )
165 + x86? (
166 + ${ASM_DEPEND}
167 + virtual/opengl
168 + )
169 +"
170 +
171 +# allow GMP_PLUGIN_LIST to be set in an eclass or
172 +# overridden in the enviromnent (advanced hackers only)
173 +if [[ -z $GMP_PLUGIN_LIST ]] ; then
174 + GMP_PLUGIN_LIST=( gmp-gmpopenh264 gmp-widevinecdm )
175 +fi
176 +
177 +BUILD_OBJ_DIR="${S}/seamonk"
178 +
179 +pkg_setup() {
180 + if [[ ${PV} == *_pre* ]] ; then
181 + ewarn "You're using an unofficial release of ${PN}. Don't file any bug in"
182 + ewarn "Gentoo's Bugtracker against this package in case it breaks for you."
183 + ewarn "Those belong to upstream: https://bugzilla.mozilla.org"
184 + fi
185 +
186 + moz_pkgsetup
187 +}
188 +
189 +pkg_pretend() {
190 + # Ensure we have enough disk space to compile
191 + if use debug || use test ; then
192 + CHECKREQS_DISK_BUILD="16G"
193 + else
194 + CHECKREQS_DISK_BUILD="12G"
195 + fi
196 + check-reqs_pkg_setup
197 +}
198 +
199 +src_unpack() {
200 + local l10n_sources="${P}.source-l10n.tar.xz"
201 + unpack ${A/ ${l10n_sources}}
202 +
203 + mkdir "${S}/${P}-l10n" || die
204 + cd "${S}/${P}-l10n" || die
205 + unpack ${l10n_sources}
206 +}
207 +
208 +src_prepare() {
209 + # Apply our patches
210 + eapply "${WORKDIR}"/seamonkey
211 +
212 + # browser patches go here
213 + pushd "${S}"/mozilla &>/dev/null || die
214 + eapply "${WORKDIR}"/firefox
215 + popd &>/dev/null || die
216 +
217 + # Shell scripts sometimes contain DOS line endings; bug 391889
218 + grep -rlZ --include="*.sh" $'\r$' . |
219 + while read -r -d $'\0' file ; do
220 + einfo edos2unix "${file}"
221 + edos2unix "${file}"
222 + done
223 +
224 + # Allow user to apply any additional patches without modifing ebuild
225 + eapply_user
226 +
227 + local ms="${S}/mozilla"
228 +
229 + # Don't error for format with gcc-9
230 + grep -rl -- '-Werror=format' | xargs sed -i 's/error=format/no-&/' || die "sed failed"
231 +
232 + # Enable gnomebreakpad
233 + if use debug ; then
234 + sed -i -e "s:GNOME_DISABLE_CRASH_DIALOG=1:GNOME_DISABLE_CRASH_DIALOG=0:g" \
235 + "${ms}"/build/unix/run-mozilla.sh || die "sed failed!"
236 + fi
237 +
238 + # Ensure that are plugins dir is enabled as default
239 + sed -i -e "s:/usr/lib/mozilla/plugins:/usr/lib/nsbrowser/plugins:" \
240 + "${ms}"/xpcom/io/nsAppFileLocationProvider.cpp || die "sed failed to replace plugin path for 32bit!"
241 + sed -i -e "s:/usr/lib64/mozilla/plugins:/usr/lib64/nsbrowser/plugins:" \
242 + "${ms}"/xpcom/io/nsAppFileLocationProvider.cpp || die "sed failed to replace plugin path for 64bit!"
243 +
244 + # Don't exit with error when some libs are missing which we have in
245 + # system.
246 + sed '/^MOZ_PKG_FATAL_WARNINGS/s@= 1@= 0@' \
247 + -i "${S}"/suite/installer/Makefile.in || die
248 + # Don't error out when there's no files to be removed:
249 + sed 's@\(xargs rm\)$@\1 -f@' \
250 + -i "${ms}"/toolkit/mozapps/installer/packager.mk || die
251 +
252 + # Don't build libs-% locale files for chatzilla if we are not building chatzilla
253 + # (this is hard-coded in the build system at present rather than being based on configuration)
254 + if ! use chatzilla ; then
255 + sed '/extensions\/irc\/locales libs-/s@^@#@' \
256 + -i "${S}"/suite/locales/Makefile.in || die
257 + fi
258 +
259 + eautoreconf old-configure.in
260 + cd "${S}"/mozilla || die
261 + eautoconf old-configure.in
262 + cd "${S}"/mozilla/js/src || die
263 + eautoconf old-configure.in
264 +}
265 +
266 +src_configure() {
267 + MEXTENSIONS="default"
268 + # Google API keys (see http://www.chromium.org/developers/how-tos/api-keys)
269 + # Note: These are for Gentoo Linux use ONLY. For your own distribution, please
270 + # get your own set of keys.
271 + _google_api_key=AIzaSyDEAOvatFo0eTgsV_ZlEzx0ObmepsMzfAc
272 +
273 + ####################################
274 + #
275 + # mozconfig, CFLAGS and CXXFLAGS setup
276 + #
277 + ####################################
278 +
279 + mozconfig_init
280 +
281 + ##################################
282 + # Former mozconfig_config() part #
283 + ##################################
284 +
285 + # Migrated from mozcoreconf-2
286 + mozconfig_annotate 'system_libs' --with-system-bz2
287 + mozconfig_annotate 'system_libs' --with-system-zlib
288 +
289 + # Disable for testing purposes only
290 + mozconfig_annotate 'Upstream bug 1341234' --disable-stylo
291 +
292 + # Must pass release in order to properly select linker via gold useflag
293 + mozconfig_annotate 'Enable by Gentoo' --enable-release
294 +
295 + # Must pass --enable-gold if using ld.gold
296 + if tc-ld-is-gold ; then
297 + mozconfig_annotate 'tc-ld-is-gold=true' --enable-gold
298 + else
299 + mozconfig_annotate 'tc-ld-is-gold=false' --disable-gold
300 + fi
301 +
302 + # Enable position independent executables
303 + mozconfig_annotate 'enabled by Gentoo' --enable-pie
304 +
305 + mozconfig_use_enable debug
306 + mozconfig_use_enable debug tests
307 + if ! use debug ; then
308 + mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
309 + else
310 + mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
311 + fi
312 +
313 + mozconfig_use_enable startup-notification
314 +
315 + # wifi pulls in dbus so manage both here
316 + mozconfig_use_enable wifi necko-wifi
317 + if use kernel_linux && use wifi && ! use dbus ; then
318 + echo "Enabling dbus support due to wifi request"
319 + mozconfig_annotate 'dbus required by necko-wifi on linux' --enable-dbus
320 + else
321 + mozconfig_use_enable dbus
322 + mozconfig_annotate 'disabled' --disable-necko-wifi
323 + fi
324 +
325 + # These are enabled by default in all mozilla applications
326 + mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${SYSROOT}${EPREFIX}"/usr
327 + mozconfig_annotate '' --with-system-nss --with-nss-prefix="${SYSROOT}${EPREFIX}"/usr
328 + mozconfig_annotate '' --x-includes="${SYSROOT}${EPREFIX}"/usr/include --x-libraries="${SYSROOT}${EPREFIX}"/usr/$(get_libdir)
329 + if use system-libevent ; then
330 + mozconfig_annotate '' --with-system-libevent="${SYSROOT}${EPREFIX}"/usr
331 + fi
332 + mozconfig_annotate '' --prefix="${EPREFIX}"/usr
333 + mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
334 + mozconfig_annotate 'Gentoo default' --enable-system-hunspell
335 + mozconfig_annotate '' --disable-crashreporter
336 + mozconfig_annotate 'Gentoo default' --with-system-png
337 + mozconfig_annotate '' --enable-system-ffi
338 + mozconfig_annotate '' --disable-gconf
339 + mozconfig_annotate '' --with-intl-api
340 +
341 + # skia has no support for big-endian platforms
342 + if [[ $(tc-endian) == "big" ]] ; then
343 + mozconfig_annotate 'big endian target' --disable-skia
344 + else
345 + mozconfig_annotate '' --enable-skia
346 + fi
347 +
348 + # default toolkit is cairo-gtk3, optional use flags can change this
349 + mozconfig_annotate '' --enable-default-toolkit=cairo-gtk3
350 +
351 + # Instead of the standard --build= and --host=, mozilla uses --host instead
352 + # of --build, and --target intstead of --host.
353 + # Note, mozilla also has --build but it does not do what you think it does.
354 + # Set both --target and --host as mozilla uses python to guess values otherwise
355 + mozconfig_annotate '' --target="${CHOST}"
356 + mozconfig_annotate '' --host="${CBUILD:-${CHOST}}"
357 +
358 + mozconfig_use_enable pulseaudio
359 + # force the deprecated alsa sound code if pulseaudio is disabled
360 + if use kernel_linux && ! use pulseaudio ; then
361 + mozconfig_annotate '-pulseaudio' --enable-alsa
362 + fi
363 +
364 + # For testing purpose only
365 + mozconfig_annotate 'Sandbox' --enable-content-sandbox
366 +
367 + mozconfig_use_enable system-sqlite
368 + mozconfig_use_with system-jpeg
369 + mozconfig_use_with system-icu
370 + mozconfig_use_with system-libvpx
371 + mozconfig_use_with system-harfbuzz
372 + mozconfig_use_with system-harfbuzz system-graphite2
373 +
374 + # Modifications to better support ARM, bug 553364
375 + if use neon ; then
376 + mozconfig_annotate '' --with-fpu=neon
377 + mozconfig_annotate '' --with-thumb=yes
378 + mozconfig_annotate '' --with-thumb-interwork=no
379 + fi
380 + if [[ ${CHOST} == armv* ]] ; then
381 + mozconfig_annotate '' --with-float-abi=hard
382 + if ! use system-libvpx ; then
383 + sed -i -e "s|softfp|hard|" \
384 + "${S}"/mozilla/media/libvpx/moz.build \
385 + || die
386 + fi
387 + fi
388 + ##################################
389 + # Former mozconfig_config() end #
390 + ##################################
391 +
392 + # enable JACK, bug 600002
393 + mozconfig_use_enable jack
394 +
395 + # It doesn't compile on alpha without this LDFLAGS
396 + use alpha && append-ldflags "-Wl,--no-relax"
397 +
398 + # Linking fails without this due to memory exhaustion
399 + use x86 && append-ldflags "-Wl,--no-keep-memory"
400 +
401 + if ! use chatzilla ; then
402 + MEXTENSIONS+=",-irc"
403 + fi
404 + if ! use roaming ; then
405 + MEXTENSIONS+=",-sroaming"
406 + fi
407 +
408 + # Setup api key for location services
409 + echo -n "${_google_api_key}" > "${S}"/google-api-key
410 + mozconfig_annotate '' --with-google-location-service-api-keyfile="${S}/google-api-key"
411 + mozconfig_annotate '' --with-google-safebrowsing-api-keyfile="${S}/google-api-key"
412 +
413 + mozconfig_annotate '' --enable-extensions="${MEXTENSIONS}"
414 +
415 + # sm-specific settings
416 + mozconfig_use_enable calendar
417 +
418 + # Use an objdir to keep things organized.
419 + echo "mk_add_options MOZ_OBJDIR=${BUILD_OBJ_DIR}" >> "${S}"/.mozconfig
420 + echo "mk_add_options XARGS=/usr/bin/xargs" >> "${S}"/.mozconfig
421 +
422 + mozlinguas_mozconfig
423 +
424 + # Finalize and report settings
425 + mozconfig_final
426 +
427 + # Required until mozcoreconf-v?.eclass-es are finally fixed...
428 + sed \
429 + -e '/--enable-application/s@comm/suite@suite@' \
430 + -i .mozconfig || die
431 +
432 + # Work around breakage in makeopts with --no-print-directory
433 + MAKEOPTS="${MAKEOPTS/--no-print-directory/}"
434 +
435 + if [[ $(gcc-major-version) -lt 4 ]] ; then
436 + append-cxxflags -fno-stack-protector
437 + elif [[ $(gcc-major-version) -gt 4 || $(gcc-minor-version) -gt 3 ]] ; then
438 + if use amd64 || use x86 ; then
439 + append-flags -mno-avx
440 + fi
441 + fi
442 +
443 + # workaround for funky/broken upstream configure...
444 + SHELL="${SHELL:-${EPREFIX%/}/bin/bash}" \
445 + emake V=1 -f client.mk configure
446 +}
447 +
448 +src_compile() {
449 + MOZ_MAKE_FLAGS="${MAKEOPTS}" SHELL="${SHELL}" \
450 + emake V=1 -f client.mk
451 +
452 + mozlinguas_src_compile
453 +}
454 +
455 +src_install() {
456 + MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
457 + DICTPATH="\"${EPREFIX}/usr/share/myspell\""
458 +
459 + local emid
460 + cd "${BUILD_OBJ_DIR}" || die
461 +
462 + # Pax mark xpcshell for hardened support, only used for startupcache creation.
463 + pax-mark m "${BUILD_OBJ_DIR}/dist/bin/xpcshell"
464 +
465 + # Copy our preference before omnijar is created.
466 + sed "s|SEAMONKEY_PVR|${PVR}|" "${FILESDIR}"/all-gentoo-1.js > \
467 + "${BUILD_OBJ_DIR}/dist/bin/defaults/pref/all-gentoo.js" \
468 + || die
469 +
470 + # Set default path to search for dictionaries.
471 + echo "pref(\"spellchecker.dictionary_path\", ${DICTPATH});" \
472 + >> "${BUILD_OBJ_DIR}/dist/bin/defaults/pref/all-gentoo.js" \
473 + || die
474 +
475 + echo 'pref("extensions.autoDisableScopes", 3);' >> \
476 + "${BUILD_OBJ_DIR}/dist/bin/defaults/pref/all-gentoo.js" \
477 + || die
478 +
479 + local plugin
480 + if ! use gmp-autoupdate ; then
481 + for plugin in "${GMP_PLUGIN_LIST[@]}" ; do
482 + echo "pref(\"media.${plugin}.autoupdate\", false);" >> \
483 + "${S}/${BUILD_OBJ_DIR}/dist/bin/browser/defaults/preferences/all-gentoo.js" \
484 + || dir
485 + done
486 + fi
487 +
488 + MOZ_MAKE_FLAGS="${MAKEOPTS}" SHELL="${SHELL:-${EPREFIX%/}/bin/bash}" \
489 + emake DESTDIR="${D}" install
490 + MOZ_P="${MY_MOZ_P}" mozlinguas_src_install
491 + cp "${FILESDIR}"/${PN}.desktop "${T}" || die
492 +
493 + sed 's|^\(MimeType=.*\)$|\1text/x-vcard;text/directory;application/mbox;message/rfc822;x-scheme-handler/mailto;|' \
494 + -i "${T}"/${PN}.desktop || die
495 + sed 's|^\(Categories=.*\)$|\1Email;|' -i "${T}"/${PN}.desktop \
496 + || die
497 +
498 + # Install icon and .desktop for menu entry
499 + newicon "${S}"/suite/branding/${PN}/default64.png ${PN}.png
500 + domenu "${T}"/${PN}.desktop
501 +
502 + # Required in order to use plugins and even run seamonkey on hardened.
503 + pax-mark m "${ED}"${MOZILLA_FIVE_HOME}/{seamonkey,seamonkey-bin,plugin-container}
504 +
505 + if use minimal ; then
506 + rm -rf "${ED}"/usr/include "${ED}${MOZILLA_FIVE_HOME}"/{idl,include,lib,sdk}
507 + fi
508 +
509 + if use chatzilla ; then
510 + local emid='{59c81df5-4b7a-477b-912d-4e0fdf64e5f2}'
511 +
512 + # remove the en_US-only xpi file so a version with all requested locales can be installed
513 + if [[ -e "${ED}"${MOZILLA_FIVE_HOME}/distribution/extensions/${emid}.xpi ]]; then
514 + rm -f "${ED}"${MOZILLA_FIVE_HOME}/distribution/extensions/${emid}.xpi || die
515 + fi
516 +
517 + # merge the extra locales into the main extension
518 + mozlinguas_xpistage_langpacks "${BUILD_OBJ_DIR}"/dist/xpi-stage/chatzilla
519 +
520 + # install the merged extension
521 + mkdir -p "${T}/${emid}" || die
522 + cp -RLp -t "${T}/${emid}" "${BUILD_OBJ_DIR}"/dist/xpi-stage/chatzilla/* || die
523 + insinto ${MOZILLA_FIVE_HOME}/distribution/extensions
524 + doins -r "${T}/${emid}"
525 + fi
526 +
527 + # Handle plugins dir through nsplugins.eclass
528 + share_plugins_dir
529 +
530 + # revdep-rebuild entry
531 + insinto /etc/revdep-rebuild
532 + echo "SEARCH_DIRS_MASK=${MOZILLA_FIVE_HOME}*" >> ${T}/11${PN}
533 + doins "${T}"/11${PN}
534 +}
535 +
536 +pkg_preinst() {
537 + MOZILLA_FIVE_HOME="${ROOT}/usr/$(get_libdir)/${PN}"
538 +
539 + if [ -d ${MOZILLA_FIVE_HOME}/plugins ] ; then
540 + rm ${MOZILLA_FIVE_HOME}/plugins -rf
541 + fi
542 +}
543 +
544 +pkg_postinst() {
545 + MOZILLA_FIVE_HOME="/usr/$(get_libdir)/${PN}"
546 +
547 + # Update mimedb for the new .desktop file
548 + xdg_desktop_database_update
549 +
550 + if ! use gmp-autoupdate ; then
551 + elog "USE='-gmp-autoupdate' has disabled the following plugins from updating or"
552 + elog "installing into new profiles:"
553 + local plugin
554 + for plugin in "${GMP_PLUGIN_LIST[@]}"; do elog "\t ${plugin}" ; done
555 + fi
556 +
557 + if use chatzilla ; then
558 + elog "chatzilla is now an extension which can be en-/disabled and configured via"
559 + elog "the Add-on manager."
560 + fi
561 +}