Gentoo Archives: gentoo-commits

From: Jory Pratt <anarchy@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/mozilla:master commit in: eclass/
Date: Mon, 06 Feb 2017 02:30:11
Message-Id: 1486348198.6f170f91d36420b53be07a169095eedf2b33f5c5.anarchy@gentoo
1 commit: 6f170f91d36420b53be07a169095eedf2b33f5c5
2 Author: Jory A. Pratt <anarchy <AT> gentoo <DOT> org>
3 AuthorDate: Mon Feb 6 02:29:35 2017 +0000
4 Commit: Jory Pratt <anarchy <AT> gentoo <DOT> org>
5 CommitDate: Mon Feb 6 02:29:58 2017 +0000
6 URL: https://gitweb.gentoo.org/proj/mozilla.git/commit/?id=6f170f91
7
8 eclass/* : remove obsolete eclasses
9
10 eclass/mozconfig-v6.38.eclass | 256 -------------------------
11 eclass/mozconfig-v6.39.eclass | 240 ------------------------
12 eclass/mozconfig-v6.41.eclass | 263 --------------------------
13 eclass/mozconfig-v6.42.eclass | 282 ----------------------------
14 eclass/mozconfig-v6.44.eclass | 340 ----------------------------------
15 eclass/mozconfig-v6.46.eclass | 408 ----------------------------------------
16 eclass/mozconfig-v6.47.eclass | 420 ------------------------------------------
17 eclass/mozconfig-v6.48.eclass | 409 ----------------------------------------
18 eclass/mozcoreconf-v3.eclass | 261 --------------------------
19 eclass/mozlinguas.eclass | 321 --------------------------------
20 10 files changed, 3200 deletions(-)
21
22 diff --git a/eclass/mozconfig-v6.38.eclass b/eclass/mozconfig-v6.38.eclass
23 deleted file mode 100644
24 index 7f70597..0000000
25 --- a/eclass/mozconfig-v6.38.eclass
26 +++ /dev/null
27 @@ -1,256 +0,0 @@
28 -# Copyright 1999-2015 Gentoo Foundation
29 -# Distributed under the terms of the GNU General Public License v2
30 -# $Id$
31 -#
32 -# @ECLASS: mozconfig-v5.33.eclass
33 -# @MAINTAINER:
34 -# mozilla team <mozilla@g.o>
35 -# @BLURB: the new mozilla common configuration eclass for FF33 and newer, v5
36 -# @DESCRIPTION:
37 -# This eclass is used in mozilla ebuilds (firefox, thunderbird, seamonkey)
38 -# to provide a single common place for the common mozilla engine compoments.
39 -#
40 -# The eclass provides all common dependencies as well as common use flags.
41 -#
42 -# Some use flags which may be optional in particular mozilla packages can be
43 -# supported through setting eclass variables.
44 -#
45 -# This eclass inherits mozconfig helper functions as defined in mozcoreconf-v3,
46 -# and so ebuilds inheriting this eclass do not need to inherit that.
47 -
48 -inherit multilib flag-o-matic toolchain-funcs mozcoreconf-v3
49 -
50 -case ${EAPI} in
51 - 0|1|2|3|4) die "EAPI=${EAPI} not supported"
52 -esac
53 -
54 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_WIFI
55 -# @DESCRIPTION:
56 -# Set this variable before the inherit line, when an ebuild needs to provide
57 -# optional necko-wifi support via IUSE="wifi". Currently this would include
58 -# ebuilds for firefox, and potentially seamonkey.
59 -#
60 -# Leave the variable UNSET if necko-wifi support should not be available.
61 -# Set the variable to "enabled" if the use flag should be enabled by default.
62 -# Set the variable to any value if the use flag should exist but not be default-enabled.
63 -
64 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_JIT
65 -# @DESCRIPTION:
66 -# Set this variable before the inherit line, when an ebuild needs to provide
67 -# optional necko-wifi support via IUSE="jit". Currently this would include
68 -# ebuilds for firefox, and potentially seamonkey.
69 -#
70 -# Leave the variable UNSET if optional jit support should not be available.
71 -# Set the variable to "enabled" if the use flag should be enabled by default.
72 -# Set the variable to any value if the use flag should exist but not be default-enabled.
73 -
74 -# use-flags common among all mozilla ebuilds
75 -IUSE="${IUSE} dbus debug gstreamer gstreamer-0 +jemalloc3 neon pulseaudio selinux startup-notification system-cairo system-icu system-jpeg system-sqlite system-libvpx"
76 -
77 -# some notes on deps:
78 -# gtk:2 minimum is technically 2.10 but gio support (enabled by default) needs 2.14
79 -# media-libs/mesa needs to be 10.2 or above due to a bug with flash+vdpau
80 -
81 -RDEPEND=">=app-text/hunspell-1.2:=
82 - dev-libs/atk
83 - dev-libs/expat
84 - >=dev-libs/libevent-1.4.7
85 - >=x11-libs/cairo-1.10[X]
86 - >=x11-libs/gtk+-2.18:2
87 - x11-libs/gdk-pixbuf
88 - >=x11-libs/pango-1.22.0
89 - >=media-libs/libpng-1.6.16:0=[apng]
90 - >=media-libs/mesa-10.2:*
91 - media-libs/fontconfig
92 - >=media-libs/freetype-2.4.10
93 - kernel_linux? ( media-libs/alsa-lib )
94 - pulseaudio? ( media-sound/pulseaudio )
95 - virtual/freedesktop-icon-theme
96 - dbus? ( >=sys-apps/dbus-0.60
97 - >=dev-libs/dbus-glib-0.72 )
98 - startup-notification? ( >=x11-libs/startup-notification-0.8 )
99 - >=dev-libs/glib-2.26:2
100 - >=sys-libs/zlib-1.2.3
101 - >=virtual/libffi-3.0.10
102 - gstreamer? (
103 - >=media-libs/gstreamer-1.4.5:1.0
104 - >=media-libs/gst-plugins-base-1.4.5:1.0
105 - >=media-libs/gst-plugins-good-1.4.5:1.0
106 - >=media-plugins/gst-plugins-libav-1.4.5:1.0
107 - )
108 - gstreamer-0? (
109 - media-plugins/gst-plugins-meta:0.10[ffmpeg]
110 - )
111 - x11-libs/libX11
112 - x11-libs/libXcomposite
113 - x11-libs/libXdamage
114 - x11-libs/libXext
115 - x11-libs/libXfixes
116 - x11-libs/libXrender
117 - x11-libs/libXt
118 - system-cairo? ( >=x11-libs/cairo-1.12[X] >=x11-libs/pixman-0.19.2 )
119 - system-icu? ( >=dev-libs/icu-51.1:= )
120 - system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
121 - system-sqlite? ( >=dev-db/sqlite-3.8.8.2:3[secure-delete,debug=] )
122 - system-libvpx? ( >=media-libs/libvpx-1.3.0:0=[postproc] )
123 -"
124 -
125 -if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]]; then
126 - if [[ ${MOZCONFIG_OPTIONAL_WIFI} = "enabled" ]]; then
127 - IUSE+=" +wifi"
128 - else
129 - IUSE+=" wifi"
130 - fi
131 - RDEPEND+="
132 - wifi? ( >=sys-apps/dbus-0.60
133 - >=dev-libs/dbus-glib-0.72
134 - net-wireless/wireless-tools )"
135 -fi
136 -if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
137 - if [[ ${MOZCONFIG_OPTIONAL_JIT} = "enabled" ]]; then
138 - IUSE+=" +jit"
139 - else
140 - IUSE+=" jit"
141 - fi
142 -fi
143 -
144 -DEPEND="app-arch/zip
145 - app-arch/unzip
146 - >=sys-devel/binutils-2.16.1
147 - ${RDEPEND}"
148 -
149 -RDEPEND+="
150 - selinux? ( sec-policy/selinux-mozilla )"
151 -
152 -# only one of gstreamer and gstreamer-0 can be enabled at a time, so set REQUIRED_USE to signify this
153 -REQUIRED_USE="?? ( gstreamer gstreamer-0 )"
154 -
155 -# @FUNCTION: mozconfig_config
156 -# @DESCRIPTION:
157 -# Set common configure options for mozilla packages.
158 -# Call this within src_configure() phase, after mozconfig_init
159 -#
160 -# Example:
161 -#
162 -# inherit mozconfig-v5.33
163 -#
164 -# src_configure() {
165 -# mozconfig_init
166 -# mozconfig_config
167 -# # ... misc ebuild-unique settings via calls to
168 -# # ... mozconfig_{annotate,use_with,use_enable}
169 -# mozconfig_final
170 -# }
171 -
172 -mozconfig_config() {
173 - # Migrated from mozcoreconf-2
174 - mozconfig_annotate 'system_libs' \
175 - --with-system-zlib \
176 - --enable-pango \
177 - --enable-svg \
178 - --with-system-bz2
179 -
180 - mozconfig_annotate '' --enable-default-toolkit=cairo-gtk2
181 -
182 - if has bindist ${IUSE}; then
183 - mozconfig_use_enable !bindist official-branding
184 - if [[ ${PN} == firefox ]] && use bindist ; then
185 - mozconfig_annotate '' --with-branding=browser/branding/aurora
186 - fi
187 - fi
188 -
189 - mozconfig_use_enable debug
190 - mozconfig_use_enable debug tests
191 -
192 - if ! use debug ; then
193 - mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
194 - else
195 - mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
196 - fi
197 -
198 - mozconfig_use_enable startup-notification
199 -
200 - if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]] ; then
201 - # wifi pulls in dbus so manage both here
202 - mozconfig_use_enable wifi necko-wifi
203 - if use wifi && ! use dbus; then
204 - echo "Enabling dbus support due to wifi request"
205 - mozconfig_annotate 'dbus required by necko-wifi' --enable-dbus
206 - else
207 - mozconfig_use_enable dbus
208 - fi
209 - else
210 - mozconfig_use_enable dbus
211 - mozconfig_annotate 'disabled' --disable-necko-wifi
212 - fi
213 -
214 - # These are forced-on for webm support
215 - mozconfig_annotate 'required' --enable-ogg
216 - mozconfig_annotate 'required' --enable-wave
217 -
218 - if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
219 - mozconfig_use_enable jit ion
220 - fi
221 -
222 - # These are enabled by default in all mozilla applications
223 - mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${EPREFIX}"/usr
224 - mozconfig_annotate '' --with-system-nss --with-nss-prefix="${EPREFIX}"/usr
225 - mozconfig_annotate '' --x-includes="${EPREFIX}"/usr/include --x-libraries="${EPREFIX}"/usr/$(get_libdir)
226 - mozconfig_annotate '' --with-system-libevent="${EPREFIX}"/usr
227 - mozconfig_annotate '' --prefix="${EPREFIX}"/usr
228 - mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
229 - mozconfig_annotate 'Gentoo default' --enable-system-hunspell
230 - mozconfig_annotate '' --disable-gnomevfs
231 - mozconfig_annotate '' --disable-gnomeui
232 - mozconfig_annotate '' --enable-gio
233 - mozconfig_annotate '' --disable-crashreporter
234 - mozconfig_annotate 'Gentoo default' --with-system-png
235 - mozconfig_annotate '' --enable-system-ffi
236 - mozconfig_annotate 'Gentoo default to honor system linker' --disable-gold
237 - mozconfig_annotate '' --disable-gconf
238 - mozconfig_annotate 'Gentoo default' --disable-skia
239 - mozconfig_annotate '' --with-intl-api
240 -
241 - # Use jemalloc unless libc is not glibc >= 2.4
242 - # at this time the minimum glibc in the tree is 2.9 so we should be safe.
243 - if use elibc_glibc && use jemalloc3; then
244 - # We must force-enable jemalloc 3 via .mozconfig
245 - echo "export MOZ_JEMALLOC3=1" >> "${S}"/.mozconfig || die
246 - mozconfig_annotate '' --enable-jemalloc
247 - mozconfig_annotate '' --enable-replace-malloc
248 - fi
249 -
250 - mozconfig_annotate '' --target="${CTARGET:-${CHOST}}"
251 - mozconfig_annotate '' --build="${CTARGET:-${CHOST}}"
252 -
253 - if use gstreamer ; then
254 - mozconfig_annotate '+gstreamer' --enable-gstreamer=1.0
255 - elif use gstreamer-0 ; then
256 - mozconfig_annotate '+gstreamer-0' --enable-gstreamer=0.10
257 - else
258 - mozconfig_annotate '' --disable-gstreamer
259 - fi
260 - mozconfig_use_enable pulseaudio
261 -
262 - mozconfig_use_enable system-cairo
263 - mozconfig_use_enable system-sqlite
264 - mozconfig_use_with system-jpeg
265 - mozconfig_use_with system-icu
266 - mozconfig_use_with system-libvpx
267 -
268 - # Modifications to better support ARM, bug 553364
269 - if use neon ; then
270 - mozconfig_annotate '' --with-fpu=neon
271 - mozconfig_annotate '' --with-thumb=yes
272 - mozconfig_annotate '' --with-thumb-interwork=no
273 - fi
274 - if [[ ${CHOST} == armv* ]] ; then
275 - mozconfig_annotate '' --with-float-abi=hard
276 - mozconfig_annotate '' --enable-skia
277 -
278 - if ! use system-libvpx ; then
279 - sed -i -e "s|softfp|hard|" \
280 - "${S}"/media/libvpx/moz.build
281 - fi
282 - fi
283 -}
284
285 diff --git a/eclass/mozconfig-v6.39.eclass b/eclass/mozconfig-v6.39.eclass
286 deleted file mode 100644
287 index 3e71ac7..0000000
288 --- a/eclass/mozconfig-v6.39.eclass
289 +++ /dev/null
290 @@ -1,240 +0,0 @@
291 -# Copyright 1999-2015 Gentoo Foundation
292 -# Distributed under the terms of the GNU General Public License v2
293 -# $Id$
294 -#
295 -# @ECLASS: mozconfig-v5.33.eclass
296 -# @MAINTAINER:
297 -# mozilla team <mozilla@g.o>
298 -# @BLURB: the new mozilla common configuration eclass for FF33 and newer, v5
299 -# @DESCRIPTION:
300 -# This eclass is used in mozilla ebuilds (firefox, thunderbird, seamonkey)
301 -# to provide a single common place for the common mozilla engine compoments.
302 -#
303 -# The eclass provides all common dependencies as well as common use flags.
304 -#
305 -# Some use flags which may be optional in particular mozilla packages can be
306 -# supported through setting eclass variables.
307 -#
308 -# This eclass inherits mozconfig helper functions as defined in mozcoreconf-v3,
309 -# and so ebuilds inheriting this eclass do not need to inherit that.
310 -
311 -inherit multilib flag-o-matic toolchain-funcs mozcoreconf-v3
312 -
313 -case ${EAPI} in
314 - 0|1|2|3|4) die "EAPI=${EAPI} not supported"
315 -esac
316 -
317 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_WIFI
318 -# @DESCRIPTION:
319 -# Set this variable before the inherit line, when an ebuild needs to provide
320 -# optional necko-wifi support via IUSE="wifi". Currently this would include
321 -# ebuilds for firefox, and potentially seamonkey.
322 -#
323 -# Leave the variable UNSET if necko-wifi support should not be available.
324 -# Set the variable to "enabled" if the use flag should be enabled by default.
325 -# Set the variable to any value if the use flag should exist but not be default-enabled.
326 -
327 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_JIT
328 -# @DESCRIPTION:
329 -# Set this variable before the inherit line, when an ebuild needs to provide
330 -# optional necko-wifi support via IUSE="jit". Currently this would include
331 -# ebuilds for firefox, and potentially seamonkey.
332 -#
333 -# Leave the variable UNSET if optional jit support should not be available.
334 -# Set the variable to "enabled" if the use flag should be enabled by default.
335 -# Set the variable to any value if the use flag should exist but not be default-enabled.
336 -
337 -# use-flags common among all mozilla ebuilds
338 -IUSE="${IUSE} dbus debug gstreamer gstreamer-0 +jemalloc3 pulseaudio selinux startup-notification system-cairo system-icu system-jpeg system-sqlite system-libvpx"
339 -
340 -# some notes on deps:
341 -# gtk:2 minimum is technically 2.10 but gio support (enabled by default) needs 2.14
342 -# media-libs/mesa needs to be 10.2 or above due to a bug with flash+vdpau
343 -
344 -RDEPEND=">=app-text/hunspell-1.2:=
345 - dev-libs/atk
346 - dev-libs/expat
347 - >=dev-libs/libevent-1.4.7
348 - >=x11-libs/cairo-1.10[X]
349 - >=x11-libs/gtk+-2.18:2
350 - x11-libs/gdk-pixbuf
351 - >=x11-libs/pango-1.22.0
352 - >=media-libs/libpng-1.6.16:0=[apng]
353 - >=media-libs/mesa-10.2:*
354 - media-libs/fontconfig
355 - >=media-libs/freetype-2.4.10
356 - kernel_linux? ( media-libs/alsa-lib )
357 - pulseaudio? ( media-sound/pulseaudio )
358 - virtual/freedesktop-icon-theme
359 - dbus? ( >=sys-apps/dbus-0.60
360 - >=dev-libs/dbus-glib-0.72 )
361 - startup-notification? ( >=x11-libs/startup-notification-0.8 )
362 - >=dev-libs/glib-2.26:2
363 - >=sys-libs/zlib-1.2.3
364 - >=virtual/libffi-3.0.10
365 - gstreamer? (
366 - >=media-libs/gstreamer-1.4.5:1.0
367 - >=media-libs/gst-plugins-base-1.4.5:1.0
368 - >=media-libs/gst-plugins-good-1.4.5:1.0
369 - >=media-plugins/gst-plugins-libav-1.4.5:1.0
370 - )
371 - gstreamer-0? (
372 - >=media-libs/gstreamer-0.10.25:0.10
373 - media-plugins/gst-plugins-meta:0.10[ffmpeg]
374 - )
375 - x11-libs/libX11
376 - x11-libs/libXcomposite
377 - x11-libs/libXdamage
378 - x11-libs/libXext
379 - x11-libs/libXfixes
380 - x11-libs/libXrender
381 - x11-libs/libXt
382 - system-cairo? ( >=x11-libs/cairo-1.12[X] >=x11-libs/pixman-0.19.2 )
383 - system-icu? ( >=dev-libs/icu-51.1:= )
384 - system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
385 - system-sqlite? ( >=dev-db/sqlite-3.8.9:3[secure-delete,debug=] )
386 - system-libvpx? ( >=media-libs/libvpx-1.3.0:0=[postproc] )
387 -"
388 -
389 -if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]]; then
390 - if [[ ${MOZCONFIG_OPTIONAL_WIFI} = "enabled" ]]; then
391 - IUSE+=" +wifi"
392 - else
393 - IUSE+=" wifi"
394 - fi
395 - RDEPEND+="
396 - wifi? ( >=sys-apps/dbus-0.60
397 - >=dev-libs/dbus-glib-0.72
398 - net-wireless/wireless-tools )"
399 -fi
400 -if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
401 - if [[ ${MOZCONFIG_OPTIONAL_JIT} = "enabled" ]]; then
402 - IUSE+=" +jit"
403 - else
404 - IUSE+=" jit"
405 - fi
406 -fi
407 -
408 -DEPEND="app-arch/zip
409 - app-arch/unzip
410 - >=sys-devel/binutils-2.16.1
411 - ${RDEPEND}"
412 -
413 -RDEPEND+="
414 - selinux? ( sec-policy/selinux-mozilla )"
415 -
416 -# only one of gstreamer and gstreamer-0 can be enabled at a time, so set REQUIRED_USE to signify this
417 -REQUIRED_USE="?? ( gstreamer gstreamer-0 )"
418 -
419 -# @FUNCTION: mozconfig_config
420 -# @DESCRIPTION:
421 -# Set common configure options for mozilla packages.
422 -# Call this within src_configure() phase, after mozconfig_init
423 -#
424 -# Example:
425 -#
426 -# inherit mozconfig-v5.33
427 -#
428 -# src_configure() {
429 -# mozconfig_init
430 -# mozconfig_config
431 -# # ... misc ebuild-unique settings via calls to
432 -# # ... mozconfig_{annotate,use_with,use_enable}
433 -# mozconfig_final
434 -# }
435 -
436 -mozconfig_config() {
437 - # Migrated from mozcoreconf-2
438 - mozconfig_annotate 'system_libs' \
439 - --with-system-zlib \
440 - --enable-pango \
441 - --enable-svg \
442 - --with-system-bz2
443 -
444 - mozconfig_annotate '' --enable-default-toolkit=cairo-gtk2
445 -
446 - if has bindist ${IUSE}; then
447 - mozconfig_use_enable !bindist official-branding
448 - if [[ ${PN} == firefox ]] && use bindist ; then
449 - mozconfig_annotate '' --with-branding=browser/branding/aurora
450 - fi
451 - fi
452 -
453 - mozconfig_use_enable debug
454 - mozconfig_use_enable debug tests
455 -
456 - if ! use debug ; then
457 - mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
458 - else
459 - mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
460 - fi
461 -
462 - mozconfig_use_enable startup-notification
463 -
464 - if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]] ; then
465 - # wifi pulls in dbus so manage both here
466 - mozconfig_use_enable wifi necko-wifi
467 - if use wifi && ! use dbus; then
468 - echo "Enabling dbus support due to wifi request"
469 - mozconfig_annotate 'dbus required by necko-wifi' --enable-dbus
470 - else
471 - mozconfig_use_enable dbus
472 - fi
473 - else
474 - mozconfig_use_enable dbus
475 - mozconfig_annotate 'disabled' --disable-necko-wifi
476 - fi
477 -
478 - # These are forced-on for webm support
479 - mozconfig_annotate 'required' --enable-ogg
480 - mozconfig_annotate 'required' --enable-wave
481 -
482 - if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
483 - mozconfig_use_enable jit ion
484 - fi
485 -
486 - # These are enabled by default in all mozilla applications
487 - mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${EPREFIX}"/usr
488 - mozconfig_annotate '' --with-system-nss --with-nss-prefix="${EPREFIX}"/usr
489 - mozconfig_annotate '' --x-includes="${EPREFIX}"/usr/include --x-libraries="${EPREFIX}"/usr/$(get_libdir)
490 - mozconfig_annotate '' --with-system-libevent="${EPREFIX}"/usr
491 - mozconfig_annotate '' --prefix="${EPREFIX}"/usr
492 - mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
493 - mozconfig_annotate 'Gentoo default' --enable-system-hunspell
494 - mozconfig_annotate '' --disable-gnomevfs
495 - mozconfig_annotate '' --disable-gnomeui
496 - mozconfig_annotate '' --enable-gio
497 - mozconfig_annotate '' --disable-crashreporter
498 - mozconfig_annotate 'Gentoo default' --with-system-png
499 - mozconfig_annotate '' --enable-system-ffi
500 - mozconfig_annotate 'Gentoo default to honor system linker' --disable-gold
501 - mozconfig_annotate '' --disable-gconf
502 -
503 - # Use jemalloc unless libc is not glibc >= 2.4
504 - # at this time the minimum glibc in the tree is 2.9 so we should be safe.
505 - if use elibc_glibc && use jemalloc3; then
506 - # We must force-enable jemalloc 3 via .mozconfig
507 - echo "export MOZ_JEMALLOC3=1" >> "${S}"/.mozconfig || die
508 - mozconfig_annotate '' --enable-jemalloc
509 - mozconfig_annotate '' --enable-replace-malloc
510 - fi
511 -
512 - mozconfig_annotate '' --target="${CTARGET:-${CHOST}}"
513 - mozconfig_annotate '' --build="${CTARGET:-${CHOST}}"
514 -
515 - if use gstreamer ; then
516 - mozconfig_annotate '+gstreamer' --enable-gstreamer=1.0
517 - elif use gstreamer-0 ; then
518 - mozconfig_annotate '+gstreamer-0' --enable-gstreamer=0.10
519 - else
520 - mozconfig_annotate '' --disable-gstreamer
521 - fi
522 - mozconfig_use_enable pulseaudio
523 -
524 - mozconfig_use_enable system-cairo
525 - mozconfig_use_enable system-sqlite
526 - mozconfig_use_with system-jpeg
527 - mozconfig_use_with system-icu
528 - mozconfig_use_with system-icu intl-api
529 - mozconfig_use_with system-libvpx
530 -}
531
532 diff --git a/eclass/mozconfig-v6.41.eclass b/eclass/mozconfig-v6.41.eclass
533 deleted file mode 100644
534 index 6ff9a2a..0000000
535 --- a/eclass/mozconfig-v6.41.eclass
536 +++ /dev/null
537 @@ -1,263 +0,0 @@
538 -# Copyright 1999-2015 Gentoo Foundation
539 -# Distributed under the terms of the GNU General Public License v2
540 -# $Id$
541 -#
542 -# @ECLASS: mozconfig-v6.40.eclass
543 -# @MAINTAINER:
544 -# mozilla team <mozilla@g.o>
545 -# @BLURB: the new mozilla common configuration eclass for FF33 and newer, v6
546 -# @DESCRIPTION:
547 -# This eclass is used in mozilla ebuilds (firefox, thunderbird, seamonkey)
548 -# to provide a single common place for the common mozilla engine compoments.
549 -#
550 -# The eclass provides all common dependencies as well as common use flags.
551 -#
552 -# Some use flags which may be optional in particular mozilla packages can be
553 -# supported through setting eclass variables.
554 -#
555 -# This eclass inherits mozconfig helper functions as defined in mozcoreconf-v3,
556 -# and so ebuilds inheriting this eclass do not need to inherit that.
557 -
558 -inherit multilib flag-o-matic toolchain-funcs mozcoreconf-v3
559 -
560 -case ${EAPI} in
561 - 0|1|2|3|4) die "EAPI=${EAPI} not supported"
562 -esac
563 -
564 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_WIFI
565 -# @DESCRIPTION:
566 -# Set this variable before the inherit line, when an ebuild needs to provide
567 -# optional necko-wifi support via IUSE="wifi". Currently this would include
568 -# ebuilds for firefox, and potentially seamonkey.
569 -#
570 -# Leave the variable UNSET if necko-wifi support should not be available.
571 -# Set the variable to "enabled" if the use flag should be enabled by default.
572 -# Set the variable to any value if the use flag should exist but not be default-enabled.
573 -
574 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_JIT
575 -# @DESCRIPTION:
576 -# Set this variable before the inherit line, when an ebuild needs to provide
577 -# optional necko-wifi support via IUSE="jit". Currently this would include
578 -# ebuilds for firefox, and potentially seamonkey.
579 -#
580 -# Leave the variable UNSET if optional jit support should not be available.
581 -# Set the variable to "enabled" if the use flag should be enabled by default.
582 -# Set the variable to any value if the use flag should exist but not be default-enabled.
583 -
584 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK3
585 -# @DESCRIPTION:
586 -# Set this variable before the inherit line, when an ebuild can provide
587 -# optional gtk3 support via IUSE="gtk3". Currently this would include
588 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
589 -#
590 -# Leave the variable UNSET if gtk3 support should not be available.
591 -# Set the variable to "enabled" if the use flag should be enabled by default.
592 -# Set the variable to any value if the use flag should exist but not be default-enabled.
593 -
594 -# use-flags common among all mozilla ebuilds
595 -IUSE="${IUSE} dbus debug gstreamer gstreamer-0 +jemalloc3 pulseaudio selinux startup-notification system-cairo system-icu system-jpeg system-sqlite system-libvpx"
596 -
597 -# some notes on deps:
598 -# gtk:2 minimum is technically 2.10 but gio support (enabled by default) needs 2.14
599 -# media-libs/mesa needs to be 10.2 or above due to a bug with flash+vdpau
600 -
601 -RDEPEND=">=app-text/hunspell-1.2:=
602 - dev-libs/atk
603 - dev-libs/expat
604 - >=dev-libs/libevent-1.4.7
605 - >=x11-libs/cairo-1.10[X]
606 - >=x11-libs/gtk+-2.18:2
607 - x11-libs/gdk-pixbuf
608 - >=x11-libs/pango-1.22.0
609 - >=media-libs/libpng-1.6.17:0=[apng]
610 - >=media-libs/mesa-10.2:*
611 - media-libs/fontconfig
612 - >=media-libs/freetype-2.4.10
613 - kernel_linux? ( media-libs/alsa-lib )
614 - pulseaudio? ( media-sound/pulseaudio )
615 - virtual/freedesktop-icon-theme
616 - dbus? ( >=sys-apps/dbus-0.60
617 - >=dev-libs/dbus-glib-0.72 )
618 - startup-notification? ( >=x11-libs/startup-notification-0.8 )
619 - >=dev-libs/glib-2.26:2
620 - >=sys-libs/zlib-1.2.3
621 - >=virtual/libffi-3.0.10
622 - gstreamer? (
623 - >=media-libs/gstreamer-1.4.5:1.0
624 - >=media-libs/gst-plugins-base-1.4.5:1.0
625 - >=media-libs/gst-plugins-good-1.4.5:1.0
626 - >=media-plugins/gst-plugins-libav-1.4.5:1.0
627 - )
628 - gstreamer-0? (
629 - >=media-libs/gstreamer-0.10.25:0.10
630 - media-plugins/gst-plugins-meta:0.10[ffmpeg]
631 - )
632 - x11-libs/libX11
633 - x11-libs/libXcomposite
634 - x11-libs/libXdamage
635 - x11-libs/libXext
636 - x11-libs/libXfixes
637 - x11-libs/libXrender
638 - x11-libs/libXt
639 - system-cairo? ( >=x11-libs/cairo-1.12[X] >=x11-libs/pixman-0.19.2 )
640 - system-icu? ( >=dev-libs/icu-51.1:= )
641 - system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
642 - system-sqlite? ( >=dev-db/sqlite-3.8.10.1:3[secure-delete,debug=] )
643 - system-libvpx? ( >=media-libs/libvpx-1.3.0:0=[postproc] )
644 -"
645 -
646 -if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
647 - if [[ ${MOZCONFIG_OPTIONAL_GTK3} = "enabled" ]]; then
648 - IUSE+=" +gtk3"
649 - else
650 - IUSE+=" gtk3"
651 - fi
652 - RDEPEND+="
653 - gtk3? ( >=x11-libs/gtk+-3.14.0:3 )"
654 -fi
655 -if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]]; then
656 - if [[ ${MOZCONFIG_OPTIONAL_WIFI} = "enabled" ]]; then
657 - IUSE+=" +wifi"
658 - else
659 - IUSE+=" wifi"
660 - fi
661 - RDEPEND+="
662 - wifi? ( >=sys-apps/dbus-0.60
663 - >=dev-libs/dbus-glib-0.72
664 - net-wireless/wireless-tools )"
665 -fi
666 -if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
667 - if [[ ${MOZCONFIG_OPTIONAL_JIT} = "enabled" ]]; then
668 - IUSE+=" +jit"
669 - else
670 - IUSE+=" jit"
671 - fi
672 -fi
673 -
674 -DEPEND="app-arch/zip
675 - app-arch/unzip
676 - >=sys-devel/binutils-2.16.1
677 - ${RDEPEND}"
678 -
679 -RDEPEND+="
680 - selinux? ( sec-policy/selinux-mozilla )"
681 -
682 -# only one of gstreamer and gstreamer-0 can be enabled at a time, so set REQUIRED_USE to signify this
683 -REQUIRED_USE="?? ( gstreamer gstreamer-0 )"
684 -
685 -# @FUNCTION: mozconfig_config
686 -# @DESCRIPTION:
687 -# Set common configure options for mozilla packages.
688 -# Call this within src_configure() phase, after mozconfig_init
689 -#
690 -# Example:
691 -#
692 -# inherit mozconfig-v5.33
693 -#
694 -# src_configure() {
695 -# mozconfig_init
696 -# mozconfig_config
697 -# # ... misc ebuild-unique settings via calls to
698 -# # ... mozconfig_{annotate,use_with,use_enable}
699 -# mozconfig_final
700 -# }
701 -
702 -mozconfig_config() {
703 - # Migrated from mozcoreconf-2
704 - mozconfig_annotate 'system_libs' \
705 - --with-system-zlib \
706 - --enable-pango \
707 - --enable-svg \
708 - --with-system-bz2
709 -
710 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
711 - mozconfig_annotate 'gtk3 use flag' --enable-default-toolkit=$(usex gtk3 cairo-gtk3 cairo-gtk2)
712 - else
713 - mozconfig_annotate '' --enable-default-toolkit=cairo-gtk2
714 - fi
715 -
716 - if has bindist ${IUSE}; then
717 - mozconfig_use_enable !bindist official-branding
718 - if [[ ${PN} == firefox ]] && use bindist ; then
719 - mozconfig_annotate '' --with-branding=browser/branding/aurora
720 - fi
721 - fi
722 -
723 - mozconfig_use_enable debug
724 - mozconfig_use_enable debug tests
725 -
726 - if ! use debug ; then
727 - mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
728 - else
729 - mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
730 - fi
731 -
732 - mozconfig_use_enable startup-notification
733 -
734 - if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]] ; then
735 - # wifi pulls in dbus so manage both here
736 - mozconfig_use_enable wifi necko-wifi
737 - if use wifi && ! use dbus; then
738 - echo "Enabling dbus support due to wifi request"
739 - mozconfig_annotate 'dbus required by necko-wifi' --enable-dbus
740 - else
741 - mozconfig_use_enable dbus
742 - fi
743 - else
744 - mozconfig_use_enable dbus
745 - mozconfig_annotate 'disabled' --disable-necko-wifi
746 - fi
747 -
748 - # These are forced-on for webm support
749 - mozconfig_annotate 'required' --enable-ogg
750 - mozconfig_annotate 'required' --enable-wave
751 -
752 - if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
753 - mozconfig_use_enable jit ion
754 - fi
755 -
756 - # These are enabled by default in all mozilla applications
757 - mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${EPREFIX}"/usr
758 - mozconfig_annotate '' --with-system-nss --with-nss-prefix="${EPREFIX}"/usr
759 - mozconfig_annotate '' --x-includes="${EPREFIX}"/usr/include --x-libraries="${EPREFIX}"/usr/$(get_libdir)
760 - mozconfig_annotate '' --with-system-libevent="${EPREFIX}"/usr
761 - mozconfig_annotate '' --prefix="${EPREFIX}"/usr
762 - mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
763 - mozconfig_annotate 'Gentoo default' --enable-system-hunspell
764 - mozconfig_annotate '' --disable-gnomevfs
765 - mozconfig_annotate '' --disable-gnomeui
766 - mozconfig_annotate '' --enable-gio
767 - mozconfig_annotate '' --disable-crashreporter
768 - mozconfig_annotate 'Gentoo default' --with-system-png
769 - mozconfig_annotate '' --enable-system-ffi
770 - mozconfig_annotate 'Gentoo default to honor system linker' --disable-gold
771 - mozconfig_annotate '' --disable-gconf
772 -
773 - # Use jemalloc unless libc is not glibc >= 2.4
774 - # at this time the minimum glibc in the tree is 2.9 so we should be safe.
775 - if use elibc_glibc && use jemalloc3; then
776 - # We must force-enable jemalloc 3 via .mozconfig
777 - echo "export MOZ_JEMALLOC3=1" >> "${S}"/.mozconfig || die
778 - mozconfig_annotate '' --enable-jemalloc
779 - mozconfig_annotate '' --enable-replace-malloc
780 - fi
781 -
782 - mozconfig_annotate '' --target="${CTARGET:-${CHOST}}"
783 - mozconfig_annotate '' --build="${CTARGET:-${CHOST}}"
784 -
785 - if use gstreamer ; then
786 - mozconfig_annotate '+gstreamer' --enable-gstreamer=1.0
787 - elif use gstreamer-0 ; then
788 - mozconfig_annotate '+gstreamer-0' --enable-gstreamer=0.10
789 - else
790 - mozconfig_annotate '' --disable-gstreamer
791 - fi
792 - mozconfig_use_enable pulseaudio
793 -
794 - mozconfig_use_enable system-cairo
795 - mozconfig_use_enable system-sqlite
796 - mozconfig_use_with system-jpeg
797 - mozconfig_use_with system-icu
798 - mozconfig_use_with system-icu intl-api
799 - mozconfig_use_with system-libvpx
800 -}
801
802 diff --git a/eclass/mozconfig-v6.42.eclass b/eclass/mozconfig-v6.42.eclass
803 deleted file mode 100644
804 index 29a75f9..0000000
805 --- a/eclass/mozconfig-v6.42.eclass
806 +++ /dev/null
807 @@ -1,282 +0,0 @@
808 -# Copyright 1999-2015 Gentoo Foundation
809 -# Distributed under the terms of the GNU General Public License v2
810 -# $Id$
811 -#
812 -# @ECLASS: mozconfig-v6.40.eclass
813 -# @MAINTAINER:
814 -# mozilla team <mozilla@g.o>
815 -# @BLURB: the new mozilla common configuration eclass for FF33 and newer, v6
816 -# @DESCRIPTION:
817 -# This eclass is used in mozilla ebuilds (firefox, thunderbird, seamonkey)
818 -# to provide a single common place for the common mozilla engine compoments.
819 -#
820 -# The eclass provides all common dependencies as well as common use flags.
821 -#
822 -# Some use flags which may be optional in particular mozilla packages can be
823 -# supported through setting eclass variables.
824 -#
825 -# This eclass inherits mozconfig helper functions as defined in mozcoreconf-v3,
826 -# and so ebuilds inheriting this eclass do not need to inherit that.
827 -
828 -inherit multilib flag-o-matic toolchain-funcs mozcoreconf-v3
829 -
830 -case ${EAPI} in
831 - 0|1|2|3|4) die "EAPI=${EAPI} not supported"
832 -esac
833 -
834 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_WIFI
835 -# @DESCRIPTION:
836 -# Set this variable before the inherit line, when an ebuild needs to provide
837 -# optional necko-wifi support via IUSE="wifi". Currently this would include
838 -# ebuilds for firefox, and potentially seamonkey.
839 -#
840 -# Leave the variable UNSET if necko-wifi support should not be available.
841 -# Set the variable to "enabled" if the use flag should be enabled by default.
842 -# Set the variable to any value if the use flag should exist but not be default-enabled.
843 -
844 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_JIT
845 -# @DESCRIPTION:
846 -# Set this variable before the inherit line, when an ebuild needs to provide
847 -# optional necko-wifi support via IUSE="jit". Currently this would include
848 -# ebuilds for firefox, and potentially seamonkey.
849 -#
850 -# Leave the variable UNSET if optional jit support should not be available.
851 -# Set the variable to "enabled" if the use flag should be enabled by default.
852 -# Set the variable to any value if the use flag should exist but not be default-enabled.
853 -
854 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK3
855 -# @DESCRIPTION:
856 -# Set this variable before the inherit line, when an ebuild can provide
857 -# optional gtk3 support via IUSE="gtk3". Currently this would include
858 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
859 -#
860 -# Leave the variable UNSET if gtk3 support should not be available.
861 -# Set the variable to "enabled" if the use flag should be enabled by default.
862 -# Set the variable to any value if the use flag should exist but not be default-enabled.
863 -
864 -# use-flags common among all mozilla ebuilds
865 -IUSE="${IUSE} dbus debug +gstreamer gstreamer-0 +jemalloc3 neon pulseaudio selinux startup-notification system-cairo system-icu system-jpeg system-sqlite system-libvpx"
866 -
867 -# some notes on deps:
868 -# gtk:2 minimum is technically 2.10 but gio support (enabled by default) needs 2.14
869 -# media-libs/mesa needs to be 10.2 or above due to a bug with flash+vdpau
870 -
871 -RDEPEND=">=app-text/hunspell-1.2:=
872 - dev-libs/atk
873 - dev-libs/expat
874 - >=dev-libs/libevent-1.4.7
875 - >=x11-libs/cairo-1.10[X]
876 - >=x11-libs/gtk+-2.18:2
877 - x11-libs/gdk-pixbuf
878 - >=x11-libs/pango-1.22.0
879 - >=media-libs/libpng-1.6.17:0=[apng]
880 - >=media-libs/mesa-10.2:*
881 - media-libs/fontconfig
882 - >=media-libs/freetype-2.4.10
883 - kernel_linux? ( media-libs/alsa-lib )
884 - pulseaudio? ( media-sound/pulseaudio )
885 - virtual/freedesktop-icon-theme
886 - dbus? ( >=sys-apps/dbus-0.60
887 - >=dev-libs/dbus-glib-0.72 )
888 - startup-notification? ( >=x11-libs/startup-notification-0.8 )
889 - >=dev-libs/glib-2.26:2
890 - >=sys-libs/zlib-1.2.3
891 - >=virtual/libffi-3.0.10
892 - gstreamer? (
893 - >=media-libs/gstreamer-1.4.5:1.0
894 - >=media-libs/gst-plugins-base-1.4.5:1.0
895 - >=media-libs/gst-plugins-good-1.4.5:1.0
896 - >=media-plugins/gst-plugins-libav-1.4.5:1.0
897 - )
898 - gstreamer-0? (
899 - >=media-libs/gstreamer-0.10.25:0.10
900 - media-plugins/gst-plugins-meta:0.10[ffmpeg]
901 - )
902 - x11-libs/libX11
903 - x11-libs/libXcomposite
904 - x11-libs/libXdamage
905 - x11-libs/libXext
906 - x11-libs/libXfixes
907 - x11-libs/libXrender
908 - x11-libs/libXt
909 - system-cairo? ( >=x11-libs/cairo-1.12[X,xcb] >=x11-libs/pixman-0.19.2 )
910 - system-icu? ( >=dev-libs/icu-51.1:= )
911 - system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
912 - system-sqlite? ( >=dev-db/sqlite-3.8.11.1:3[secure-delete,debug=] )
913 - system-libvpx? ( >=media-libs/libvpx-1.3.0:0=[postproc] )
914 -"
915 -
916 -if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
917 - if [[ ${MOZCONFIG_OPTIONAL_GTK3} = "enabled" ]]; then
918 - IUSE+=" +gtk3"
919 - else
920 - IUSE+=" gtk3"
921 - fi
922 - RDEPEND+="
923 - gtk3? ( >=x11-libs/gtk+-3.14.0:3 )"
924 -fi
925 -if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]]; then
926 - if [[ ${MOZCONFIG_OPTIONAL_WIFI} = "enabled" ]]; then
927 - IUSE+=" +wifi"
928 - else
929 - IUSE+=" wifi"
930 - fi
931 - RDEPEND+="
932 - wifi? (
933 - kernel_linux? ( >=sys-apps/dbus-0.60
934 - >=dev-libs/dbus-glib-0.72
935 - net-misc/networkmanager )
936 - )"
937 -fi
938 -if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
939 - if [[ ${MOZCONFIG_OPTIONAL_JIT} = "enabled" ]]; then
940 - IUSE+=" +jit"
941 - else
942 - IUSE+=" jit"
943 - fi
944 -fi
945 -
946 -DEPEND="app-arch/zip
947 - app-arch/unzip
948 - >=sys-devel/binutils-2.16.1
949 - ${RDEPEND}"
950 -
951 -RDEPEND+="
952 - selinux? ( sec-policy/selinux-mozilla )"
953 -
954 -# only one of gstreamer and gstreamer-0 can be enabled at a time, so set REQUIRED_USE to signify this
955 -REQUIRED_USE="?? ( gstreamer gstreamer-0 )"
956 -
957 -# @FUNCTION: mozconfig_config
958 -# @DESCRIPTION:
959 -# Set common configure options for mozilla packages.
960 -# Call this within src_configure() phase, after mozconfig_init
961 -#
962 -# Example:
963 -#
964 -# inherit mozconfig-v5.33
965 -#
966 -# src_configure() {
967 -# mozconfig_init
968 -# mozconfig_config
969 -# # ... misc ebuild-unique settings via calls to
970 -# # ... mozconfig_{annotate,use_with,use_enable}
971 -# mozconfig_final
972 -# }
973 -
974 -mozconfig_config() {
975 - # Migrated from mozcoreconf-2
976 - mozconfig_annotate 'system_libs' \
977 - --with-system-zlib \
978 - --enable-pango \
979 - --enable-svg \
980 - --with-system-bz2
981 -
982 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
983 - mozconfig_annotate 'gtk3 use flag' --enable-default-toolkit=$(usex gtk3 cairo-gtk3 cairo-gtk2)
984 - else
985 - mozconfig_annotate '' --enable-default-toolkit=cairo-gtk2
986 - fi
987 -
988 - if has bindist ${IUSE}; then
989 - mozconfig_use_enable !bindist official-branding
990 - if [[ ${PN} == firefox ]] && use bindist ; then
991 - mozconfig_annotate '' --with-branding=browser/branding/aurora
992 - fi
993 - fi
994 -
995 - mozconfig_use_enable debug
996 - mozconfig_use_enable debug tests
997 -
998 - if ! use debug ; then
999 - mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
1000 - else
1001 - mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
1002 - fi
1003 -
1004 - mozconfig_use_enable startup-notification
1005 -
1006 - if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]] ; then
1007 - # wifi pulls in dbus so manage both here
1008 - mozconfig_use_enable wifi necko-wifi
1009 - if use kernel_linux && use wifi && ! use dbus; then
1010 - echo "Enabling dbus support due to wifi request"
1011 - mozconfig_annotate 'dbus required by necko-wifi on linux' --enable-dbus
1012 - else
1013 - mozconfig_use_enable dbus
1014 - fi
1015 - else
1016 - mozconfig_use_enable dbus
1017 - mozconfig_annotate 'disabled' --disable-necko-wifi
1018 - fi
1019 -
1020 - # These are forced-on for webm support
1021 - mozconfig_annotate 'required' --enable-ogg
1022 - mozconfig_annotate 'required' --enable-wave
1023 -
1024 - if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
1025 - mozconfig_use_enable jit ion
1026 - fi
1027 -
1028 - # These are enabled by default in all mozilla applications
1029 - mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${EPREFIX}"/usr
1030 - mozconfig_annotate '' --with-system-nss --with-nss-prefix="${EPREFIX}"/usr
1031 - mozconfig_annotate '' --x-includes="${EPREFIX}"/usr/include --x-libraries="${EPREFIX}"/usr/$(get_libdir)
1032 - mozconfig_annotate '' --with-system-libevent="${EPREFIX}"/usr
1033 - mozconfig_annotate '' --prefix="${EPREFIX}"/usr
1034 - mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
1035 - mozconfig_annotate 'Gentoo default' --enable-system-hunspell
1036 - mozconfig_annotate '' --disable-gnomevfs
1037 - mozconfig_annotate '' --disable-gnomeui
1038 - mozconfig_annotate '' --enable-gio
1039 - mozconfig_annotate '' --disable-crashreporter
1040 - mozconfig_annotate 'Gentoo default' --with-system-png
1041 - mozconfig_annotate '' --enable-system-ffi
1042 - mozconfig_annotate 'Gentoo default to honor system linker' --disable-gold
1043 - mozconfig_annotate 'Gentoo default' --disable-skia
1044 - mozconfig_annotate '' --disable-gconf
1045 - mozconfig_annotate '' --with-intl-api
1046 -
1047 - # Use jemalloc unless libc is not glibc >= 2.4
1048 - # at this time the minimum glibc in the tree is 2.9 so we should be safe.
1049 - if use elibc_glibc && use jemalloc3; then
1050 - # We must force-enable jemalloc 3 via .mozconfig
1051 - echo "export MOZ_JEMALLOC3=1" >> "${S}"/.mozconfig || die
1052 - mozconfig_annotate '' --enable-jemalloc
1053 - mozconfig_annotate '' --enable-replace-malloc
1054 - fi
1055 -
1056 - mozconfig_annotate '' --target="${CTARGET:-${CHOST}}"
1057 - mozconfig_annotate '' --build="${CTARGET:-${CHOST}}"
1058 -
1059 - if use gstreamer ; then
1060 - mozconfig_annotate '+gstreamer' --enable-gstreamer=1.0
1061 - elif use gstreamer-0 ; then
1062 - mozconfig_annotate '+gstreamer-0' --enable-gstreamer=0.10
1063 - else
1064 - mozconfig_annotate '' --disable-gstreamer
1065 - fi
1066 - mozconfig_use_enable pulseaudio
1067 -
1068 - mozconfig_use_enable system-cairo
1069 - mozconfig_use_enable system-sqlite
1070 - mozconfig_use_with system-jpeg
1071 - mozconfig_use_with system-icu
1072 - mozconfig_use_with system-libvpx
1073 -
1074 - # Modifications to better support ARM, bug 553364
1075 - if use neon ; then
1076 - mozconfig_annotate '' --with-fpu=neon
1077 - mozconfig_annotate '' --with-thumb=yes
1078 - mozconfig_annotate '' --with-thumb-interwork=no
1079 - fi
1080 - if [[ ${CHOST} == armv* ]] ; then
1081 - mozconfig_annotate '' --with-float-abi=hard
1082 - mozconfig_annotate '' --enable-skia
1083 -
1084 - if ! use system-libvpx ; then
1085 - sed -i -e "s|softfp|hard|" \
1086 - "${S}"/media/libvpx/moz.build
1087 - fi
1088 - fi
1089 -}
1090
1091 diff --git a/eclass/mozconfig-v6.44.eclass b/eclass/mozconfig-v6.44.eclass
1092 deleted file mode 100644
1093 index 275f1a5..0000000
1094 --- a/eclass/mozconfig-v6.44.eclass
1095 +++ /dev/null
1096 @@ -1,340 +0,0 @@
1097 -# Copyright 1999-2015 Gentoo Foundation
1098 -# Distributed under the terms of the GNU General Public License v2
1099 -# $Id$
1100 -#
1101 -# @ECLASS: mozconfig-v6.40.eclass
1102 -# @MAINTAINER:
1103 -# mozilla team <mozilla@g.o>
1104 -# @BLURB: the new mozilla common configuration eclass for FF33 and newer, v6
1105 -# @DESCRIPTION:
1106 -# This eclass is used in mozilla ebuilds (firefox, thunderbird, seamonkey)
1107 -# to provide a single common place for the common mozilla engine compoments.
1108 -#
1109 -# The eclass provides all common dependencies as well as common use flags.
1110 -#
1111 -# Some use flags which may be optional in particular mozilla packages can be
1112 -# supported through setting eclass variables.
1113 -#
1114 -# This eclass inherits mozconfig helper functions as defined in mozcoreconf-v3,
1115 -# and so ebuilds inheriting this eclass do not need to inherit that.
1116 -
1117 -inherit multilib flag-o-matic toolchain-funcs mozcoreconf-v3
1118 -
1119 -case ${EAPI} in
1120 - 0|1|2|3|4) die "EAPI=${EAPI} not supported"
1121 -esac
1122 -
1123 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_WIFI
1124 -# @DESCRIPTION:
1125 -# Set this variable before the inherit line, when an ebuild needs to provide
1126 -# optional necko-wifi support via IUSE="wifi". Currently this would include
1127 -# ebuilds for firefox, and potentially seamonkey.
1128 -#
1129 -# Leave the variable UNSET if necko-wifi support should not be available.
1130 -# Set the variable to "enabled" if the use flag should be enabled by default.
1131 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1132 -
1133 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_JIT
1134 -# @DESCRIPTION:
1135 -# Set this variable before the inherit line, when an ebuild needs to provide
1136 -# optional necko-wifi support via IUSE="jit". Currently this would include
1137 -# ebuilds for firefox, and potentially seamonkey.
1138 -#
1139 -# Leave the variable UNSET if optional jit support should not be available.
1140 -# Set the variable to "enabled" if the use flag should be enabled by default.
1141 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1142 -
1143 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK3
1144 -# @DESCRIPTION:
1145 -# Set this variable before the inherit line, when an ebuild can provide
1146 -# optional gtk3 support via IUSE="gtk3". Currently this would include
1147 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
1148 -#
1149 -# Leave the variable UNSET if gtk3 support should not be available.
1150 -# Set the variable to "enabled" if the use flag should be enabled by default.
1151 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1152 -
1153 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_QT5
1154 -# @DESCRIPTION:
1155 -# Set this variable before the inherit line, when an ebuild can provide
1156 -# optional qt5 support via IUSE="qt5". Currently this would include
1157 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
1158 -#
1159 -# Leave the variable UNSET if qt5 support should not be available.
1160 -# Set the variable to "enabled" if the use flag should be enabled by default.
1161 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1162 -
1163 -# use-flags common among all mozilla ebuilds
1164 -IUSE="${IUSE} dbus debug ffmpeg +gstreamer gstreamer-0 +jemalloc3 neon pulseaudio selinux startup-notification system-cairo
1165 - system-icu system-jpeg system-libevent system-sqlite system-libvpx"
1166 -
1167 -# some notes on deps:
1168 -# gtk:2 minimum is technically 2.10 but gio support (enabled by default) needs 2.14
1169 -# media-libs/mesa needs to be 10.2 or above due to a bug with flash+vdpau
1170 -
1171 -RDEPEND=">=app-text/hunspell-1.2:=
1172 - dev-libs/atk
1173 - dev-libs/expat
1174 - >=x11-libs/cairo-1.10[X]
1175 - >=x11-libs/gtk+-2.18:2
1176 - x11-libs/gdk-pixbuf
1177 - >=x11-libs/pango-1.22.0
1178 - >=media-libs/libpng-1.6.17:0=[apng]
1179 - >=media-libs/mesa-10.2:*
1180 - media-libs/fontconfig
1181 - >=media-libs/freetype-2.4.10
1182 - kernel_linux? ( media-libs/alsa-lib )
1183 - pulseaudio? ( media-sound/pulseaudio )
1184 - virtual/freedesktop-icon-theme
1185 - dbus? ( >=sys-apps/dbus-0.60
1186 - >=dev-libs/dbus-glib-0.72 )
1187 - startup-notification? ( >=x11-libs/startup-notification-0.8 )
1188 - >=dev-libs/glib-2.26:2
1189 - >=sys-libs/zlib-1.2.3
1190 - >=virtual/libffi-3.0.10
1191 - ffmpeg? ( virtual/ffmpeg )
1192 - gstreamer? (
1193 - >=media-libs/gstreamer-1.4.5:1.0
1194 - >=media-libs/gst-plugins-base-1.4.5:1.0
1195 - >=media-libs/gst-plugins-good-1.4.5:1.0
1196 - >=media-plugins/gst-plugins-libav-1.4.5:1.0
1197 - )
1198 - gstreamer-0? (
1199 - >=media-libs/gstreamer-0.10.25:0.10
1200 - media-plugins/gst-plugins-meta:0.10[ffmpeg]
1201 - )
1202 - x11-libs/libX11
1203 - x11-libs/libXcomposite
1204 - x11-libs/libXdamage
1205 - x11-libs/libXext
1206 - x11-libs/libXfixes
1207 - x11-libs/libXrender
1208 - x11-libs/libXt
1209 - system-cairo? ( >=x11-libs/cairo-1.12[X,xcb] >=x11-libs/pixman-0.19.2 )
1210 - system-icu? ( >=dev-libs/icu-51.1:= )
1211 - system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
1212 - system-libevent? ( =dev-libs/libevent-2.0*:0= )
1213 - system-sqlite? ( >=dev-db/sqlite-3.9.1:3[secure-delete,debug=] )
1214 - system-libvpx? ( >=media-libs/libvpx-1.3.0:0=[postproc] )
1215 -"
1216 -
1217 -if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
1218 - if [[ ${MOZCONFIG_OPTIONAL_GTK3} = "enabled" ]]; then
1219 - IUSE+=" +gtk3"
1220 - else
1221 - IUSE+=" gtk3"
1222 - fi
1223 - RDEPEND+="
1224 - gtk3? ( >=x11-libs/gtk+-3.4.0:3 )"
1225 -fi
1226 -if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
1227 - inherit qmake-utils
1228 - if [[ ${MOZCONFIG_OPTIONAL_QT5} = "enabled" ]]; then
1229 - IUSE+=" +qt5"
1230 - else
1231 - IUSE+=" qt5"
1232 - fi
1233 - RDEPEND+="
1234 - qt5? (
1235 - dev-qt/qtcore:5
1236 - dev-qt/qtgui:5
1237 - dev-qt/qtnetwork:5
1238 - dev-qt/qtprintsupport:5
1239 - dev-qt/qtwidgets:5
1240 - dev-qt/qtxml:5
1241 - dev-qt/qtdeclarative:5
1242 - )"
1243 -fi
1244 -if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]]; then
1245 - if [[ ${MOZCONFIG_OPTIONAL_WIFI} = "enabled" ]]; then
1246 - IUSE+=" +wifi"
1247 - else
1248 - IUSE+=" wifi"
1249 - fi
1250 - RDEPEND+="
1251 - wifi? (
1252 - kernel_linux? ( >=sys-apps/dbus-0.60
1253 - >=dev-libs/dbus-glib-0.72
1254 - net-misc/networkmanager )
1255 - )"
1256 -fi
1257 -if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
1258 - if [[ ${MOZCONFIG_OPTIONAL_JIT} = "enabled" ]]; then
1259 - IUSE+=" +jit"
1260 - else
1261 - IUSE+=" jit"
1262 - fi
1263 -fi
1264 -
1265 -DEPEND="app-arch/zip
1266 - app-arch/unzip
1267 - >=sys-devel/binutils-2.16.1
1268 - ${RDEPEND}"
1269 -
1270 -RDEPEND+="
1271 - selinux? ( sec-policy/selinux-mozilla )"
1272 -
1273 -# only one of gstreamer and gstreamer-0 can be enabled at a time, so set REQUIRED_USE to signify this
1274 -REQUIRED_USE="?? ( gstreamer gstreamer-0 )"
1275 -
1276 -# only one of gtk3 or qt5 should be permitted to be selected, since only one will be used.
1277 -[[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]] && [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]] && \
1278 - REQUIRED_USE+=" ?? ( gtk3 qt5 )"
1279 -
1280 -# @FUNCTION: mozconfig_config
1281 -# @DESCRIPTION:
1282 -# Set common configure options for mozilla packages.
1283 -# Call this within src_configure() phase, after mozconfig_init
1284 -#
1285 -# Example:
1286 -#
1287 -# inherit mozconfig-v5.33
1288 -#
1289 -# src_configure() {
1290 -# mozconfig_init
1291 -# mozconfig_config
1292 -# # ... misc ebuild-unique settings via calls to
1293 -# # ... mozconfig_{annotate,use_with,use_enable}
1294 -# mozconfig_final
1295 -# }
1296 -
1297 -mozconfig_config() {
1298 - # Migrated from mozcoreconf-2
1299 - mozconfig_annotate 'system_libs' \
1300 - --with-system-zlib \
1301 - --enable-pango \
1302 - --enable-svg \
1303 - --with-system-bz2
1304 -
1305 - if has bindist ${IUSE}; then
1306 - mozconfig_use_enable !bindist official-branding
1307 - if [[ ${PN} == firefox ]] && use bindist ; then
1308 - mozconfig_annotate '' --with-branding=browser/branding/aurora
1309 - fi
1310 - fi
1311 -
1312 - mozconfig_use_enable debug
1313 - mozconfig_use_enable debug tests
1314 -
1315 - if ! use debug ; then
1316 - mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
1317 - else
1318 - mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
1319 - fi
1320 -
1321 - mozconfig_use_enable startup-notification
1322 -
1323 - if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]] ; then
1324 - # wifi pulls in dbus so manage both here
1325 - mozconfig_use_enable wifi necko-wifi
1326 - if use kernel_linux && use wifi && ! use dbus; then
1327 - echo "Enabling dbus support due to wifi request"
1328 - mozconfig_annotate 'dbus required by necko-wifi on linux' --enable-dbus
1329 - else
1330 - mozconfig_use_enable dbus
1331 - fi
1332 - else
1333 - mozconfig_use_enable dbus
1334 - mozconfig_annotate 'disabled' --disable-necko-wifi
1335 - fi
1336 -
1337 - # These are forced-on for webm support
1338 - mozconfig_annotate 'required' --enable-ogg
1339 - mozconfig_annotate 'required' --enable-wave
1340 -
1341 - if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
1342 - mozconfig_use_enable jit ion
1343 - fi
1344 -
1345 - # These are enabled by default in all mozilla applications
1346 - mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${EPREFIX}"/usr
1347 - mozconfig_annotate '' --with-system-nss --with-nss-prefix="${EPREFIX}"/usr
1348 - mozconfig_annotate '' --x-includes="${EPREFIX}"/usr/include --x-libraries="${EPREFIX}"/usr/$(get_libdir)
1349 - if use system-libevent; then
1350 - mozconfig_annotate '' --with-system-libevent="${EPREFIX}"/usr
1351 - fi
1352 - mozconfig_annotate '' --prefix="${EPREFIX}"/usr
1353 - mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
1354 - mozconfig_annotate 'Gentoo default' --enable-system-hunspell
1355 - mozconfig_annotate '' --disable-gnomeui
1356 - mozconfig_annotate '' --enable-gio
1357 - mozconfig_annotate '' --disable-crashreporter
1358 - mozconfig_annotate 'Gentoo default' --with-system-png
1359 - mozconfig_annotate '' --enable-system-ffi
1360 - mozconfig_annotate 'Gentoo default to honor system linker' --disable-gold
1361 - mozconfig_annotate 'Gentoo default' --disable-skia
1362 - mozconfig_annotate '' --disable-gconf
1363 - mozconfig_annotate '' --with-intl-api
1364 -
1365 - # default toolkit is cairo-gtk2, optional use flags can change this
1366 - local toolkit="cairo-gtk2"
1367 - local toolkit_comment=""
1368 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
1369 - if use gtk3; then
1370 - toolkit="cairo-gtk3"
1371 - toolkit_comment="gtk3 use flag"
1372 - fi
1373 - fi
1374 - if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
1375 - if use qt5; then
1376 - toolkit="cairo-qt"
1377 - toolkit_comment="qt5 use flag"
1378 - # need to specify these vars because the qt5 versions are not found otherwise,
1379 - # and setting --with-qtdir overrides the pkg-config include dirs
1380 - local i
1381 - for i in qmake moc rcc; do
1382 - echo "export HOST_${i^^}=\"$(qt5_get_bindir)/${i}\"" \
1383 - >> "${S}"/.mozconfig || die
1384 - done
1385 - echo 'unset QTDIR' >> "${S}"/.mozconfig || die
1386 - mozconfig_annotate '+qt5' --disable-gio
1387 - fi
1388 - fi
1389 - mozconfig_annotate "${toolkit_comment}" --enable-default-toolkit=${toolkit}
1390 -
1391 - # Use jemalloc unless libc is not glibc >= 2.4
1392 - # at this time the minimum glibc in the tree is 2.9 so we should be safe.
1393 - if use elibc_glibc && use jemalloc3; then
1394 - # We must force-enable jemalloc 3 via .mozconfig
1395 - echo "export MOZ_JEMALLOC3=1" >> "${S}"/.mozconfig || die
1396 - mozconfig_annotate '' --enable-jemalloc
1397 - mozconfig_annotate '' --enable-replace-malloc
1398 - fi
1399 -
1400 - mozconfig_annotate '' --target="${CTARGET:-${CHOST}}"
1401 - mozconfig_annotate '' --build="${CTARGET:-${CHOST}}"
1402 -
1403 - use ffmpeg || mozconfig_annotate '-ffmpeg' --disable-ffmpeg
1404 - if use gstreamer ; then
1405 - use ffmpeg && einfo "${PN} will not use ffmpeg unless gstreamer:1.0 is not available at runtime"
1406 - mozconfig_annotate '+gstreamer' --enable-gstreamer=1.0
1407 - elif use gstreamer-0 ; then
1408 - use ffmpeg && einfo "${PN} will not use ffmpeg unless gstreamer:0.10 is not available at runtime"
1409 - mozconfig_annotate '+gstreamer-0' --enable-gstreamer=0.10
1410 - else
1411 - mozconfig_annotate '' --disable-gstreamer
1412 - fi
1413 - mozconfig_use_enable pulseaudio
1414 -
1415 - mozconfig_use_enable system-cairo
1416 - mozconfig_use_enable system-sqlite
1417 - mozconfig_use_with system-jpeg
1418 - mozconfig_use_with system-icu
1419 - mozconfig_use_with system-libvpx
1420 -
1421 - # Modifications to better support ARM, bug 553364
1422 - if use neon ; then
1423 - mozconfig_annotate '' --with-fpu=neon
1424 - mozconfig_annotate '' --with-thumb=yes
1425 - mozconfig_annotate '' --with-thumb-interwork=no
1426 - fi
1427 - if [[ ${CHOST} == armv* ]] ; then
1428 - mozconfig_annotate '' --with-float-abi=hard
1429 - mozconfig_annotate '' --enable-skia
1430 -
1431 - if ! use system-libvpx ; then
1432 - sed -i -e "s|softfp|hard|" \
1433 - "${S}"/media/libvpx/moz.build
1434 - fi
1435 - fi
1436 -}
1437
1438 diff --git a/eclass/mozconfig-v6.46.eclass b/eclass/mozconfig-v6.46.eclass
1439 deleted file mode 100644
1440 index 1cdf881..0000000
1441 --- a/eclass/mozconfig-v6.46.eclass
1442 +++ /dev/null
1443 @@ -1,408 +0,0 @@
1444 -# Copyright 1999-2015 Gentoo Foundation
1445 -# Distributed under the terms of the GNU General Public License v2
1446 -# $Id$
1447 -#
1448 -# @ECLASS: mozconfig-v6.46.eclass
1449 -# @MAINTAINER:
1450 -# mozilla team <mozilla@g.o>
1451 -# @BLURB: the new mozilla common configuration eclass for FF33 and newer, v6
1452 -# @DESCRIPTION:
1453 -# This eclass is used in mozilla ebuilds (firefox, thunderbird, seamonkey)
1454 -# to provide a single common place for the common mozilla engine compoments.
1455 -#
1456 -# The eclass provides all common dependencies as well as common use flags.
1457 -#
1458 -# Some use flags which may be optional in particular mozilla packages can be
1459 -# supported through setting eclass variables.
1460 -#
1461 -# This eclass inherits mozconfig helper functions as defined in mozcoreconf-v3,
1462 -# and so ebuilds inheriting this eclass do not need to inherit that.
1463 -
1464 -case ${EAPI} in
1465 - 0|1|2|3|4)
1466 - die "EAPI=${EAPI} not supported"
1467 - ;;
1468 - 5)
1469 - inherit multilib
1470 - ;;
1471 -esac
1472 -
1473 -inherit flag-o-matic toolchain-funcs mozcoreconf-v4
1474 -
1475 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_WIFI
1476 -# @DESCRIPTION:
1477 -# Set this variable before the inherit line, when an ebuild needs to provide
1478 -# optional necko-wifi support via IUSE="wifi". Currently this would include
1479 -# ebuilds for firefox, and potentially seamonkey.
1480 -#
1481 -# Leave the variable UNSET if necko-wifi support should not be available.
1482 -# Set the variable to "enabled" if the use flag should be enabled by default.
1483 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1484 -
1485 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_JIT
1486 -# @DESCRIPTION:
1487 -# Set this variable before the inherit line, when an ebuild needs to provide
1488 -# optional necko-wifi support via IUSE="jit". Currently this would include
1489 -# ebuilds for firefox, and potentially seamonkey.
1490 -#
1491 -# Leave the variable UNSET if optional jit support should not be available.
1492 -# Set the variable to "enabled" if the use flag should be enabled by default.
1493 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1494 -
1495 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK3
1496 -# @DESCRIPTION:
1497 -# Set this variable before the inherit line, when an ebuild can provide
1498 -# optional gtk3 support via IUSE="gtk3". Currently this would include
1499 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
1500 -#
1501 -# Leave the variable UNSET if gtk3 support should not be available.
1502 -# Set the variable to "enabled" if the use flag should be enabled by default.
1503 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1504 -
1505 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK2ONLY
1506 -# @DESCRIPTION:
1507 -# Set this variable before the inherit line, when an ebuild can provide
1508 -# optional gtk2-only support via IUSE="gtk2".
1509 -#
1510 -# Note that this option conflicts directly with MOZCONFIG_OPTIONAL_GTK3, both
1511 -# variables cannot be set at the same time and this variable will be ignored if
1512 -# MOZCONFIG_OPTIONAL_GTK3 is set.
1513 -#
1514 -# Leave the variable UNSET if gtk2-only support should not be available.
1515 -# Set the variable to "enabled" if the use flag should be enabled by default.
1516 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1517 -
1518 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_QT5
1519 -# @DESCRIPTION:
1520 -# Set this variable before the inherit line, when an ebuild can provide
1521 -# optional qt5 support via IUSE="qt5". Currently this would include
1522 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
1523 -#
1524 -# Leave the variable UNSET if qt5 support should not be available.
1525 -# Set the variable to "enabled" if the use flag should be enabled by default.
1526 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1527 -
1528 -# use-flags common among all mozilla ebuilds
1529 -IUSE="${IUSE} dbus debug +ffmpeg +jemalloc3 neon pulseaudio selinux startup-notification system-cairo
1530 - system-harfbuzz system-icu system-jpeg system-libevent system-sqlite system-libvpx"
1531 -
1532 -# some notes on deps:
1533 -# gtk:2 minimum is technically 2.10 but gio support (enabled by default) needs 2.14
1534 -# media-libs/mesa needs to be 10.2 or above due to a bug with flash+vdpau
1535 -
1536 -RDEPEND=">=app-text/hunspell-1.2:=
1537 - dev-libs/atk
1538 - dev-libs/expat
1539 - >=x11-libs/cairo-1.10[X]
1540 - >=x11-libs/gtk+-2.18:2
1541 - x11-libs/gdk-pixbuf
1542 - >=x11-libs/pango-1.22.0
1543 - >=media-libs/libpng-1.6.19:0=[apng]
1544 - >=media-libs/mesa-10.2:*
1545 - media-libs/fontconfig
1546 - >=media-libs/freetype-2.4.10
1547 - kernel_linux? ( media-libs/alsa-lib )
1548 - pulseaudio? ( media-sound/pulseaudio )
1549 - virtual/freedesktop-icon-theme
1550 - dbus? ( >=sys-apps/dbus-0.60
1551 - >=dev-libs/dbus-glib-0.72 )
1552 - startup-notification? ( >=x11-libs/startup-notification-0.8 )
1553 - >=dev-libs/glib-2.26:2
1554 - >=sys-libs/zlib-1.2.3
1555 - >=virtual/libffi-3.0.10
1556 - ffmpeg? ( virtual/ffmpeg )
1557 - x11-libs/libX11
1558 - x11-libs/libXcomposite
1559 - x11-libs/libXdamage
1560 - x11-libs/libXext
1561 - x11-libs/libXfixes
1562 - x11-libs/libXrender
1563 - x11-libs/libXt
1564 - system-cairo? ( >=x11-libs/cairo-1.12[X,xcb] >=x11-libs/pixman-0.19.2 )
1565 - system-icu? ( >=dev-libs/icu-51.1:= )
1566 - system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
1567 - system-libevent? ( =dev-libs/libevent-2.0*:0= )
1568 - system-sqlite? ( >=dev-db/sqlite-3.10.2:3[secure-delete,debug=] )
1569 - system-libvpx? ( >=media-libs/libvpx-1.5.0:0=[postproc,svc(-)] )
1570 - system-harfbuzz? ( >=media-libs/harfbuzz-1.1.3:0=[graphite,icu] >=media-gfx/graphite2-1.3.8 )
1571 -"
1572 -
1573 -if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
1574 - MOZCONFIG_OPTIONAL_GTK2ONLY=
1575 - if [[ ${MOZCONFIG_OPTIONAL_GTK3} = "enabled" ]]; then
1576 - IUSE+=" +gtk3"
1577 - else
1578 - IUSE+=" gtk3"
1579 - fi
1580 - RDEPEND+="
1581 - gtk3? ( >=x11-libs/gtk+-3.4.0:3 )"
1582 -elif [[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]]; then
1583 - if [[ ${MOZCONFIG_OPTIONAL_GTK2ONLY} = "enabled" ]]; then
1584 - IUSE+=" +gtk2"
1585 - else
1586 - IUSE+=" gtk2"
1587 - fi
1588 - RDEPEND+="
1589 - !gtk2? ( >=x11-libs/gtk+-3.4.0:3 )"
1590 -fi
1591 -if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
1592 - inherit qmake-utils
1593 - if [[ ${MOZCONFIG_OPTIONAL_QT5} = "enabled" ]]; then
1594 - IUSE+=" +qt5"
1595 - else
1596 - IUSE+=" qt5"
1597 - fi
1598 - RDEPEND+="
1599 - qt5? (
1600 - dev-qt/qtcore:5
1601 - dev-qt/qtgui:5
1602 - dev-qt/qtnetwork:5
1603 - dev-qt/qtprintsupport:5
1604 - dev-qt/qtwidgets:5
1605 - dev-qt/qtxml:5
1606 - dev-qt/qtdeclarative:5
1607 - )"
1608 -fi
1609 -if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]]; then
1610 - if [[ ${MOZCONFIG_OPTIONAL_WIFI} = "enabled" ]]; then
1611 - IUSE+=" +wifi"
1612 - else
1613 - IUSE+=" wifi"
1614 - fi
1615 - RDEPEND+="
1616 - wifi? (
1617 - kernel_linux? ( >=sys-apps/dbus-0.60
1618 - >=dev-libs/dbus-glib-0.72
1619 - net-misc/networkmanager )
1620 - )"
1621 -fi
1622 -if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
1623 - if [[ ${MOZCONFIG_OPTIONAL_JIT} = "enabled" ]]; then
1624 - IUSE+=" +jit"
1625 - else
1626 - IUSE+=" jit"
1627 - fi
1628 -fi
1629 -
1630 -DEPEND="app-arch/zip
1631 - app-arch/unzip
1632 - >=sys-devel/binutils-2.16.1
1633 - ${RDEPEND}"
1634 -
1635 -RDEPEND+="
1636 - selinux? ( sec-policy/selinux-mozilla )"
1637 -
1638 -# force system-icu if system-harfbuzz is selected, to avoid potential ABI issues
1639 -REQUIRED_USE="
1640 - system-harfbuzz? ( system-icu )"
1641 -
1642 -# only one of gtk3 or qt5 should be permitted to be selected, since only one will be used.
1643 -[[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]] && [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]] && \
1644 - REQUIRED_USE+=" ?? ( gtk3 qt5 )"
1645 -
1646 -# only one of gtk2 or qt5 should be permitted to be selected, since only one will be used.
1647 -[[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]] && [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]] && \
1648 - REQUIRED_USE+=" ?? ( gtk2 qt5 )"
1649 -
1650 -# @FUNCTION: mozconfig_config
1651 -# @DESCRIPTION:
1652 -# Set common configure options for mozilla packages.
1653 -# Call this within src_configure() phase, after mozconfig_init
1654 -#
1655 -# Example:
1656 -#
1657 -# inherit mozconfig-v6.46
1658 -#
1659 -# src_configure() {
1660 -# mozconfig_init
1661 -# mozconfig_config
1662 -# # ... misc ebuild-unique settings via calls to
1663 -# # ... mozconfig_{annotate,use_with,use_enable}
1664 -# mozconfig_final
1665 -# }
1666 -
1667 -mozconfig_config() {
1668 - # Migrated from mozcoreconf-2
1669 - mozconfig_annotate 'system_libs' \
1670 - --with-system-zlib \
1671 - --enable-pango \
1672 - --enable-svg \
1673 - --with-system-bz2
1674 -
1675 - if has bindist ${IUSE}; then
1676 - mozconfig_use_enable !bindist official-branding
1677 - if [[ ${PN} == firefox ]] && use bindist ; then
1678 - mozconfig_annotate '' --with-branding=browser/branding/aurora
1679 - fi
1680 - fi
1681 -
1682 - mozconfig_use_enable debug
1683 - mozconfig_use_enable debug tests
1684 -
1685 - if ! use debug ; then
1686 - mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
1687 - else
1688 - mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
1689 - fi
1690 -
1691 - mozconfig_use_enable startup-notification
1692 -
1693 - if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]] ; then
1694 - # wifi pulls in dbus so manage both here
1695 - mozconfig_use_enable wifi necko-wifi
1696 - if use kernel_linux && use wifi && ! use dbus; then
1697 - echo "Enabling dbus support due to wifi request"
1698 - mozconfig_annotate 'dbus required by necko-wifi on linux' --enable-dbus
1699 - else
1700 - mozconfig_use_enable dbus
1701 - fi
1702 - else
1703 - mozconfig_use_enable dbus
1704 - mozconfig_annotate 'disabled' --disable-necko-wifi
1705 - fi
1706 -
1707 - # These are forced-on for webm support
1708 - mozconfig_annotate 'required' --enable-ogg
1709 - mozconfig_annotate 'required' --enable-wave
1710 -
1711 - if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
1712 - mozconfig_use_enable jit ion
1713 - fi
1714 -
1715 - # These are enabled by default in all mozilla applications
1716 - mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${SYSROOT}${EPREFIX}"/usr
1717 - mozconfig_annotate '' --with-system-nss --with-nss-prefix="${SYSROOT}${EPREFIX}"/usr
1718 - mozconfig_annotate '' --x-includes="${SYSROOT}${EPREFIX}"/usr/include --x-libraries="${SYSROOT}${EPREFIX}"/usr/$(get_libdir)
1719 - if use system-libevent; then
1720 - mozconfig_annotate '' --with-system-libevent="${SYSROOT}${EPREFIX}"/usr
1721 - fi
1722 - mozconfig_annotate '' --prefix="${EPREFIX}"/usr
1723 - mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
1724 - mozconfig_annotate 'Gentoo default' --enable-system-hunspell
1725 - mozconfig_annotate '' --disable-gnomeui
1726 - mozconfig_annotate '' --enable-gio
1727 - mozconfig_annotate '' --disable-crashreporter
1728 - mozconfig_annotate 'Gentoo default' --with-system-png
1729 - mozconfig_annotate '' --enable-system-ffi
1730 - mozconfig_annotate 'Gentoo default to honor system linker' --disable-gold
1731 - mozconfig_annotate 'Gentoo default' --disable-skia
1732 - mozconfig_annotate '' --disable-gconf
1733 - mozconfig_annotate '' --with-intl-api
1734 -
1735 - # default toolkit is cairo-gtk2, optional use flags can change this
1736 - local toolkit="cairo-gtk2"
1737 - local toolkit_comment=""
1738 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
1739 - if use gtk3; then
1740 - toolkit="cairo-gtk3"
1741 - toolkit_comment="gtk3 use flag"
1742 - fi
1743 - fi
1744 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]]; then
1745 - if ! use gtk2 ; then
1746 - toolkit="cairo-gtk3"
1747 - else
1748 - toolkit_comment="gtk2 use flag"
1749 - fi
1750 - fi
1751 - if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
1752 - if use qt5; then
1753 - toolkit="cairo-qt"
1754 - toolkit_comment="qt5 use flag"
1755 - # need to specify these vars because the qt5 versions are not found otherwise,
1756 - # and setting --with-qtdir overrides the pkg-config include dirs
1757 - local i
1758 - for i in qmake moc rcc; do
1759 - echo "export HOST_${i^^}=\"$(qt5_get_bindir)/${i}\"" \
1760 - >> "${S}"/.mozconfig || die
1761 - done
1762 - echo 'unset QTDIR' >> "${S}"/.mozconfig || die
1763 - mozconfig_annotate '+qt5' --disable-gio
1764 - fi
1765 - fi
1766 - mozconfig_annotate "${toolkit_comment}" --enable-default-toolkit=${toolkit}
1767 -
1768 - # Use jemalloc unless libc is not glibc >= 2.4
1769 - # at this time the minimum glibc in the tree is 2.9 so we should be safe.
1770 - if use elibc_glibc && use jemalloc3; then
1771 - # We must force-enable jemalloc 3 via .mozconfig
1772 - echo "export MOZ_JEMALLOC3=1" >> "${S}"/.mozconfig || die
1773 - mozconfig_annotate '' --enable-jemalloc
1774 - mozconfig_annotate '' --enable-replace-malloc
1775 - fi
1776 -
1777 - # Instead of the standard --build= and --host=, mozilla uses --host instead
1778 - # of --build, and --target intstead of --host.
1779 - # Note, mozilla also has --build but it does not do what you think it does.
1780 - # Set both --target and --host as mozilla uses python to guess values otherwise
1781 - mozconfig_annotate '' --target="${CHOST}"
1782 - mozconfig_annotate '' --host="${CBUILD:-${CHOST}}"
1783 -
1784 - use ffmpeg || mozconfig_annotate '-ffmpeg' --disable-ffmpeg
1785 - mozconfig_use_enable pulseaudio
1786 -
1787 - mozconfig_use_enable system-cairo
1788 - mozconfig_use_enable system-sqlite
1789 - mozconfig_use_with system-jpeg
1790 - mozconfig_use_with system-icu
1791 - mozconfig_use_with system-libvpx
1792 - mozconfig_use_with system-harfbuzz
1793 - mozconfig_use_with system-harfbuzz system-graphite2
1794 -
1795 - # Modifications to better support ARM, bug 553364
1796 - if use neon ; then
1797 - mozconfig_annotate '' --with-fpu=neon
1798 - mozconfig_annotate '' --with-thumb=yes
1799 - mozconfig_annotate '' --with-thumb-interwork=no
1800 - fi
1801 - if [[ ${CHOST} == armv* ]] ; then
1802 - mozconfig_annotate '' --with-float-abi=hard
1803 - mozconfig_annotate '' --enable-skia
1804 -
1805 - if ! use system-libvpx ; then
1806 - sed -i -e "s|softfp|hard|" \
1807 - "${S}"/media/libvpx/moz.build
1808 - fi
1809 - fi
1810 -}
1811 -
1812 -# @FUNCTION: mozconfig_install_prefs
1813 -# @DESCRIPTION:
1814 -# Set preferences into the prefs.js file specified as a parameter to
1815 -# the function. This sets both some common prefs to all mozilla
1816 -# packages, and any prefs that may relate to the use flags administered
1817 -# by mozconfig_config().
1818 -#
1819 -# Call this within src_install() phase, after copying the template
1820 -# prefs file (if any) from ${FILESDIR}
1821 -#
1822 -# Example:
1823 -#
1824 -# inherit mozconfig-v6.46
1825 -#
1826 -# src_install() {
1827 -# cp "${FILESDIR}"/gentoo-default-prefs.js \
1828 -# "${BUILD_OBJ_DIR}/dist/bin/browser/defaults/preferences/all-gentoo.js" \
1829 -# || die
1830 -#
1831 -# mozconfig_install_prefs \
1832 -# "${BUILD_OBJ_DIR}/dist/bin/browser/defaults/preferences/all-gentoo.js"
1833 -#
1834 -# ...
1835 -# }
1836 -
1837 -mozconfig_install_prefs() {
1838 - local prefs_file="${1}"
1839 -
1840 - einfo "Adding prefs from mozconfig to ${prefs_file}"
1841 -
1842 - # set dictionary path, to use system hunspell
1843 - echo "pref(\"spellchecker.dictionary_path\", \"${EPREFIX}/usr/share/myspell\");" \
1844 - >>"${prefs_file}" || die
1845 -
1846 - # force the graphite pref if system-harfbuzz is enabled, since the pref cant disable it
1847 - if use system-harfbuzz ; then
1848 - echo "sticky_pref(\"gfx.font_rendering.graphite.enabled\",true);" \
1849 - >>"${prefs_file}" || die
1850 - fi
1851 -}
1852
1853 diff --git a/eclass/mozconfig-v6.47.eclass b/eclass/mozconfig-v6.47.eclass
1854 deleted file mode 100644
1855 index 5fd672c..0000000
1856 --- a/eclass/mozconfig-v6.47.eclass
1857 +++ /dev/null
1858 @@ -1,420 +0,0 @@
1859 -# Copyright 1999-2015 Gentoo Foundation
1860 -# Distributed under the terms of the GNU General Public License v2
1861 -# $Id$
1862 -#
1863 -# @ECLASS: mozconfig-v6.46.eclass
1864 -# @MAINTAINER:
1865 -# mozilla team <mozilla@g.o>
1866 -# @BLURB: the new mozilla common configuration eclass for FF33 and newer, v6
1867 -# @DESCRIPTION:
1868 -# This eclass is used in mozilla ebuilds (firefox, thunderbird, seamonkey)
1869 -# to provide a single common place for the common mozilla engine compoments.
1870 -#
1871 -# The eclass provides all common dependencies as well as common use flags.
1872 -#
1873 -# Some use flags which may be optional in particular mozilla packages can be
1874 -# supported through setting eclass variables.
1875 -#
1876 -# This eclass inherits mozconfig helper functions as defined in mozcoreconf-v4,
1877 -# and so ebuilds inheriting this eclass do not need to inherit that.
1878 -
1879 -case ${EAPI} in
1880 - 0|1|2|3|4)
1881 - die "EAPI=${EAPI} not supported"
1882 - ;;
1883 - 5)
1884 - inherit multilib
1885 - ;;
1886 -esac
1887 -
1888 -inherit flag-o-matic toolchain-funcs mozcoreconf-v4
1889 -
1890 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_WIFI
1891 -# @DESCRIPTION:
1892 -# Set this variable before the inherit line, when an ebuild needs to provide
1893 -# optional necko-wifi support via IUSE="wifi". Currently this would include
1894 -# ebuilds for firefox, and potentially seamonkey.
1895 -#
1896 -# Leave the variable UNSET if necko-wifi support should not be available.
1897 -# Set the variable to "enabled" if the use flag should be enabled by default.
1898 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1899 -
1900 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_JIT
1901 -# @DESCRIPTION:
1902 -# Set this variable before the inherit line, when an ebuild needs to provide
1903 -# optional necko-wifi support via IUSE="jit". Currently this would include
1904 -# ebuilds for firefox, and potentially seamonkey.
1905 -#
1906 -# Leave the variable UNSET if optional jit support should not be available.
1907 -# Set the variable to "enabled" if the use flag should be enabled by default.
1908 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1909 -
1910 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK3
1911 -# @DESCRIPTION:
1912 -# Set this variable before the inherit line, when an ebuild can provide
1913 -# optional gtk3 support via IUSE="gtk3". Currently this would include
1914 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
1915 -#
1916 -# Leave the variable UNSET if gtk3 support should not be available.
1917 -# Set the variable to "enabled" if the use flag should be enabled by default.
1918 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1919 -
1920 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK2ONLY
1921 -# @DESCRIPTION:
1922 -# Set this variable before the inherit line, when an ebuild can provide
1923 -# optional gtk2-only support via IUSE="gtk2".
1924 -#
1925 -# Note that this option conflicts directly with MOZCONFIG_OPTIONAL_GTK3, both
1926 -# variables cannot be set at the same time and this variable will be ignored if
1927 -# MOZCONFIG_OPTIONAL_GTK3 is set.
1928 -#
1929 -# Leave the variable UNSET if gtk2-only support should not be available.
1930 -# Set the variable to "enabled" if the use flag should be enabled by default.
1931 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1932 -
1933 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_QT5
1934 -# @DESCRIPTION:
1935 -# Set this variable before the inherit line, when an ebuild can provide
1936 -# optional qt5 support via IUSE="qt5". Currently this would include
1937 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
1938 -#
1939 -# Leave the variable UNSET if qt5 support should not be available.
1940 -# Set the variable to "enabled" if the use flag should be enabled by default.
1941 -# Set the variable to any value if the use flag should exist but not be default-enabled.
1942 -
1943 -# use-flags common among all mozilla ebuilds
1944 -IUSE="${IUSE} dbus debug +jemalloc3 neon pulseaudio selinux startup-notification system-cairo
1945 - system-harfbuzz system-icu system-jpeg system-libevent system-sqlite system-libvpx"
1946 -
1947 -# some notes on deps:
1948 -# gtk:2 minimum is technically 2.10 but gio support (enabled by default) needs 2.14
1949 -# media-libs/mesa needs to be 10.2 or above due to a bug with flash+vdpau
1950 -
1951 -RDEPEND=">=app-text/hunspell-1.2:=
1952 - dev-libs/atk
1953 - dev-libs/expat
1954 - >=x11-libs/cairo-1.10[X]
1955 - >=x11-libs/gtk+-2.18:2
1956 - x11-libs/gdk-pixbuf
1957 - >=x11-libs/pango-1.22.0
1958 - >=media-libs/libpng-1.6.21:0=[apng]
1959 - >=media-libs/mesa-10.2:*
1960 - media-libs/fontconfig
1961 - >=media-libs/freetype-2.4.10
1962 - kernel_linux? ( media-libs/alsa-lib )
1963 - pulseaudio? ( media-sound/pulseaudio )
1964 - virtual/freedesktop-icon-theme
1965 - dbus? ( >=sys-apps/dbus-0.60
1966 - >=dev-libs/dbus-glib-0.72 )
1967 - startup-notification? ( >=x11-libs/startup-notification-0.8 )
1968 - >=dev-libs/glib-2.26:2
1969 - >=sys-libs/zlib-1.2.3
1970 - >=virtual/libffi-3.0.10
1971 - virtual/ffmpeg
1972 - x11-libs/libX11
1973 - x11-libs/libXcomposite
1974 - x11-libs/libXdamage
1975 - x11-libs/libXext
1976 - x11-libs/libXfixes
1977 - x11-libs/libXrender
1978 - x11-libs/libXt
1979 - system-cairo? ( >=x11-libs/cairo-1.12[X,xcb] >=x11-libs/pixman-0.19.2 )
1980 - system-icu? ( >=dev-libs/icu-51.1:= )
1981 - system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
1982 - system-libevent? ( =dev-libs/libevent-2.0*:0= )
1983 - system-sqlite? ( >=dev-db/sqlite-3.11.0:3[secure-delete,debug=] )
1984 - system-libvpx? ( >=media-libs/libvpx-1.5.0:0=[postproc] )
1985 - system-harfbuzz? ( >=media-libs/harfbuzz-1.2.2:0=[graphite,icu] >=media-gfx/graphite2-1.3.8 )
1986 -"
1987 -
1988 -if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
1989 - MOZCONFIG_OPTIONAL_GTK2ONLY=
1990 - if [[ ${MOZCONFIG_OPTIONAL_GTK3} = "enabled" ]]; then
1991 - IUSE+=" +gtk3"
1992 - else
1993 - IUSE+=" gtk3"
1994 - fi
1995 - RDEPEND+="
1996 - gtk3? ( >=x11-libs/gtk+-3.4.0:3 )"
1997 -elif [[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]]; then
1998 - if [[ ${MOZCONFIG_OPTIONAL_GTK2ONLY} = "enabled" ]]; then
1999 - IUSE+=" +gtk2"
2000 - else
2001 - IUSE+=" gtk2"
2002 - fi
2003 - RDEPEND+="
2004 - !gtk2? ( >=x11-libs/gtk+-3.4.0:3 )"
2005 -fi
2006 -if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
2007 - inherit qmake-utils
2008 - if [[ ${MOZCONFIG_OPTIONAL_QT5} = "enabled" ]]; then
2009 - IUSE+=" +qt5"
2010 - else
2011 - IUSE+=" qt5"
2012 - fi
2013 - RDEPEND+="
2014 - qt5? (
2015 - dev-qt/qtcore:5
2016 - dev-qt/qtgui:5
2017 - dev-qt/qtnetwork:5
2018 - dev-qt/qtprintsupport:5
2019 - dev-qt/qtwidgets:5
2020 - dev-qt/qtxml:5
2021 - dev-qt/qtdeclarative:5
2022 - )"
2023 -fi
2024 -if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]]; then
2025 - if [[ ${MOZCONFIG_OPTIONAL_WIFI} = "enabled" ]]; then
2026 - IUSE+=" +wifi"
2027 - else
2028 - IUSE+=" wifi"
2029 - fi
2030 - RDEPEND+="
2031 - wifi? (
2032 - kernel_linux? ( >=sys-apps/dbus-0.60
2033 - >=dev-libs/dbus-glib-0.72
2034 - net-misc/networkmanager )
2035 - )"
2036 -fi
2037 -if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
2038 - if [[ ${MOZCONFIG_OPTIONAL_JIT} = "enabled" ]]; then
2039 - IUSE+=" +jit"
2040 - else
2041 - IUSE+=" jit"
2042 - fi
2043 -fi
2044 -
2045 -DEPEND="app-arch/zip
2046 - app-arch/unzip
2047 - >=sys-devel/binutils-2.16.1
2048 - ${RDEPEND}"
2049 -
2050 -RDEPEND+="
2051 - selinux? ( sec-policy/selinux-mozilla )"
2052 -
2053 -# force system-icu if system-harfbuzz is selected, to avoid potential ABI issues
2054 -REQUIRED_USE="
2055 - system-harfbuzz? ( system-icu )"
2056 -
2057 -# only one of gtk3 or qt5 should be permitted to be selected, since only one will be used.
2058 -[[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]] && [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]] && \
2059 - REQUIRED_USE+=" ?? ( gtk3 qt5 )"
2060 -
2061 -# only one of gtk2 or qt5 should be permitted to be selected, since only one will be used.
2062 -[[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]] && [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]] && \
2063 - REQUIRED_USE+=" ?? ( gtk2 qt5 )"
2064 -
2065 -# @FUNCTION: mozconfig_config
2066 -# @DESCRIPTION:
2067 -# Set common configure options for mozilla packages.
2068 -# Call this within src_configure() phase, after mozconfig_init
2069 -#
2070 -# Example:
2071 -#
2072 -# inherit mozconfig-v6.46
2073 -#
2074 -# src_configure() {
2075 -# mozconfig_init
2076 -# mozconfig_config
2077 -# # ... misc ebuild-unique settings via calls to
2078 -# # ... mozconfig_{annotate,use_with,use_enable}
2079 -# mozconfig_final
2080 -# }
2081 -
2082 -mozconfig_config() {
2083 - # Migrated from mozcoreconf-v3
2084 - mozconfig_annotate 'more disable_update_strip' \
2085 - --disable-pedantic \
2086 - --disable-installer \
2087 - --disable-strip-libs
2088 -
2089 - if [[ ${PN} != seamonkey ]]; then
2090 - mozconfig_annotate 'basic_profile' \
2091 - --disable-profilelocking \
2092 - --enable-single-profile \
2093 - --disable-profilesharing
2094 - fi
2095 -
2096 - # Migrated from mozcoreconf-2
2097 - mozconfig_annotate 'system_libs' \
2098 - --with-system-zlib \
2099 - --enable-pango \
2100 - --enable-svg \
2101 - --with-system-bz2
2102 -
2103 - if has bindist ${IUSE}; then
2104 - mozconfig_use_enable !bindist official-branding
2105 - if [[ ${PN} == firefox ]] && use bindist ; then
2106 - mozconfig_annotate '' --with-branding=browser/branding/aurora
2107 - fi
2108 - fi
2109 -
2110 - mozconfig_use_enable debug
2111 - mozconfig_use_enable debug tests
2112 -
2113 - if ! use debug ; then
2114 - mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
2115 - else
2116 - mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
2117 - fi
2118 -
2119 - mozconfig_use_enable startup-notification
2120 -
2121 - if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]] ; then
2122 - # wifi pulls in dbus so manage both here
2123 - mozconfig_use_enable wifi necko-wifi
2124 - if use kernel_linux && use wifi && ! use dbus; then
2125 - echo "Enabling dbus support due to wifi request"
2126 - mozconfig_annotate 'dbus required by necko-wifi on linux' --enable-dbus
2127 - else
2128 - mozconfig_use_enable dbus
2129 - fi
2130 - else
2131 - mozconfig_use_enable dbus
2132 - mozconfig_annotate 'disabled' --disable-necko-wifi
2133 - fi
2134 -
2135 - # These are forced-on for webm support
2136 - mozconfig_annotate 'required' --enable-ogg
2137 - mozconfig_annotate 'required' --enable-wave
2138 -
2139 - if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
2140 - mozconfig_use_enable jit ion
2141 - fi
2142 -
2143 - # These are enabled by default in all mozilla applications
2144 - mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${SYSROOT}${EPREFIX}"/usr
2145 - mozconfig_annotate '' --with-system-nss --with-nss-prefix="${SYSROOT}${EPREFIX}"/usr
2146 - mozconfig_annotate '' --x-includes="${SYSROOT}${EPREFIX}"/usr/include --x-libraries="${SYSROOT}${EPREFIX}"/usr/$(get_libdir)
2147 - if use system-libevent; then
2148 - mozconfig_annotate '' --with-system-libevent="${SYSROOT}${EPREFIX}"/usr
2149 - fi
2150 - mozconfig_annotate '' --prefix="${EPREFIX}"/usr
2151 - mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
2152 - mozconfig_annotate 'Gentoo default' --enable-system-hunspell
2153 - mozconfig_annotate '' --disable-gnomeui
2154 - mozconfig_annotate '' --enable-gio
2155 - mozconfig_annotate '' --disable-crashreporter
2156 - mozconfig_annotate 'Gentoo default' --with-system-png
2157 - mozconfig_annotate '' --enable-system-ffi
2158 - mozconfig_annotate 'Gentoo default to honor system linker' --disable-gold
2159 - mozconfig_annotate 'Gentoo default' --disable-skia
2160 - mozconfig_annotate '' --disable-gconf
2161 - mozconfig_annotate '' --with-intl-api
2162 -
2163 - # default toolkit is cairo-gtk2, optional use flags can change this
2164 - local toolkit="cairo-gtk2"
2165 - local toolkit_comment=""
2166 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
2167 - if use gtk3; then
2168 - toolkit="cairo-gtk3"
2169 - toolkit_comment="gtk3 use flag"
2170 - fi
2171 - fi
2172 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]]; then
2173 - if ! use gtk2 ; then
2174 - toolkit="cairo-gtk3"
2175 - else
2176 - toolkit_comment="gtk2 use flag"
2177 - fi
2178 - fi
2179 - if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
2180 - if use qt5; then
2181 - toolkit="cairo-qt"
2182 - toolkit_comment="qt5 use flag"
2183 - # need to specify these vars because the qt5 versions are not found otherwise,
2184 - # and setting --with-qtdir overrides the pkg-config include dirs
2185 - local i
2186 - for i in qmake moc rcc; do
2187 - echo "export HOST_${i^^}=\"$(qt5_get_bindir)/${i}\"" \
2188 - >> "${S}"/.mozconfig || die
2189 - done
2190 - echo 'unset QTDIR' >> "${S}"/.mozconfig || die
2191 - mozconfig_annotate '+qt5' --disable-gio
2192 - fi
2193 - fi
2194 - mozconfig_annotate "${toolkit_comment}" --enable-default-toolkit=${toolkit}
2195 -
2196 - # Use jemalloc unless libc is not glibc >= 2.4
2197 - # at this time the minimum glibc in the tree is 2.9 so we should be safe.
2198 - if use elibc_glibc && use jemalloc3; then
2199 - # We must force-enable jemalloc 3 via .mozconfig
2200 - echo "export MOZ_JEMALLOC3=1" >> "${S}"/.mozconfig || die
2201 - mozconfig_annotate '' --enable-jemalloc
2202 - mozconfig_annotate '' --enable-replace-malloc
2203 - fi
2204 -
2205 - # Instead of the standard --build= and --host=, mozilla uses --host instead
2206 - # of --build, and --target intstead of --host.
2207 - # Note, mozilla also has --build but it does not do what you think it does.
2208 - # Set both --target and --host as mozilla uses python to guess values otherwise
2209 - mozconfig_annotate '' --target="${CHOST}"
2210 - mozconfig_annotate '' --host="${CBUILD:-${CHOST}}"
2211 -
2212 - mozconfig_use_enable pulseaudio
2213 -
2214 - mozconfig_use_enable system-cairo
2215 - mozconfig_use_enable system-sqlite
2216 - mozconfig_use_with system-jpeg
2217 - mozconfig_use_with system-icu
2218 - mozconfig_use_with system-libvpx
2219 - mozconfig_use_with system-harfbuzz
2220 - mozconfig_use_with system-harfbuzz system-graphite2
2221 -
2222 - # Modifications to better support ARM, bug 553364
2223 - if use neon ; then
2224 - mozconfig_annotate '' --with-fpu=neon
2225 - mozconfig_annotate '' --with-thumb=yes
2226 - mozconfig_annotate '' --with-thumb-interwork=no
2227 - fi
2228 - if [[ ${CHOST} == armv* ]] ; then
2229 - mozconfig_annotate '' --with-float-abi=hard
2230 - mozconfig_annotate '' --enable-skia
2231 -
2232 - if ! use system-libvpx ; then
2233 - sed -i -e "s|softfp|hard|" \
2234 - "${S}"/media/libvpx/moz.build
2235 - fi
2236 - fi
2237 -}
2238 -
2239 -# @FUNCTION: mozconfig_install_prefs
2240 -# @DESCRIPTION:
2241 -# Set preferences into the prefs.js file specified as a parameter to
2242 -# the function. This sets both some common prefs to all mozilla
2243 -# packages, and any prefs that may relate to the use flags administered
2244 -# by mozconfig_config().
2245 -#
2246 -# Call this within src_install() phase, after copying the template
2247 -# prefs file (if any) from ${FILESDIR}
2248 -#
2249 -# Example:
2250 -#
2251 -# inherit mozconfig-v6.46
2252 -#
2253 -# src_install() {
2254 -# cp "${FILESDIR}"/gentoo-default-prefs.js \
2255 -# "${BUILD_OBJ_DIR}/dist/bin/browser/defaults/preferences/all-gentoo.js" \
2256 -# || die
2257 -#
2258 -# mozconfig_install_prefs \
2259 -# "${BUILD_OBJ_DIR}/dist/bin/browser/defaults/preferences/all-gentoo.js"
2260 -#
2261 -# ...
2262 -# }
2263 -
2264 -mozconfig_install_prefs() {
2265 - local prefs_file="${1}"
2266 -
2267 - einfo "Adding prefs from mozconfig to ${prefs_file}"
2268 -
2269 - # set dictionary path, to use system hunspell
2270 - echo "pref(\"spellchecker.dictionary_path\", \"${EPREFIX}/usr/share/myspell\");" \
2271 - >>"${prefs_file}" || die
2272 -
2273 - # force the graphite pref if system-harfbuzz is enabled, since the pref cant disable it
2274 - if use system-harfbuzz ; then
2275 - echo "sticky_pref(\"gfx.font_rendering.graphite.enabled\",true);" \
2276 - >>"${prefs_file}" || die
2277 - fi
2278 -}
2279
2280 diff --git a/eclass/mozconfig-v6.48.eclass b/eclass/mozconfig-v6.48.eclass
2281 deleted file mode 100644
2282 index 8ba0fd5..0000000
2283 --- a/eclass/mozconfig-v6.48.eclass
2284 +++ /dev/null
2285 @@ -1,409 +0,0 @@
2286 -# Copyright 1999-2015 Gentoo Foundation
2287 -# Distributed under the terms of the GNU General Public License v2
2288 -# $Id$
2289 -#
2290 -# @ECLASS: mozconfig-v6.46.eclass
2291 -# @MAINTAINER:
2292 -# mozilla team <mozilla@g.o>
2293 -# @BLURB: the new mozilla common configuration eclass for FF33 and newer, v6
2294 -# @DESCRIPTION:
2295 -# This eclass is used in mozilla ebuilds (firefox, thunderbird, seamonkey)
2296 -# to provide a single common place for the common mozilla engine compoments.
2297 -#
2298 -# The eclass provides all common dependencies as well as common use flags.
2299 -#
2300 -# Some use flags which may be optional in particular mozilla packages can be
2301 -# supported through setting eclass variables.
2302 -#
2303 -# This eclass inherits mozconfig helper functions as defined in mozcoreconf-v3,
2304 -# and so ebuilds inheriting this eclass do not need to inherit that.
2305 -
2306 -case ${EAPI} in
2307 - 0|1|2|3|4)
2308 - die "EAPI=${EAPI} not supported"
2309 - ;;
2310 - 5)
2311 - inherit multilib
2312 - ;;
2313 -esac
2314 -
2315 -inherit flag-o-matic toolchain-funcs mozcoreconf-v4
2316 -
2317 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_WIFI
2318 -# @DESCRIPTION:
2319 -# Set this variable before the inherit line, when an ebuild needs to provide
2320 -# optional necko-wifi support via IUSE="wifi". Currently this would include
2321 -# ebuilds for firefox, and potentially seamonkey.
2322 -#
2323 -# Leave the variable UNSET if necko-wifi support should not be available.
2324 -# Set the variable to "enabled" if the use flag should be enabled by default.
2325 -# Set the variable to any value if the use flag should exist but not be default-enabled.
2326 -
2327 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_JIT
2328 -# @DESCRIPTION:
2329 -# Set this variable before the inherit line, when an ebuild needs to provide
2330 -# optional necko-wifi support via IUSE="jit". Currently this would include
2331 -# ebuilds for firefox, and potentially seamonkey.
2332 -#
2333 -# Leave the variable UNSET if optional jit support should not be available.
2334 -# Set the variable to "enabled" if the use flag should be enabled by default.
2335 -# Set the variable to any value if the use flag should exist but not be default-enabled.
2336 -
2337 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK3
2338 -# @DESCRIPTION:
2339 -# Set this variable before the inherit line, when an ebuild can provide
2340 -# optional gtk3 support via IUSE="gtk3". Currently this would include
2341 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
2342 -#
2343 -# Leave the variable UNSET if gtk3 support should not be available.
2344 -# Set the variable to "enabled" if the use flag should be enabled by default.
2345 -# Set the variable to any value if the use flag should exist but not be default-enabled.
2346 -
2347 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK2ONLY
2348 -# @DESCRIPTION:
2349 -# Set this variable before the inherit line, when an ebuild can provide
2350 -# optional gtk2-only support via IUSE="gtk2".
2351 -#
2352 -# Note that this option conflicts directly with MOZCONFIG_OPTIONAL_GTK3, both
2353 -# variables cannot be set at the same time and this variable will be ignored if
2354 -# MOZCONFIG_OPTIONAL_GTK3 is set.
2355 -#
2356 -# Leave the variable UNSET if gtk2-only support should not be available.
2357 -# Set the variable to "enabled" if the use flag should be enabled by default.
2358 -# Set the variable to any value if the use flag should exist but not be default-enabled.
2359 -
2360 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_QT5
2361 -# @DESCRIPTION:
2362 -# Set this variable before the inherit line, when an ebuild can provide
2363 -# optional qt5 support via IUSE="qt5". Currently this would include
2364 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
2365 -#
2366 -# Leave the variable UNSET if qt5 support should not be available.
2367 -# Set the variable to "enabled" if the use flag should be enabled by default.
2368 -# Set the variable to any value if the use flag should exist but not be default-enabled.
2369 -
2370 -# use-flags common among all mozilla ebuilds
2371 -IUSE="${IUSE} dbus debug +jemalloc neon pulseaudio selinux +skia startup-notification system-cairo
2372 - system-harfbuzz system-icu system-jpeg system-libevent system-sqlite system-libvpx"
2373 -
2374 -# some notes on deps:
2375 -# gtk:2 minimum is technically 2.10 but gio support (enabled by default) needs 2.14
2376 -# media-libs/mesa needs to be 10.2 or above due to a bug with flash+vdpau
2377 -
2378 -RDEPEND=">=app-text/hunspell-1.2:=
2379 - dev-libs/atk
2380 - dev-libs/expat
2381 - >=x11-libs/cairo-1.10[X]
2382 - >=x11-libs/gtk+-2.18:2
2383 - x11-libs/gdk-pixbuf
2384 - >=x11-libs/pango-1.22.0
2385 - >=media-libs/libpng-1.6.21:0=[apng]
2386 - >=media-libs/mesa-10.2:*
2387 - media-libs/fontconfig
2388 - >=media-libs/freetype-2.4.10
2389 - kernel_linux? ( media-libs/alsa-lib )
2390 - pulseaudio? ( media-sound/pulseaudio )
2391 - virtual/freedesktop-icon-theme
2392 - dbus? ( >=sys-apps/dbus-0.60
2393 - >=dev-libs/dbus-glib-0.72 )
2394 - startup-notification? ( >=x11-libs/startup-notification-0.8 )
2395 - >=dev-libs/glib-2.26:2
2396 - >=sys-libs/zlib-1.2.3
2397 - >=virtual/libffi-3.0.10
2398 - virtual/ffmpeg
2399 - x11-libs/libX11
2400 - x11-libs/libXcomposite
2401 - x11-libs/libXdamage
2402 - x11-libs/libXext
2403 - x11-libs/libXfixes
2404 - x11-libs/libXrender
2405 - x11-libs/libXt
2406 - system-cairo? ( >=x11-libs/cairo-1.12[X,xcb] >=x11-libs/pixman-0.19.2 )
2407 - system-icu? ( >=dev-libs/icu-51.1:= )
2408 - system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
2409 - system-libevent? ( =dev-libs/libevent-2.0*:0= )
2410 - system-sqlite? ( >=dev-db/sqlite-3.12.2:3[secure-delete,debug=] )
2411 - system-libvpx? ( >=media-libs/libvpx-1.5.0:0=[postproc] )
2412 - system-harfbuzz? ( >=media-libs/harfbuzz-1.2.6:0=[graphite,icu] >=media-gfx/graphite2-1.3.8 )
2413 -"
2414 -
2415 -if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
2416 - MOZCONFIG_OPTIONAL_GTK2ONLY=
2417 - if [[ ${MOZCONFIG_OPTIONAL_GTK3} = "enabled" ]]; then
2418 - IUSE+=" +gtk3"
2419 - else
2420 - IUSE+=" gtk3"
2421 - fi
2422 - RDEPEND+="
2423 - gtk3? ( >=x11-libs/gtk+-3.4.0:3 )"
2424 -elif [[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]]; then
2425 - if [[ ${MOZCONFIG_OPTIONAL_GTK2ONLY} = "enabled" ]]; then
2426 - IUSE+=" +gtk2"
2427 - else
2428 - IUSE+=" gtk2"
2429 - fi
2430 - RDEPEND+="
2431 - !gtk2? ( >=x11-libs/gtk+-3.4.0:3 )"
2432 -fi
2433 -if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
2434 - inherit qmake-utils
2435 - if [[ ${MOZCONFIG_OPTIONAL_QT5} = "enabled" ]]; then
2436 - IUSE+=" +qt5"
2437 - else
2438 - IUSE+=" qt5"
2439 - fi
2440 - RDEPEND+="
2441 - qt5? (
2442 - dev-qt/qtcore:5
2443 - dev-qt/qtgui:5
2444 - dev-qt/qtnetwork:5
2445 - dev-qt/qtprintsupport:5
2446 - dev-qt/qtwidgets:5
2447 - dev-qt/qtxml:5
2448 - dev-qt/qtdeclarative:5
2449 - )"
2450 -fi
2451 -if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]]; then
2452 - if [[ ${MOZCONFIG_OPTIONAL_WIFI} = "enabled" ]]; then
2453 - IUSE+=" +wifi"
2454 - else
2455 - IUSE+=" wifi"
2456 - fi
2457 - RDEPEND+="
2458 - wifi? (
2459 - kernel_linux? ( >=sys-apps/dbus-0.60
2460 - >=dev-libs/dbus-glib-0.72
2461 - net-misc/networkmanager )
2462 - )"
2463 -fi
2464 -if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
2465 - if [[ ${MOZCONFIG_OPTIONAL_JIT} = "enabled" ]]; then
2466 - IUSE+=" +jit"
2467 - else
2468 - IUSE+=" jit"
2469 - fi
2470 -fi
2471 -
2472 -DEPEND="app-arch/zip
2473 - app-arch/unzip
2474 - >=sys-devel/binutils-2.16.1
2475 - sys-apps/findutils
2476 - ${RDEPEND}"
2477 -
2478 -RDEPEND+="
2479 - selinux? ( sec-policy/selinux-mozilla )"
2480 -
2481 -# force system-icu if system-harfbuzz is selected, to avoid potential ABI issues
2482 -REQUIRED_USE="
2483 - system-harfbuzz? ( system-icu )"
2484 -
2485 -# only one of gtk3 or qt5 should be permitted to be selected, since only one will be used.
2486 -[[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]] && [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]] && \
2487 - REQUIRED_USE+=" ?? ( gtk3 qt5 )"
2488 -
2489 -# only one of gtk2 or qt5 should be permitted to be selected, since only one will be used.
2490 -[[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]] && [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]] && \
2491 - REQUIRED_USE+=" ?? ( gtk2 qt5 )"
2492 -
2493 -# @FUNCTION: mozconfig_config
2494 -# @DESCRIPTION:
2495 -# Set common configure options for mozilla packages.
2496 -# Call this within src_configure() phase, after mozconfig_init
2497 -#
2498 -# Example:
2499 -#
2500 -# inherit mozconfig-v6.46
2501 -#
2502 -# src_configure() {
2503 -# mozconfig_init
2504 -# mozconfig_config
2505 -# # ... misc ebuild-unique settings via calls to
2506 -# # ... mozconfig_{annotate,use_with,use_enable}
2507 -# mozconfig_final
2508 -# }
2509 -
2510 -mozconfig_config() {
2511 - # Migrated from mozcoreconf-2
2512 - mozconfig_annotate 'system_libs' \
2513 - --with-system-zlib \
2514 - --with-system-bz2
2515 -
2516 - if has bindist ${IUSE}; then
2517 - mozconfig_use_enable !bindist official-branding
2518 - if [[ ${PN} == firefox ]] && use bindist ; then
2519 - mozconfig_annotate '' --with-branding=browser/branding/aurora
2520 - fi
2521 - fi
2522 -
2523 - mozconfig_use_enable debug
2524 - mozconfig_use_enable debug tests
2525 -
2526 - if ! use debug ; then
2527 - mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
2528 - else
2529 - mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
2530 - fi
2531 -
2532 - mozconfig_use_enable startup-notification
2533 -
2534 - if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]] ; then
2535 - # wifi pulls in dbus so manage both here
2536 - mozconfig_use_enable wifi necko-wifi
2537 - if use kernel_linux && use wifi && ! use dbus; then
2538 - echo "Enabling dbus support due to wifi request"
2539 - mozconfig_annotate 'dbus required by necko-wifi on linux' --enable-dbus
2540 - else
2541 - mozconfig_use_enable dbus
2542 - fi
2543 - else
2544 - mozconfig_use_enable dbus
2545 - mozconfig_annotate 'disabled' --disable-necko-wifi
2546 - fi
2547 -
2548 - if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
2549 - mozconfig_use_enable jit ion
2550 - fi
2551 -
2552 - # These are enabled by default in all mozilla applications
2553 - mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${SYSROOT}${EPREFIX}"/usr
2554 - mozconfig_annotate '' --with-system-nss --with-nss-prefix="${SYSROOT}${EPREFIX}"/usr
2555 - mozconfig_annotate '' --x-includes="${SYSROOT}${EPREFIX}"/usr/include --x-libraries="${SYSROOT}${EPREFIX}"/usr/$(get_libdir)
2556 - if use system-libevent; then
2557 - mozconfig_annotate '' --with-system-libevent="${SYSROOT}${EPREFIX}"/usr
2558 - fi
2559 - mozconfig_annotate '' --prefix="${EPREFIX}"/usr
2560 - mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
2561 - mozconfig_annotate 'Gentoo default' --enable-system-hunspell
2562 - mozconfig_annotate '' --disable-gnomeui
2563 - mozconfig_annotate '' --enable-gio
2564 - mozconfig_annotate '' --disable-crashreporter
2565 - mozconfig_annotate 'Gentoo default' --with-system-png
2566 - mozconfig_annotate '' --enable-system-ffi
2567 - mozconfig_annotate 'Gentoo default to honor system linker' --disable-gold
2568 - mozconfig_use_enable skia
2569 - mozconfig_annotate '' --disable-gconf
2570 - mozconfig_annotate '' --with-intl-api
2571 -
2572 - # default toolkit is cairo-gtk2, optional use flags can change this
2573 - local toolkit="cairo-gtk2"
2574 - local toolkit_comment=""
2575 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
2576 - if use gtk3; then
2577 - toolkit="cairo-gtk3"
2578 - toolkit_comment="gtk3 use flag"
2579 - fi
2580 - fi
2581 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]]; then
2582 - if ! use gtk2 ; then
2583 - toolkit="cairo-gtk3"
2584 - else
2585 - toolkit_comment="gtk2 use flag"
2586 - fi
2587 - fi
2588 - if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
2589 - if use qt5; then
2590 - toolkit="cairo-qt"
2591 - toolkit_comment="qt5 use flag"
2592 - # need to specify these vars because the qt5 versions are not found otherwise,
2593 - # and setting --with-qtdir overrides the pkg-config include dirs
2594 - local i
2595 - for i in qmake moc rcc; do
2596 - echo "export HOST_${i^^}=\"$(qt5_get_bindir)/${i}\"" \
2597 - >> "${S}"/.mozconfig || die
2598 - done
2599 - echo 'unset QTDIR' >> "${S}"/.mozconfig || die
2600 - mozconfig_annotate '+qt5' --disable-gio
2601 - fi
2602 - fi
2603 - mozconfig_annotate "${toolkit_comment}" --enable-default-toolkit=${toolkit}
2604 -
2605 - # Use jemalloc unless libc is not glibc >= 2.4
2606 - # at this time the minimum glibc in the tree is 2.9 so we should be safe.
2607 - if use elibc_glibc && use jemalloc; then
2608 - # We must force-enable jemalloc 4 via .mozconfig
2609 - echo "export MOZ_JEMALLOC4=1" >> "${S}"/.mozconfig || die
2610 - mozconfig_annotate '' --enable-replace-malloc
2611 - fi
2612 -
2613 - # Instead of the standard --build= and --host=, mozilla uses --host instead
2614 - # of --build, and --target intstead of --host.
2615 - # Note, mozilla also has --build but it does not do what you think it does.
2616 - # Set both --target and --host as mozilla uses python to guess values otherwise
2617 - mozconfig_annotate '' --target="${CHOST}"
2618 - mozconfig_annotate '' --host="${CBUILD:-${CHOST}}"
2619 -
2620 - mozconfig_use_enable pulseaudio
2621 -
2622 - mozconfig_use_enable system-cairo
2623 - mozconfig_use_enable system-sqlite
2624 - mozconfig_use_with system-jpeg
2625 - mozconfig_use_with system-icu
2626 - mozconfig_use_with system-libvpx
2627 - mozconfig_use_with system-harfbuzz
2628 - mozconfig_use_with system-harfbuzz system-graphite2
2629 -
2630 - # Modifications to better support ARM, bug 553364
2631 - if use neon ; then
2632 - mozconfig_annotate '' --with-fpu=neon
2633 - mozconfig_annotate '' --with-thumb=yes
2634 - mozconfig_annotate '' --with-thumb-interwork=no
2635 - fi
2636 - if [[ ${CHOST} == armv* ]] ; then
2637 - mozconfig_annotate '' --with-float-abi=hard
2638 - mozconfig_annotate '' --enable-skia
2639 -
2640 - if ! use system-libvpx ; then
2641 - sed -i -e "s|softfp|hard|" \
2642 - "${S}"/media/libvpx/moz.build
2643 - fi
2644 - fi
2645 -}
2646 -
2647 -# @FUNCTION: mozconfig_install_prefs
2648 -# @DESCRIPTION:
2649 -# Set preferences into the prefs.js file specified as a parameter to
2650 -# the function. This sets both some common prefs to all mozilla
2651 -# packages, and any prefs that may relate to the use flags administered
2652 -# by mozconfig_config().
2653 -#
2654 -# Call this within src_install() phase, after copying the template
2655 -# prefs file (if any) from ${FILESDIR}
2656 -#
2657 -# Example:
2658 -#
2659 -# inherit mozconfig-v6.46
2660 -#
2661 -# src_install() {
2662 -# cp "${FILESDIR}"/gentoo-default-prefs.js \
2663 -# "${BUILD_OBJ_DIR}/dist/bin/browser/defaults/preferences/all-gentoo.js" \
2664 -# || die
2665 -#
2666 -# mozconfig_install_prefs \
2667 -# "${BUILD_OBJ_DIR}/dist/bin/browser/defaults/preferences/all-gentoo.js"
2668 -#
2669 -# ...
2670 -# }
2671 -
2672 -mozconfig_install_prefs() {
2673 - local prefs_file="${1}"
2674 -
2675 - einfo "Adding prefs from mozconfig to ${prefs_file}"
2676 -
2677 - # set dictionary path, to use system hunspell
2678 - echo "pref(\"spellchecker.dictionary_path\", \"${EPREFIX}/usr/share/myspell\");" \
2679 - >>"${prefs_file}" || die
2680 -
2681 - # force the graphite pref if system-harfbuzz is enabled, since the pref cant disable it
2682 - if use system-harfbuzz ; then
2683 - echo "sticky_pref(\"gfx.font_rendering.graphite.enabled\",true);" \
2684 - >>"${prefs_file}" || die
2685 - fi
2686 -
2687 - # force cairo as the canvas renderer if USE=skia is disabled
2688 - if ! use skia ; then
2689 - echo "lockPref(\"gfx.canvas.azure.backends\",\"cairo\");" \
2690 - >>"${prefs_file}" || die
2691 - echo "lockPref(\"gfx.content.azure.backends\",\"cairo\");" \
2692 - >>"${prefs_file}" || die
2693 - fi
2694 -}
2695
2696 diff --git a/eclass/mozcoreconf-v3.eclass b/eclass/mozcoreconf-v3.eclass
2697 deleted file mode 100644
2698 index 5060c73..0000000
2699 --- a/eclass/mozcoreconf-v3.eclass
2700 +++ /dev/null
2701 @@ -1,261 +0,0 @@
2702 -# Copyright 1999-2015 Gentoo Foundation
2703 -# Distributed under the terms of the GNU General Public License v2
2704 -# $Id$
2705 -#
2706 -# @ECLASS: mozcoreconf.eclass
2707 -# @MAINTAINER:
2708 -# Mozilla team <mozilla@g.o>
2709 -# @BLURB: core options and configuration functions for mozilla
2710 -# @DESCRIPTION:
2711 -#
2712 -# inherit mozconfig-v5.* or above for mozilla configuration support
2713 -
2714 -if [[ ! ${_MOZCORECONF_V3} ]]; then
2715 -
2716 -PYTHON_COMPAT=( python2_7 )
2717 -PYTHON_REQ_USE='ncurses,sqlite,ssl,threads'
2718 -
2719 -inherit multilib flag-o-matic python-any-r1 versionator
2720 -
2721 -IUSE="${IUSE} custom-cflags custom-optimization"
2722 -
2723 -DEPEND="virtual/pkgconfig
2724 - ${PYTHON_DEPS}"
2725 -
2726 -# @FUNCTION: mozconfig_annotate
2727 -# @DESCRIPTION:
2728 -# add an annotated line to .mozconfig
2729 -#
2730 -# Example:
2731 -# mozconfig_annotate "building on ultrasparc" --enable-js-ultrasparc
2732 -# => ac_add_options --enable-js-ultrasparc # building on ultrasparc
2733 -mozconfig_annotate() {
2734 - declare reason=$1 x ; shift
2735 - [[ $# -gt 0 ]] || die "mozconfig_annotate missing flags for ${reason}\!"
2736 - for x in ${*}; do
2737 - echo "ac_add_options ${x} # ${reason}" >>.mozconfig
2738 - done
2739 -}
2740 -
2741 -# @FUNCTION: mozconfig_use_enable
2742 -# @DESCRIPTION:
2743 -# add a line to .mozconfig based on a USE-flag
2744 -#
2745 -# Example:
2746 -# mozconfig_use_enable truetype freetype2
2747 -# => ac_add_options --enable-freetype2 # +truetype
2748 -mozconfig_use_enable() {
2749 - declare flag=$(use_enable "$@")
2750 - mozconfig_annotate "$(use $1 && echo +$1 || echo -$1)" "${flag}"
2751 -}
2752 -
2753 -# @FUNCTION mozconfig_use_with
2754 -# @DESCRIPTION
2755 -# add a line to .mozconfig based on a USE-flag
2756 -#
2757 -# Example:
2758 -# mozconfig_use_with kerberos gss-api /usr/$(get_libdir)
2759 -# => ac_add_options --with-gss-api=/usr/lib # +kerberos
2760 -mozconfig_use_with() {
2761 - declare flag=$(use_with "$@")
2762 - mozconfig_annotate "$(use $1 && echo +$1 || echo -$1)" "${flag}"
2763 -}
2764 -
2765 -# @FUNCTION mozconfig_use_extension
2766 -# @DESCRIPTION
2767 -# enable or disable an extension based on a USE-flag
2768 -#
2769 -# Example:
2770 -# mozconfig_use_extension gnome gnomevfs
2771 -# => ac_add_options --enable-extensions=gnomevfs
2772 -mozconfig_use_extension() {
2773 - declare minus=$(use $1 || echo -)
2774 - mozconfig_annotate "${minus:-+}$1" --enable-extensions=${minus}${2}
2775 -}
2776 -
2777 -moz_pkgsetup() {
2778 - # Ensure we use C locale when building
2779 - export LANG="C"
2780 - export LC_ALL="C"
2781 - export LC_MESSAGES="C"
2782 - export LC_CTYPE="C"
2783 -
2784 - # Ensure that we have a sane build enviroment
2785 - export MOZILLA_CLIENT=1
2786 - export BUILD_OPT=1
2787 - export NO_STATIC_LIB=1
2788 - export USE_PTHREADS=1
2789 - export ALDFLAGS=${LDFLAGS}
2790 - # ensure MOZCONFIG is not defined
2791 - eval unset MOZCONFIG
2792 -
2793 - # nested configure scripts in mozilla products generate unrecognized options
2794 - # false positives when toplevel configure passes downwards.
2795 - export QA_CONFIGURE_OPTIONS=".*"
2796 -
2797 - if [[ $(gcc-major-version) -eq 3 ]]; then
2798 - ewarn "Unsupported compiler detected, DO NOT file bugs for"
2799 - ewarn "outdated compilers. Bugs opened with gcc-3 will be closed"
2800 - ewarn "invalid."
2801 - fi
2802 -
2803 - python-any-r1_pkg_setup
2804 -}
2805 -
2806 -# @FUNCTION: mozconfig_init
2807 -# @DESCRIPTION:
2808 -# Initialize mozilla configuration and populate with core settings.
2809 -# This should be called in src_configure before any other mozconfig_* functions.
2810 -mozconfig_init() {
2811 - declare enable_optimize pango_version myext x
2812 - declare XUL=$([[ ${PN} == xulrunner ]] && echo true || echo false)
2813 - declare FF=$([[ ${PN} == firefox ]] && echo true || echo false)
2814 - declare SM=$([[ ${PN} == seamonkey ]] && echo true || echo false)
2815 - declare TB=$([[ ${PN} == thunderbird ]] && echo true || echo false)
2816 -
2817 - ####################################
2818 - #
2819 - # Setup the initial .mozconfig
2820 - # See http://www.mozilla.org/build/configure-build.html
2821 - #
2822 - ####################################
2823 -
2824 - case ${PN} in
2825 - *xulrunner)
2826 - cp xulrunner/config/mozconfig .mozconfig \
2827 - || die "cp xulrunner/config/mozconfig failed" ;;
2828 - *firefox)
2829 - cp browser/config/mozconfig .mozconfig \
2830 - || die "cp browser/config/mozconfig failed" ;;
2831 - seamonkey)
2832 - # Must create the initial mozconfig to enable application
2833 - : >.mozconfig || die "initial mozconfig creation failed"
2834 - mozconfig_annotate "" --enable-application=suite ;;
2835 - *thunderbird)
2836 - # Must create the initial mozconfig to enable application
2837 - : >.mozconfig || die "initial mozconfig creation failed"
2838 - mozconfig_annotate "" --enable-application=mail ;;
2839 - esac
2840 -
2841 - ####################################
2842 - #
2843 - # CFLAGS setup and ARCH support
2844 - #
2845 - ####################################
2846 -
2847 - # Set optimization level
2848 - if [[ ${ARCH} == hppa ]]; then
2849 - mozconfig_annotate "more than -O0 causes a segfault on hppa" --enable-optimize=-O0
2850 - elif [[ ${ARCH} == x86 ]]; then
2851 - mozconfig_annotate "less then -O2 causes a segfault on x86" --enable-optimize=-O2
2852 - elif use custom-optimization || [[ ${ARCH} =~ (alpha|ia64) ]]; then
2853 - # Set optimization level based on CFLAGS
2854 - if is-flag -O0; then
2855 - mozconfig_annotate "from CFLAGS" --enable-optimize=-O0
2856 - elif [[ ${ARCH} == ppc ]] && has_version '>=sys-libs/glibc-2.8'; then
2857 - mozconfig_annotate "more than -O1 segfaults on ppc with glibc-2.8" --enable-optimize=-O1
2858 - elif is-flag -O3; then
2859 - mozconfig_annotate "from CFLAGS" --enable-optimize=-O3
2860 - elif is-flag -O1; then
2861 - mozconfig_annotate "from CFLAGS" --enable-optimize=-O1
2862 - elif is-flag -Os; then
2863 - mozconfig_annotate "from CFLAGS" --enable-optimize=-Os
2864 - else
2865 - mozconfig_annotate "Gentoo's default optimization" --enable-optimize=-O2
2866 - fi
2867 - else
2868 - # Enable Mozilla's default
2869 - mozconfig_annotate "mozilla default" --enable-optimize
2870 - fi
2871 -
2872 - # Strip optimization so it does not end up in compile string
2873 - filter-flags '-O*'
2874 -
2875 - # Strip over-aggressive CFLAGS
2876 - use custom-cflags || strip-flags
2877 -
2878 - # Additional ARCH support
2879 - case "${ARCH}" in
2880 - alpha)
2881 - # Historically we have needed to add -fPIC manually for 64-bit.
2882 - # Additionally, alpha should *always* build with -mieee for correct math
2883 - # operation
2884 - append-flags -fPIC -mieee
2885 - ;;
2886 -
2887 - ia64)
2888 - # Historically we have needed to add this manually for 64-bit
2889 - append-flags -fPIC
2890 - ;;
2891 -
2892 - ppc64)
2893 - append-flags -fPIC -mminimal-toc
2894 - ;;
2895 - esac
2896 -
2897 - # Go a little faster; use less RAM
2898 - append-flags "$MAKEEDIT_FLAGS"
2899 -
2900 - ####################################
2901 - #
2902 - # mozconfig setup
2903 - #
2904 - ####################################
2905 -
2906 - mozconfig_annotate disable_update_strip \
2907 - --disable-pedantic \
2908 - --disable-updater \
2909 - --disable-strip \
2910 - --disable-install-strip \
2911 - --disable-installer \
2912 - --disable-strip-libs
2913 -
2914 - if [[ ${PN} != seamonkey ]]; then
2915 - mozconfig_annotate basic_profile \
2916 - --disable-profilelocking \
2917 - --enable-single-profile \
2918 - --disable-profilesharing
2919 - fi
2920 -
2921 - # Here is a strange one...
2922 - if is-flag '-mcpu=ultrasparc*' || is-flag '-mtune=ultrasparc*'; then
2923 - mozconfig_annotate "building on ultrasparc" --enable-js-ultrasparc
2924 - fi
2925 -
2926 - # Currently --enable-elf-dynstr-gc only works for x86,
2927 - # thanks to Jason Wever <weeve@g.o> for the fix.
2928 - if use x86 && [[ ${enable_optimize} != -O0 ]]; then
2929 - mozconfig_annotate "${ARCH} optimized build" --enable-elf-dynstr-gc
2930 - fi
2931 -
2932 - # jemalloc won't build with older glibc
2933 - ! has_version ">=sys-libs/glibc-2.4" && mozconfig_annotate "we have old glibc" --disable-jemalloc
2934 -}
2935 -
2936 -# @FUNCTION: mozconfig_final
2937 -# @DESCRIPTION:
2938 -# Display a table describing all configuration options paired
2939 -# with reasons, then clean up extensions list.
2940 -# This should be called in src_configure at the end of all other mozconfig_* functions.
2941 -mozconfig_final() {
2942 - declare ac opt hash reason
2943 - echo
2944 - echo "=========================================================="
2945 - echo "Building ${PF} with the following configuration"
2946 - grep ^ac_add_options .mozconfig | while read ac opt hash reason; do
2947 - [[ -z ${hash} || ${hash} == \# ]] \
2948 - || die "error reading mozconfig: ${ac} ${opt} ${hash} ${reason}"
2949 - printf " %-30s %s\n" "${opt}" "${reason:-mozilla.org default}"
2950 - done
2951 - echo "=========================================================="
2952 - echo
2953 -
2954 - # Resolve multiple --enable-extensions down to one
2955 - declare exts=$(sed -n 's/^ac_add_options --enable-extensions=\([^ ]*\).*/\1/p' \
2956 - .mozconfig | xargs)
2957 - sed -i '/^ac_add_options --enable-extensions/d' .mozconfig
2958 - echo "ac_add_options --enable-extensions=${exts// /,}" >> .mozconfig
2959 -}
2960 -
2961 -_MOZCORECONF_V3=1
2962 -fi
2963
2964 diff --git a/eclass/mozlinguas.eclass b/eclass/mozlinguas.eclass
2965 deleted file mode 100644
2966 index adba9a9..0000000
2967 --- a/eclass/mozlinguas.eclass
2968 +++ /dev/null
2969 @@ -1,321 +0,0 @@
2970 -# Copyright 1999-2015 Gentoo Foundation
2971 -# Distributed under the terms of the GNU General Public License v2
2972 -# $Id$
2973 -
2974 -# @ECLASS: mozlinguas.eclass
2975 -# @MAINTAINER:
2976 -# mozilla@g.o
2977 -# @AUTHOR:
2978 -# Nirbheek Chauhan <nirbheek@g.o>
2979 -# Ian Stakenvicius <axs@g.o>
2980 -# @BLURB: Handle language packs for mozilla products
2981 -# @DESCRIPTION:
2982 -# Sets IUSE according to MOZ_LANGS (language packs available). Also exports
2983 -# src_unpack, src_compile and src_install for use in ebuilds, and provides
2984 -# supporting functions for langpack generation and installation.
2985 -
2986 -inherit mozextension
2987 -
2988 -case "${EAPI:-0}" in
2989 - 0|1)
2990 - die "EAPI ${EAPI:-0} does not support the '->' SRC_URI operator";;
2991 - 2|3|4|5|6)
2992 - EXPORT_FUNCTIONS src_unpack src_compile src_install;;
2993 - *)
2994 - die "EAPI ${EAPI} is not supported, contact eclass maintainers";;
2995 -esac
2996 -
2997 -# @ECLASS-VARIABLE: MOZ_LANGS
2998 -# @DESCRIPTION:
2999 -# Array containing the list of language pack xpis available for
3000 -# this release. The list can be updated with scripts/get_langs.sh from the
3001 -# mozilla overlay.
3002 -: ${MOZ_LANGS:=()}
3003 -
3004 -# @ECLASS-VARIABLE: MOZ_PV
3005 -# @DESCRIPTION:
3006 -# Ebuild package version converted to equivalent upstream version.
3007 -# Defaults to ${PV}, and should be overridden for alphas, betas, and RCs
3008 -: ${MOZ_PV:="${PV}"}
3009 -
3010 -# @ECLASS-VARIABLE: MOZ_PN
3011 -# @DESCRIPTION:
3012 -# Ebuild package name converted to equivalent upstream name.
3013 -# Defaults to ${PN}, and should be overridden for binary ebuilds.
3014 -: ${MOZ_PN:="${PN}"}
3015 -
3016 -# @ECLASS-VARIABLE: MOZ_P
3017 -# @DESCRIPTION:
3018 -# Ebuild package name + version converted to upstream equivalent.
3019 -# Defaults to ${MOZ_PN}-${MOZ_PV}
3020 -: ${MOZ_P:="${MOZ_PN}-${MOZ_PV}"}
3021 -
3022 -# @ECLASS-VARIABLE: MOZ_FTP_URI
3023 -# @DESCRIPTION:
3024 -# The ftp URI prefix for the release tarballs and language packs.
3025 -: ${MOZ_FTP_URI:=""}
3026 -
3027 -# @ECLASS-VARIABLE: MOZ_HTTP_URI
3028 -# @DESCRIPTION:
3029 -# The http URI prefix for the release tarballs and language packs.
3030 -: ${MOZ_HTTP_URI:=""}
3031 -
3032 -# @ECLASS-VARIABLE: MOZ_LANGPACK_PREFIX
3033 -# @DESCRIPTION:
3034 -# The relative path till the lang code in the langpack file URI.
3035 -# Defaults to ${MOZ_PV}/linux-i686/xpi/
3036 -: ${MOZ_LANGPACK_PREFIX:="${MOZ_PV}/linux-i686/xpi/"}
3037 -
3038 -# @ECLASS-VARIABLE: MOZ_LANGPACK_SUFFIX
3039 -# @DESCRIPTION:
3040 -# The suffix after the lang code in the langpack file URI.
3041 -# Defaults to '.xpi'
3042 -: ${MOZ_LANGPACK_SUFFIX:=".xpi"}
3043 -
3044 -# @ECLASS-VARIABLE: MOZ_LANGPACK_UNOFFICIAL
3045 -# @DESCRIPTION:
3046 -# The status of the langpack, used to differentiate within
3047 -# Manifests and on Gentoo mirrors as to when the langpacks are
3048 -# generated officially by Mozilla or if they were generated
3049 -# unofficially by others (ie the Gentoo mozilla team). When
3050 -# this var is set, the distfile will have a .unofficial.xpi
3051 -# suffix.
3052 -: ${MOZ_LANGPACK_UNOFFICIAL:=""}
3053 -
3054 -# @ECLASS-VARIABLE: MOZ_GENERATE_LANGPACKS
3055 -# @DESCRIPTION:
3056 -# This flag specifies whether or not the langpacks should be
3057 -# generated directly during the build process, rather than
3058 -# being downloaded and installed from upstream pre-built
3059 -# extensions. Primarily it supports pre-release builds.
3060 -# Defaults to empty.
3061 -: ${MOZ_GENERATE_LANGPACKS:=""}
3062 -
3063 -# @ECLASS-VARIABLE: MOZ_L10N_SOURCEDIR
3064 -# @DESCRIPTION:
3065 -# The path that l10n sources can be found at, once unpacked.
3066 -# Defaults to ${WORKDIR}/l10n-sources
3067 -: ${MOZ_L10N_SOURCEDIR:="${WORKDIR}/l10n-sources"}
3068 -
3069 -# @ECLASS-VARIABLE: MOZ_L10N_URI_PREFIX
3070 -# @DESCRIPTION:
3071 -# The full URI prefix of the distfile for each l10n locale. The
3072 -# AB_CD and MOZ_L10N_URI_SUFFIX will be appended to this to complete the
3073 -# SRC_URI when MOZ_GENERATE_LANGPACKS is set. If empty, nothing will
3074 -# be added to SRC_URI.
3075 -# Defaults to empty.
3076 -: ${MOZ_L10N_URI_PREFIX:=""}
3077 -
3078 -# @ECLASS-VARIABLE: MOZ_L10N_URI_SUFFIX
3079 -# @DESCRIPTION:
3080 -# The suffix of l10n source distfiles.
3081 -# Defaults to '.tar.xz'
3082 -: ${MOZ_L10N_URI_SUFFIX:=".tar.xz"}
3083 -
3084 -# @ECLASS-VARIABLE: MOZ_FORCE_UPSTREAM_L10N
3085 -# @DESCRIPTION:
3086 -# Set this to use upstream langpaks even if the package normally
3087 -# shouldn't (ie it is an alpha or beta package)
3088 -: ${MOZ_FORCE_UPSTREAM_L10N:=""}
3089 -
3090 -# Add linguas_* to IUSE according to available language packs
3091 -# No language packs for alphas and betas
3092 -if ! [[ -n ${MOZ_GENERATE_LANGPACKS} ]] ; then
3093 - if ! [[ ${PV} =~ alpha|beta ]] || { [[ ${PN} == seamonkey ]] && ! [[ ${PV} =~ alpha ]] ; } || [[ -n ${MOZ_FORCE_UPSTREAM_L10N} ]] ; then
3094 - [[ -z ${MOZ_FTP_URI} ]] && [[ -z ${MOZ_HTTP_URI} ]] && die "No URI set to download langpacks, please set one of MOZ_{FTP,HTTP}_URI"
3095 - for x in "${MOZ_LANGS[@]}" ; do
3096 - # en and en_US are handled internally
3097 - if [[ ${x} == en ]] || [[ ${x} == en-US ]]; then
3098 - continue
3099 - fi
3100 - SRC_URI+=" linguas_${x/-/_}? ("
3101 - [[ -n ${MOZ_FTP_URI} ]] && SRC_URI+="
3102 - ${MOZ_FTP_URI}/${MOZ_LANGPACK_PREFIX}${x}${MOZ_LANGPACK_SUFFIX} -> ${MOZ_P}-${x}${MOZ_LANGPACK_UNOFFICIAL:+.unofficial}.xpi"
3103 - [[ -n ${MOZ_HTTP_URI} ]] && SRC_URI+="
3104 - ${MOZ_HTTP_URI}/${MOZ_LANGPACK_PREFIX}${x}${MOZ_LANGPACK_SUFFIX} -> ${MOZ_P}-${x}${MOZ_LANGPACK_UNOFFICIAL:+.unofficial}.xpi"
3105 - SRC_URI+=" )"
3106 - IUSE+=" linguas_${x/-/_}"
3107 - # We used to do some magic if specific/generic locales were missing, but
3108 - # we stopped doing that due to bug 325195.
3109 - done
3110 - fi
3111 -else
3112 - for x in "${MOZ_LANGS[@]}" ; do
3113 - # en and en_US are handled internally
3114 - if [[ ${x} == en ]] || [[ ${x} == en-US ]]; then
3115 - continue
3116 - fi
3117 -# Do NOT grab l10n sources from hg tip at this time, since it is a moving target
3118 -# if [[ ${PV} =~ alpha ]]; then
3119 -# # Please note that this URI is not deterministic - digest breakage could occur
3120 -# SRC_URI+=" linguas_${x/-/_}? ( http://hg.mozilla.org/releases/l10n/mozilla-aurora/ach/archive/tip.tar.bz2 -> ${MOZ_P}-l10n-${x}.tar.bz2 )"
3121 -# elif [[ ${PV} =~ beta ]] && ! [[ ${PN} == seamonkey ]]; then
3122 -# # Please note that this URI is not deterministic - digest breakage could occur
3123 -# SRC_URI+=" linguas_${x/-/_}? ( http://hg.mozilla.org/releases/l10n/mozilla-beta/ach/archive/tip.tar.bz2 -> ${MOZ_P}-l10n-${x}.tar.bz2 )"
3124 -# elif [[ -n ${MOZ_L10N_URI_PREFIX} ]]; then
3125 - if [[ -n ${MOZ_L10N_URI_PREFIX} ]]; then
3126 - SRC_URI+=" linguas_${x/-/_}? ( ${MOZ_L10N_URI_PREFIX}${x}${MOZ_L10N_URI_SUFFIX} )"
3127 - fi
3128 - IUSE+=" linguas_${x/-/_}"
3129 - done
3130 -fi
3131 -unset x
3132 -
3133 -# @FUNCTION: mozlinguas_export
3134 -# @INTERNAL
3135 -# @DESCRIPTION:
3136 -# Generate the list of language packs called "mozlinguas"
3137 -# This list is used to unpack and install the xpi language packs
3138 -mozlinguas_export() {
3139 - if [[ ${PN} == seamonkey ]] ; then
3140 - [[ ${PV} =~ alpha ]] && ! [[ -n ${MOZ_GENERATE_LANGPACKS} ]] && return
3141 - else
3142 - [[ ${PV} =~ alpha|beta ]] && ! [[ -n ${MOZ_GENERATE_LANGPACKS} ]] && return
3143 - fi
3144 - local lingua
3145 - mozlinguas=()
3146 - for lingua in ${LINGUAS}; do
3147 - if has ${lingua} en en_US; then
3148 - # For mozilla products, en and en_US are handled internally
3149 - continue
3150 - # If this language is supported by ${P},
3151 - elif has ${lingua} "${MOZ_LANGS[@]//-/_}"; then
3152 - # Add the language to mozlinguas, if it isn't already there
3153 - has ${lingua//_/-} "${mozlinguas[@]}" || mozlinguas+=(${lingua//_/-})
3154 - continue
3155 - # For each short lingua that isn't in MOZ_LANGS,
3156 - # We used to add *all* long MOZ_LANGS to the mozlinguas list,
3157 - # but we stopped doing that due to bug 325195.
3158 - else
3159 - :
3160 - fi
3161 - ewarn "Sorry, but ${P} does not support the ${lingua} locale"
3162 - done
3163 -}
3164 -
3165 -# @FUNCTION: mozlinguas_src_unpack
3166 -# @DESCRIPTION:
3167 -# Unpack xpi language packs according to the user's LINGUAS settings
3168 -mozlinguas_src_unpack() {
3169 - local x
3170 - if ! [[ -n ${MOZ_GENERATE_LANGPACKS} ]]; then
3171 - mozlinguas_export
3172 - for x in "${mozlinguas[@]}"; do
3173 - # FIXME: Add support for unpacking xpis to portage
3174 - xpi_unpack "${MOZ_P}-${x}${MOZ_LANGPACK_UNOFFICIAL:+.unofficial}.xpi"
3175 - done
3176 - if [[ "${mozlinguas[*]}" != "" && "${mozlinguas[*]}" != "en" ]]; then
3177 - einfo "Selected language packs (first will be default): ${mozlinguas[*]}"
3178 - fi
3179 - fi
3180 -}
3181 -
3182 -# @FUNCTION: mozlinguas_mozconfig
3183 -# @DESCRIPTION:
3184 -# if applicable, add the necessary flag to .mozconfig to support
3185 -# the generation of locales. Note that this function requires
3186 -# mozconfig_annontate to already be declared via an inherit of
3187 -# mozconfig or mozcoreconf.
3188 -mozlinguas_mozconfig() {
3189 - if [[ -n ${MOZ_GENERATE_LANGPACKS} ]]; then
3190 - if declare -f mozconfig_annotate >/dev/null ; then
3191 - mozconfig_annotate 'for building locales' --with-l10n-base=${MOZ_L10N_SOURCEDIR}
3192 - else
3193 - die "Could not configure l10n-base, mozconfig_annotate not declared -- missing inherit?"
3194 - fi
3195 - fi
3196 -}
3197 -
3198 -# @FUNCTION: mozlinguas_src_compile
3199 -# @DESCRIPTION:
3200 -# if applicable, build the selected locales.
3201 -mozlinguas_src_compile() {
3202 - if [[ -n ${MOZ_GENERATE_LANGPACKS} ]]; then
3203 - # leverage BUILD_OBJ_DIR if set otherwise assume PWD.
3204 - local x y targets=( "langpack" ) localedir="${BUILD_OBJ_DIR:-.}"
3205 - case ${PN} in
3206 - *firefox)
3207 - localedir+="/browser/locales"
3208 - ;;
3209 - seamonkey)
3210 - localedir+="/suite/locales"
3211 - ;;
3212 - *thunderbird)
3213 - localedir+="/mail/locales"
3214 - targets+=( "calendar-langpack" )
3215 - ;;
3216 - *) die "Building locales for ${PN} is not supported."
3217 - esac
3218 - pushd "${localedir}" > /dev/null || die
3219 - mozlinguas_export
3220 - for x in "${mozlinguas[@]}"; do for y in "${targets[@]}"; do
3221 - emake ${y}-${x} LOCALE_MERGEDIR="./${y}-${x}"
3222 - done; done
3223 - popd > /dev/null || die
3224 - fi
3225 -}
3226 -
3227 -# @FUNCTION: mozlinguas_xpistage_langpacks
3228 -# @DESCRIPTION:
3229 -# Add extra langpacks to the xpi-stage dir for prebuilt plugins
3230 -#
3231 -# First argument is the path to the extension
3232 -# Second argument is the prefix of the source (same as first if unspecified)
3233 -# Remaining arguments are the modules in the extension that are localized
3234 -# (basename of first if unspecified)
3235 -#
3236 -# Example - installing extra langpacks for lightning:
3237 -# src_install() {
3238 -# ... # general installation steps
3239 -# mozlinguas_xpistage_langpacks \
3240 -# "${BUILD_OBJ_DIR}"/dist/xpi-stage/lightning \
3241 -# "${WORKDIR}"/lightning \
3242 -# lightning calendar
3243 -# ... # proceed with installation from the xpi-stage dir
3244 -# }
3245 -
3246 -mozlinguas_xpistage_langpacks() {
3247 - local l c modpath="${1}" srcprefix="${1}" modules=( "${1##*/}" )
3248 - shift
3249 - if [[ -n ${1} ]] ; then srcprefix="${1}" ; shift ; fi
3250 - if [[ -n ${1} ]] ; then modules=( $@ ) ; fi
3251 -
3252 - mozlinguas_export
3253 - mkdir -p "${modpath}/chrome" || die
3254 - for l in "${mozlinguas[@]}"; do for c in "${modules[@]}" ; do
3255 - if [[ -e "${srcprefix}-${l}/chrome/${c}-${l}" ]]; then
3256 - cp -RLp -t "${modpath}/chrome" "${srcprefix}-${l}/chrome/${c}-${l}" || die
3257 - grep "locale ${c} ${l} chrome/" "${srcprefix}-${l}/chrome.manifest" \
3258 - >>"${modpath}/chrome.manifest" || die
3259 - elif [[ -e "${srcprefix}/chrome/${c}-${l}" ]]; then
3260 - cp -RLp -t "${modpath}/chrome" "${srcprefix}/chrome/${c}-${l}" || die
3261 - grep "locale ${c} ${l} chrome/" "${srcprefix}/chrome.manifest" \
3262 - >>"${modpath}/chrome.manifest" || die
3263 - else
3264 - ewarn "Locale ${l} was not found for ${c}, skipping."
3265 - fi
3266 - done; done
3267 -}
3268 -
3269 -# @FUNCTION: mozlinguas_src_install
3270 -# @DESCRIPTION:
3271 -# Install xpi language packs according to the user's LINGUAS settings
3272 -# NOTE - uses ${BUILD_OBJ_DIR} or PWD if unset, for source-generated langpacks
3273 -mozlinguas_src_install() {
3274 - local x
3275 - mozlinguas_export
3276 - if [[ -n ${MOZ_GENERATE_LANGPACKS} ]]; then
3277 - local repopath="${WORKDIR}/${PN}-generated-langpacks"
3278 - mkdir -p "${repopath}"
3279 - pushd "${BUILD_OBJ_DIR:-.}"/dist/*/xpi > /dev/null || die
3280 - for x in "${mozlinguas[@]}"; do
3281 - cp "${MOZ_P}.${x}.langpack.xpi" \
3282 - "${repopath}/${MOZ_P}-${x}${MOZ_LANGPACK_UNOFFICIAL:+.unofficial}.xpi" || die
3283 - xpi_unpack "${repopath}/${MOZ_P}-${x}${MOZ_LANGPACK_UNOFFICIAL:+.unofficial}.xpi"
3284 - done
3285 - popd > /dev/null || die
3286 - fi
3287 - for x in "${mozlinguas[@]}"; do
3288 - xpi_install "${WORKDIR}/${MOZ_P}-${x}${MOZ_LANGPACK_UNOFFICIAL:+.unofficial}"
3289 - done
3290 -}