Gentoo Archives: gentoo-commits

From: Ian Stakenvicius <axs@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: eclass/
Date: Sat, 09 Jul 2016 02:26:20
Message-Id: 1468031160.2e636a6097b7955770cf51510c3679a29ab817b1.axs@gentoo
1 commit: 2e636a6097b7955770cf51510c3679a29ab817b1
2 Author: Ian Stakenvicius <axs <AT> gentoo <DOT> org>
3 AuthorDate: Thu Jul 7 17:17:07 2016 +0000
4 Commit: Ian Stakenvicius <axs <AT> gentoo <DOT> org>
5 CommitDate: Sat Jul 9 02:26:00 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2e636a60
7
8 mozconfig-v6.46.eclass: removed, no inheriters.
9
10 eclass/mozconfig-v6.46.eclass | 404 ------------------------------------------
11 1 file changed, 404 deletions(-)
12
13 diff --git a/eclass/mozconfig-v6.46.eclass b/eclass/mozconfig-v6.46.eclass
14 deleted file mode 100644
15 index 0ec1e8a..0000000
16 --- a/eclass/mozconfig-v6.46.eclass
17 +++ /dev/null
18 @@ -1,404 +0,0 @@
19 -# Copyright 1999-2015 Gentoo Foundation
20 -# Distributed under the terms of the GNU General Public License v2
21 -# $Id$
22 -#
23 -# @ECLASS: mozconfig-v6.46.eclass
24 -# @MAINTAINER:
25 -# mozilla team <mozilla@g.o>
26 -# @BLURB: the new mozilla common configuration eclass for FF33 and newer, v6
27 -# @DESCRIPTION:
28 -# This eclass is used in mozilla ebuilds (firefox, thunderbird, seamonkey)
29 -# to provide a single common place for the common mozilla engine compoments.
30 -#
31 -# The eclass provides all common dependencies as well as common use flags.
32 -#
33 -# Some use flags which may be optional in particular mozilla packages can be
34 -# supported through setting eclass variables.
35 -#
36 -# This eclass inherits mozconfig helper functions as defined in mozcoreconf-v3,
37 -# and so ebuilds inheriting this eclass do not need to inherit that.
38 -
39 -case ${EAPI} in
40 - 0|1|2|3|4)
41 - die "EAPI=${EAPI} not supported"
42 - ;;
43 - 5)
44 - inherit multilib
45 - ;;
46 -esac
47 -
48 -inherit flag-o-matic toolchain-funcs mozcoreconf-v3
49 -
50 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_WIFI
51 -# @DESCRIPTION:
52 -# Set this variable before the inherit line, when an ebuild needs to provide
53 -# optional necko-wifi support via IUSE="wifi". Currently this would include
54 -# ebuilds for firefox, and potentially seamonkey.
55 -#
56 -# Leave the variable UNSET if necko-wifi support should not be available.
57 -# Set the variable to "enabled" if the use flag should be enabled by default.
58 -# Set the variable to any value if the use flag should exist but not be default-enabled.
59 -
60 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_JIT
61 -# @DESCRIPTION:
62 -# Set this variable before the inherit line, when an ebuild needs to provide
63 -# optional necko-wifi support via IUSE="jit". Currently this would include
64 -# ebuilds for firefox, and potentially seamonkey.
65 -#
66 -# Leave the variable UNSET if optional jit support should not be available.
67 -# Set the variable to "enabled" if the use flag should be enabled by default.
68 -# Set the variable to any value if the use flag should exist but not be default-enabled.
69 -
70 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK3
71 -# @DESCRIPTION:
72 -# Set this variable before the inherit line, when an ebuild can provide
73 -# optional gtk3 support via IUSE="gtk3". Currently this would include
74 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
75 -#
76 -# Leave the variable UNSET if gtk3 support should not be available.
77 -# Set the variable to "enabled" if the use flag should be enabled by default.
78 -# Set the variable to any value if the use flag should exist but not be default-enabled.
79 -
80 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_GTK2ONLY
81 -# @DESCRIPTION:
82 -# Set this variable before the inherit line, when an ebuild can provide
83 -# optional gtk2-only support via IUSE="gtk2".
84 -#
85 -# Note that this option conflicts directly with MOZCONFIG_OPTIONAL_GTK3, both
86 -# variables cannot be set at the same time and this variable will be ignored if
87 -# MOZCONFIG_OPTIONAL_GTK3 is set.
88 -#
89 -# Leave the variable UNSET if gtk2-only support should not be available.
90 -# Set the variable to "enabled" if the use flag should be enabled by default.
91 -# Set the variable to any value if the use flag should exist but not be default-enabled.
92 -
93 -# @ECLASS-VARIABLE: MOZCONFIG_OPTIONAL_QT5
94 -# @DESCRIPTION:
95 -# Set this variable before the inherit line, when an ebuild can provide
96 -# optional qt5 support via IUSE="qt5". Currently this would include
97 -# ebuilds for firefox, but thunderbird and seamonkey could follow in the future.
98 -#
99 -# Leave the variable UNSET if qt5 support should not be available.
100 -# Set the variable to "enabled" if the use flag should be enabled by default.
101 -# Set the variable to any value if the use flag should exist but not be default-enabled.
102 -
103 -# use-flags common among all mozilla ebuilds
104 -IUSE="${IUSE} dbus debug +ffmpeg +jemalloc3 neon pulseaudio selinux startup-notification system-cairo
105 - system-harfbuzz system-icu system-jpeg system-libevent system-sqlite system-libvpx"
106 -
107 -# some notes on deps:
108 -# gtk:2 minimum is technically 2.10 but gio support (enabled by default) needs 2.14
109 -# media-libs/mesa needs to be 10.2 or above due to a bug with flash+vdpau
110 -
111 -RDEPEND=">=app-text/hunspell-1.2
112 - dev-libs/atk
113 - dev-libs/expat
114 - >=x11-libs/cairo-1.10[X]
115 - >=x11-libs/gtk+-2.18:2
116 - x11-libs/gdk-pixbuf
117 - >=x11-libs/pango-1.22.0
118 - >=media-libs/libpng-1.6.19:0=[apng]
119 - >=media-libs/mesa-10.2:*
120 - media-libs/fontconfig
121 - >=media-libs/freetype-2.4.10
122 - kernel_linux? ( media-libs/alsa-lib )
123 - pulseaudio? ( media-sound/pulseaudio )
124 - virtual/freedesktop-icon-theme
125 - dbus? ( >=sys-apps/dbus-0.60
126 - >=dev-libs/dbus-glib-0.72 )
127 - startup-notification? ( >=x11-libs/startup-notification-0.8 )
128 - >=dev-libs/glib-2.26:2
129 - >=sys-libs/zlib-1.2.3
130 - >=virtual/libffi-3.0.10
131 - ffmpeg? ( virtual/ffmpeg )
132 - x11-libs/libX11
133 - x11-libs/libXcomposite
134 - x11-libs/libXdamage
135 - x11-libs/libXext
136 - x11-libs/libXfixes
137 - x11-libs/libXrender
138 - x11-libs/libXt
139 - system-cairo? ( >=x11-libs/cairo-1.12[X,xcb] >=x11-libs/pixman-0.19.2 )
140 - system-icu? ( >=dev-libs/icu-51.1:= )
141 - system-jpeg? ( >=media-libs/libjpeg-turbo-1.2.1 )
142 - system-libevent? ( =dev-libs/libevent-2.0*:0= )
143 - system-sqlite? ( >=dev-db/sqlite-3.10.2:3[secure-delete,debug=] )
144 - system-libvpx? ( >=media-libs/libvpx-1.3.0:0=[postproc,svc(-)] )
145 - system-harfbuzz? ( >=media-libs/harfbuzz-1.1.3:0=[graphite,icu] >=media-gfx/graphite2-1.3.8 )
146 -"
147 -
148 -if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
149 - MOZCONFIG_OPTIONAL_GTK2ONLY=
150 - if [[ ${MOZCONFIG_OPTIONAL_GTK3} = "enabled" ]]; then
151 - IUSE+=" +gtk3"
152 - else
153 - IUSE+=" gtk3"
154 - fi
155 - RDEPEND+="
156 - gtk3? ( >=x11-libs/gtk+-3.4.0:3 )"
157 -elif [[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]]; then
158 - if [[ ${MOZCONFIG_OPTIONAL_GTK2ONLY} = "enabled" ]]; then
159 - IUSE+=" +gtk2"
160 - else
161 - IUSE+=" gtk2"
162 - fi
163 - RDEPEND+="
164 - !gtk2? ( >=x11-libs/gtk+-3.4.0:3 )"
165 -fi
166 -if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
167 - inherit qmake-utils
168 - if [[ ${MOZCONFIG_OPTIONAL_QT5} = "enabled" ]]; then
169 - IUSE+=" +qt5"
170 - else
171 - IUSE+=" qt5"
172 - fi
173 - RDEPEND+="
174 - qt5? (
175 - dev-qt/qtcore:5
176 - dev-qt/qtgui:5
177 - dev-qt/qtnetwork:5
178 - dev-qt/qtprintsupport:5
179 - dev-qt/qtwidgets:5
180 - dev-qt/qtxml:5
181 - dev-qt/qtdeclarative:5
182 - )"
183 -fi
184 -if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]]; then
185 - if [[ ${MOZCONFIG_OPTIONAL_WIFI} = "enabled" ]]; then
186 - IUSE+=" +wifi"
187 - else
188 - IUSE+=" wifi"
189 - fi
190 - RDEPEND+="
191 - wifi? (
192 - kernel_linux? ( >=sys-apps/dbus-0.60
193 - >=dev-libs/dbus-glib-0.72
194 - net-misc/networkmanager )
195 - )"
196 -fi
197 -if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
198 - if [[ ${MOZCONFIG_OPTIONAL_JIT} = "enabled" ]]; then
199 - IUSE+=" +jit"
200 - else
201 - IUSE+=" jit"
202 - fi
203 -fi
204 -
205 -DEPEND="app-arch/zip
206 - app-arch/unzip
207 - >=sys-devel/binutils-2.16.1
208 - ${RDEPEND}"
209 -
210 -RDEPEND+="
211 - selinux? ( sec-policy/selinux-mozilla )"
212 -
213 -# force system-icu if system-harfbuzz is selected, to avoid potential ABI issues
214 -REQUIRED_USE="
215 - system-harfbuzz? ( system-icu )"
216 -
217 -# only one of gtk3 or qt5 should be permitted to be selected, since only one will be used.
218 -[[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]] && [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]] && \
219 - REQUIRED_USE+=" ?? ( gtk3 qt5 )"
220 -
221 -# only one of gtk2 or qt5 should be permitted to be selected, since only one will be used.
222 -[[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]] && [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]] && \
223 - REQUIRED_USE+=" ?? ( gtk2 qt5 )"
224 -
225 -# @FUNCTION: mozconfig_config
226 -# @DESCRIPTION:
227 -# Set common configure options for mozilla packages.
228 -# Call this within src_configure() phase, after mozconfig_init
229 -#
230 -# Example:
231 -#
232 -# inherit mozconfig-v6.46
233 -#
234 -# src_configure() {
235 -# mozconfig_init
236 -# mozconfig_config
237 -# # ... misc ebuild-unique settings via calls to
238 -# # ... mozconfig_{annotate,use_with,use_enable}
239 -# mozconfig_final
240 -# }
241 -
242 -mozconfig_config() {
243 - # Migrated from mozcoreconf-2
244 - mozconfig_annotate 'system_libs' \
245 - --with-system-zlib \
246 - --enable-pango \
247 - --enable-svg \
248 - --with-system-bz2
249 -
250 - if has bindist ${IUSE}; then
251 - mozconfig_use_enable !bindist official-branding
252 - if [[ ${PN} == firefox ]] && use bindist ; then
253 - mozconfig_annotate '' --with-branding=browser/branding/aurora
254 - fi
255 - fi
256 -
257 - mozconfig_use_enable debug
258 - mozconfig_use_enable debug tests
259 -
260 - if ! use debug ; then
261 - mozconfig_annotate 'disabled by Gentoo' --disable-debug-symbols
262 - else
263 - mozconfig_annotate 'enabled by Gentoo' --enable-debug-symbols
264 - fi
265 -
266 - mozconfig_use_enable startup-notification
267 -
268 - if [[ -n ${MOZCONFIG_OPTIONAL_WIFI} ]] ; then
269 - # wifi pulls in dbus so manage both here
270 - mozconfig_use_enable wifi necko-wifi
271 - if use kernel_linux && use wifi && ! use dbus; then
272 - echo "Enabling dbus support due to wifi request"
273 - mozconfig_annotate 'dbus required by necko-wifi on linux' --enable-dbus
274 - else
275 - mozconfig_use_enable dbus
276 - fi
277 - else
278 - mozconfig_use_enable dbus
279 - mozconfig_annotate 'disabled' --disable-necko-wifi
280 - fi
281 -
282 - # These are forced-on for webm support
283 - mozconfig_annotate 'required' --enable-ogg
284 - mozconfig_annotate 'required' --enable-wave
285 -
286 - if [[ -n ${MOZCONFIG_OPTIONAL_JIT} ]]; then
287 - mozconfig_use_enable jit ion
288 - fi
289 -
290 - # These are enabled by default in all mozilla applications
291 - mozconfig_annotate '' --with-system-nspr --with-nspr-prefix="${EPREFIX}"/usr
292 - mozconfig_annotate '' --with-system-nss --with-nss-prefix="${EPREFIX}"/usr
293 - mozconfig_annotate '' --x-includes="${EPREFIX}"/usr/include --x-libraries="${EPREFIX}"/usr/$(get_libdir)
294 - if use system-libevent; then
295 - mozconfig_annotate '' --with-system-libevent="${EPREFIX}"/usr
296 - fi
297 - mozconfig_annotate '' --prefix="${EPREFIX}"/usr
298 - mozconfig_annotate '' --libdir="${EPREFIX}"/usr/$(get_libdir)
299 - mozconfig_annotate 'Gentoo default' --enable-system-hunspell
300 - mozconfig_annotate '' --disable-gnomeui
301 - mozconfig_annotate '' --enable-gio
302 - mozconfig_annotate '' --disable-crashreporter
303 - mozconfig_annotate 'Gentoo default' --with-system-png
304 - mozconfig_annotate '' --enable-system-ffi
305 - mozconfig_annotate 'Gentoo default to honor system linker' --disable-gold
306 - mozconfig_annotate 'Gentoo default' --disable-skia
307 - mozconfig_annotate '' --disable-gconf
308 - mozconfig_annotate '' --with-intl-api
309 -
310 - # default toolkit is cairo-gtk2, optional use flags can change this
311 - local toolkit="cairo-gtk2"
312 - local toolkit_comment=""
313 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK3} ]]; then
314 - if use gtk3; then
315 - toolkit="cairo-gtk3"
316 - toolkit_comment="gtk3 use flag"
317 - fi
318 - fi
319 - if [[ -n ${MOZCONFIG_OPTIONAL_GTK2ONLY} ]]; then
320 - if ! use gtk2 ; then
321 - toolkit="cairo-gtk3"
322 - else
323 - toolkit_comment="gtk2 use flag"
324 - fi
325 - fi
326 - if [[ -n ${MOZCONFIG_OPTIONAL_QT5} ]]; then
327 - if use qt5; then
328 - toolkit="cairo-qt"
329 - toolkit_comment="qt5 use flag"
330 - # need to specify these vars because the qt5 versions are not found otherwise,
331 - # and setting --with-qtdir overrides the pkg-config include dirs
332 - local i
333 - for i in qmake moc rcc; do
334 - echo "export HOST_${i^^}=\"$(qt5_get_bindir)/${i}\"" \
335 - >> "${S}"/.mozconfig || die
336 - done
337 - echo 'unset QTDIR' >> "${S}"/.mozconfig || die
338 - mozconfig_annotate '+qt5' --disable-gio
339 - fi
340 - fi
341 - mozconfig_annotate "${toolkit_comment}" --enable-default-toolkit=${toolkit}
342 -
343 - # Use jemalloc unless libc is not glibc >= 2.4
344 - # at this time the minimum glibc in the tree is 2.9 so we should be safe.
345 - if use elibc_glibc && use jemalloc3; then
346 - # We must force-enable jemalloc 3 via .mozconfig
347 - echo "export MOZ_JEMALLOC3=1" >> "${S}"/.mozconfig || die
348 - mozconfig_annotate '' --enable-jemalloc
349 - mozconfig_annotate '' --enable-replace-malloc
350 - fi
351 -
352 - mozconfig_annotate '' --target="${CTARGET:-${CHOST}}"
353 - mozconfig_annotate '' --build="${CTARGET:-${CHOST}}"
354 -
355 - use ffmpeg || mozconfig_annotate '-ffmpeg' --disable-ffmpeg
356 - mozconfig_use_enable pulseaudio
357 -
358 - mozconfig_use_enable system-cairo
359 - mozconfig_use_enable system-sqlite
360 - mozconfig_use_with system-jpeg
361 - mozconfig_use_with system-icu
362 - mozconfig_use_with system-libvpx
363 - mozconfig_use_with system-harfbuzz
364 - mozconfig_use_with system-harfbuzz system-graphite2
365 -
366 - # Modifications to better support ARM, bug 553364
367 - if use neon ; then
368 - mozconfig_annotate '' --with-fpu=neon
369 - mozconfig_annotate '' --with-thumb=yes
370 - mozconfig_annotate '' --with-thumb-interwork=no
371 - fi
372 - if [[ ${CHOST} == armv* ]] ; then
373 - mozconfig_annotate '' --with-float-abi=hard
374 - mozconfig_annotate '' --enable-skia
375 -
376 - if ! use system-libvpx ; then
377 - sed -i -e "s|softfp|hard|" \
378 - "${S}"/media/libvpx/moz.build
379 - fi
380 - fi
381 -}
382 -
383 -# @FUNCTION: mozconfig_install_prefs
384 -# @DESCRIPTION:
385 -# Set preferences into the prefs.js file specified as a parameter to
386 -# the function. This sets both some common prefs to all mozilla
387 -# packages, and any prefs that may relate to the use flags administered
388 -# by mozconfig_config().
389 -#
390 -# Call this within src_install() phase, after copying the template
391 -# prefs file (if any) from ${FILESDIR}
392 -#
393 -# Example:
394 -#
395 -# inherit mozconfig-v6.46
396 -#
397 -# src_install() {
398 -# cp "${FILESDIR}"/gentoo-default-prefs.js \
399 -# "${BUILD_OBJ_DIR}/dist/bin/browser/defaults/preferences/all-gentoo.js" \
400 -# || die
401 -#
402 -# mozconfig_install_prefs \
403 -# "${BUILD_OBJ_DIR}/dist/bin/browser/defaults/preferences/all-gentoo.js"
404 -#
405 -# ...
406 -# }
407 -
408 -mozconfig_install_prefs() {
409 - local prefs_file="${1}"
410 -
411 - einfo "Adding prefs from mozconfig to ${prefs_file}"
412 -
413 - # set dictionary path, to use system hunspell
414 - echo "pref(\"spellchecker.dictionary_path\", \"${EPREFIX}/usr/share/myspell\");" \
415 - >>"${prefs_file}" || die
416 -
417 - # force the graphite pref if system-harfbuzz is enabled, since the pref cant disable it
418 - if use system-harfbuzz ; then
419 - echo "sticky_pref(\"gfx.font_rendering.graphite.enabled\",true);" \
420 - >>"${prefs_file}" || die
421 - fi
422 -}