Gentoo Archives: gentoo-commits

From: "Mike Gilbert (floppym)" <floppym@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in www-client/chromium: chromium-38.0.2125.111.ebuild ChangeLog
Date: Thu, 30 Oct 2014 02:55:00
Message-Id: 20141030025455.4F26690AA@oystercatcher.gentoo.org
1 floppym 14/10/30 02:54:55
2
3 Modified: ChangeLog
4 Added: chromium-38.0.2125.111.ebuild
5 Log:
6 Stable channel bump.
7
8 (Portage version: 2.2.14/cvs/Linux x86_64, signed Manifest commit with key 0BBEEA1FEA4843A4)
9
10 Revision Changes Path
11 1.1158 www-client/chromium/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/ChangeLog?rev=1.1158&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/ChangeLog?rev=1.1158&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/ChangeLog?r1=1.1157&r2=1.1158
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v
20 retrieving revision 1.1157
21 retrieving revision 1.1158
22 diff -u -r1.1157 -r1.1158
23 --- ChangeLog 29 Oct 2014 20:22:51 -0000 1.1157
24 +++ ChangeLog 30 Oct 2014 02:54:55 -0000 1.1158
25 @@ -1,6 +1,11 @@
26 # ChangeLog for www-client/chromium
27 # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v 1.1157 2014/10/29 20:22:51 phajdan.jr Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v 1.1158 2014/10/30 02:54:55 floppym Exp $
30 +
31 +*chromium-38.0.2125.111 (30 Oct 2014)
32 +
33 + 30 Oct 2014; Mike Gilbert <floppym@g.o> +chromium-38.0.2125.111.ebuild:
34 + Stable channel bump.
35
36 *chromium-40.0.2202.3 (29 Oct 2014)
37
38
39
40
41 1.1 www-client/chromium/chromium-38.0.2125.111.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/chromium-38.0.2125.111.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/chromium-38.0.2125.111.ebuild?rev=1.1&content-type=text/plain
45
46 Index: chromium-38.0.2125.111.ebuild
47 ===================================================================
48 # Copyright 1999-2014 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/www-client/chromium/chromium-38.0.2125.111.ebuild,v 1.1 2014/10/30 02:54:55 floppym Exp $
51
52 EAPI="5"
53 PYTHON_COMPAT=( python{2_6,2_7} )
54
55 CHROMIUM_LANGS="am ar bg bn ca cs da de el en_GB es es_LA et fa fi fil fr gu he
56 hi hr hu id it ja kn ko lt lv ml mr ms nb nl pl pt_BR pt_PT ro ru sk sl sr
57 sv sw ta te th tr uk vi zh_CN zh_TW"
58
59 inherit chromium eutils flag-o-matic multilib multiprocessing pax-utils \
60 portability python-any-r1 readme.gentoo toolchain-funcs versionator virtualx
61
62 DESCRIPTION="Open-source version of Google Chrome web browser"
63 HOMEPAGE="http://chromium.org/"
64 SRC_URI="https://commondatastorage.googleapis.com/chromium-browser-official/${P}.tar.xz"
65
66 LICENSE="BSD"
67 SLOT="0"
68 KEYWORDS="~amd64 ~arm ~x86"
69 IUSE="bindist cups gnome gnome-keyring kerberos neon pic pulseaudio selinux +tcmalloc"
70
71 # Native Client binaries are compiled with different set of flags, bug #452066.
72 QA_FLAGS_IGNORED=".*\.nexe"
73
74 # Native Client binaries may be stripped by the build system, which uses the
75 # right tools for it, bug #469144 .
76 QA_PRESTRIPPED=".*\.nexe"
77
78 RDEPEND=">=app-accessibility/speech-dispatcher-0.8:=
79 app-arch/bzip2:=
80 app-arch/snappy:=
81 cups? (
82 dev-libs/libgcrypt:0=
83 >=net-print/cups-1.3.11:=
84 )
85 >=dev-libs/elfutils-0.149
86 dev-libs/expat:=
87 dev-libs/glib:=
88 dev-libs/icu:=
89 >=dev-libs/jsoncpp-0.5.0-r1:=
90 >=dev-libs/libevent-1.4.13:=
91 dev-libs/libxml2:=[icu]
92 dev-libs/libxslt:=
93 dev-libs/nspr:=
94 >=dev-libs/nss-3.14.3:=
95 dev-libs/re2:=
96 gnome? ( >=gnome-base/gconf-2.24.0:= )
97 gnome-keyring? ( >=gnome-base/libgnome-keyring-3.12:= )
98 >=media-libs/alsa-lib-1.0.19:=
99 media-libs/flac:=
100 media-libs/fontconfig:=
101 media-libs/freetype:=
102 media-libs/harfbuzz:=[icu(+)]
103 media-libs/libexif:=
104 >=media-libs/libjpeg-turbo-1.2.0-r1:=
105 media-libs/libpng:0=
106 >=media-libs/libwebp-0.4.0:=
107 media-libs/speex:=
108 pulseaudio? ( media-sound/pulseaudio:= )
109 sys-apps/dbus:=
110 sys-apps/pciutils:=
111 >=sys-libs/libcap-2.22:=
112 sys-libs/zlib:=[minizip]
113 virtual/udev
114 x11-libs/cairo:=
115 x11-libs/gdk-pixbuf:=
116 x11-libs/gtk+:2=
117 x11-libs/libdrm
118 x11-libs/libX11:=
119 x11-libs/libXcomposite:=
120 x11-libs/libXcursor:=
121 x11-libs/libXdamage:=
122 x11-libs/libXext:=
123 x11-libs/libXfixes:=
124 >=x11-libs/libXi-1.6.0:=
125 x11-libs/libXinerama:=
126 x11-libs/libXrandr:=
127 x11-libs/libXrender:=
128 x11-libs/libXScrnSaver:=
129 x11-libs/libXtst:=
130 x11-libs/pango:=
131 kerberos? ( virtual/krb5 )
132 selinux? ( sec-policy/selinux-chromium )"
133 DEPEND="${RDEPEND}
134 !arm? (
135 dev-lang/yasm
136 )
137 dev-lang/perl
138 dev-perl/JSON
139 >=dev-util/gperf-3.0.3
140 dev-util/ninja
141 sys-apps/hwids[usb(+)]
142 >=sys-devel/bison-2.4.3
143 sys-devel/flex
144 virtual/pkgconfig"
145 # For nvidia-drivers blocker, see bug #413637 .
146 RDEPEND+="
147 !=www-client/chromium-9999
148 !<www-plugins/chrome-binary-plugins-37
149 x11-misc/xdg-utils
150 virtual/opengl
151 virtual/ttf-fonts
152 tcmalloc? ( !<x11-drivers/nvidia-drivers-331.20 )"
153
154 # Python dependencies. The DEPEND part needs to be kept in sync
155 # with python_check_deps.
156 DEPEND+=" $(python_gen_any_dep '
157 dev-python/jinja[${PYTHON_USEDEP}]
158 dev-python/ply[${PYTHON_USEDEP}]
159 dev-python/simplejson[${PYTHON_USEDEP}]
160 ')"
161 python_check_deps() {
162 has_version "dev-python/jinja[${PYTHON_USEDEP}]" && \
163 has_version "dev-python/ply[${PYTHON_USEDEP}]" && \
164 has_version "dev-python/simplejson[${PYTHON_USEDEP}]"
165 }
166
167 if ! has chromium_pkg_die ${EBUILD_DEATH_HOOKS}; then
168 EBUILD_DEATH_HOOKS+=" chromium_pkg_die";
169 fi
170
171 DISABLE_AUTOFORMATTING="yes"
172 DOC_CONTENTS="
173 Some web pages may require additional fonts to display properly.
174 Try installing some of the following packages if some characters
175 are not displayed properly:
176 - media-fonts/arphicfonts
177 - media-fonts/bitstream-cyberbit
178 - media-fonts/droid
179 - media-fonts/ipamonafont
180 - media-fonts/ja-ipafonts
181 - media-fonts/takao-fonts
182 - media-fonts/wqy-microhei
183 - media-fonts/wqy-zenhei
184
185 Depending on your desktop environment, you may need
186 to install additional packages to get icons on the Downloads page.
187
188 For KDE, the required package is kde-base/oxygen-icons.
189
190 For other desktop environments, try one of the following:
191 - x11-themes/gnome-icon-theme
192 - x11-themes/tango-icon-theme
193 "
194
195 pkg_setup() {
196 if [[ "${SLOT}" == "0" ]]; then
197 CHROMIUM_SUFFIX=""
198 else
199 CHROMIUM_SUFFIX="-${SLOT}"
200 fi
201 CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser${CHROMIUM_SUFFIX}"
202
203 # Make sure the build system will use the right python, bug #344367.
204 python-any-r1_pkg_setup
205
206 chromium_suid_sandbox_check_kernel_config
207
208 if use bindist; then
209 elog "bindist enabled: H.264 video support will be disabled."
210 else
211 elog "bindist disabled: Resulting binaries may not be legal to re-distribute."
212 fi
213 }
214
215 src_prepare() {
216 # if ! use arm; then
217 # mkdir -p out/Release/gen/sdk/toolchain || die
218 # # Do not preserve SELinux context, bug #460892 .
219 # cp -a --no-preserve=context /usr/$(get_libdir)/nacl-toolchain-newlib \
220 # out/Release/gen/sdk/toolchain/linux_x86_newlib || die
221 # touch out/Release/gen/sdk/toolchain/linux_x86_newlib/stamp.untar || die
222 # fi
223
224 epatch "${FILESDIR}/${PN}-gcc-4.7-r0.patch"
225 epatch "${FILESDIR}/${PN}-system-jinja-r6.patch"
226
227 epatch_user
228
229 # Remove most bundled libraries. Some are still needed.
230 build/linux/unbundle/remove_bundled_libraries.py \
231 'base/third_party/dmg_fp' \
232 'base/third_party/dynamic_annotations' \
233 'base/third_party/icu' \
234 'base/third_party/nspr' \
235 'base/third_party/superfasthash' \
236 'base/third_party/symbolize' \
237 'base/third_party/valgrind' \
238 'base/third_party/xdg_mime' \
239 'base/third_party/xdg_user_dirs' \
240 'breakpad/src/third_party/curl' \
241 'chrome/third_party/mozilla_security_manager' \
242 'courgette/third_party' \
243 'crypto/third_party/nss' \
244 'net/third_party/mozilla_security_manager' \
245 'net/third_party/nss' \
246 'third_party/WebKit' \
247 'third_party/angle' \
248 'third_party/angle/src/third_party/compiler' \
249 'third_party/brotli' \
250 'third_party/cacheinvalidation' \
251 'third_party/cld_2' \
252 'third_party/cros_system_api' \
253 'third_party/dom_distiller_js' \
254 'third_party/dom_distiller_js/package/proto_gen/third_party/dom_distiller_js' \
255 'third_party/ffmpeg' \
256 'third_party/fips181' \
257 'third_party/flot' \
258 'third_party/hunspell' \
259 'third_party/iccjpeg' \
260 'third_party/jstemplate' \
261 'third_party/khronos' \
262 'third_party/leveldatabase' \
263 'third_party/libaddressinput' \
264 'third_party/libjingle' \
265 'third_party/libphonenumber' \
266 'third_party/libsrtp' \
267 'third_party/libusb' \
268 'third_party/libvpx' \
269 'third_party/libvpx/source/libvpx/third_party/x86inc' \
270 'third_party/libwebm' \
271 'third_party/libxml/chromium' \
272 'third_party/libXNVCtrl' \
273 'third_party/libyuv' \
274 'third_party/lss' \
275 'third_party/lzma_sdk' \
276 'third_party/mesa' \
277 'third_party/modp_b64' \
278 'third_party/mt19937ar' \
279 'third_party/npapi' \
280 'third_party/opus' \
281 'third_party/ots' \
282 'third_party/pdfium' \
283 'third_party/pdfium/third_party/logging.h' \
284 'third_party/pdfium/third_party/macros.h' \
285 'third_party/pdfium/third_party/numerics' \
286 'third_party/pdfium/third_party/template_util.h' \
287 'third_party/polymer' \
288 'third_party/protobuf' \
289 'third_party/qcms' \
290 'third_party/readability' \
291 'third_party/sfntly' \
292 'third_party/skia' \
293 'third_party/smhasher' \
294 'third_party/sqlite' \
295 'third_party/tcmalloc' \
296 'third_party/tlslite' \
297 'third_party/trace-viewer' \
298 'third_party/trace-viewer/third_party/jszip' \
299 'third_party/trace-viewer/third_party/tvcm' \
300 'third_party/trace-viewer/third_party/tvcm/third_party/d3' \
301 'third_party/trace-viewer/third_party/tvcm/third_party/gl-matrix' \
302 'third_party/trace-viewer/third_party/tvcm/third_party/polymer' \
303 'third_party/undoview' \
304 'third_party/usrsctp' \
305 'third_party/webdriver' \
306 'third_party/webrtc' \
307 'third_party/widevine' \
308 'third_party/x86inc' \
309 'third_party/zlib/google' \
310 'url/third_party/mozilla' \
311 'v8/src/third_party/kernel' \
312 'v8/src/third_party/valgrind' \
313 'v8/third_party/fdlibm' \
314 --do-remove || die
315 }
316
317 src_configure() {
318 local myconf=""
319
320 # Never tell the build system to "enable" SSE2, it has a few unexpected
321 # additions, bug #336871.
322 myconf+=" -Ddisable_sse2=1"
323
324 # Disable nacl, we can't build without pnacl (http://crbug.com/269560).
325 myconf+=" -Ddisable_nacl=1"
326
327 # Disable glibc Native Client toolchain, we don't need it (bug #417019).
328 # myconf+=" -Ddisable_glibc=1"
329
330 # TODO: also build with pnacl
331 # myconf+=" -Ddisable_pnacl=1"
332
333 # It would be awkward for us to tar the toolchain and get it untarred again
334 # during the build.
335 # myconf+=" -Ddisable_newlib_untar=1"
336
337 # Make it possible to remove third_party/adobe.
338 echo > "${T}/flapper_version.h" || die
339 myconf+=" -Dflapper_version_h_file=${T}/flapper_version.h"
340
341 # Use system-provided libraries.
342 # TODO: use_system_hunspell (upstream changes needed).
343 # TODO: use_system_libsrtp (bug #459932).
344 # TODO: use_system_libvpx (http://crbug.com/347823).
345 # TODO: use_system_libusb (http://crbug.com/266149).
346 # TODO: use_system_opus (https://code.google.com/p/webrtc/issues/detail?id=3077).
347 # TODO: use_system_protobuf (bug #503084).
348 # TODO: use_system_ssl (http://crbug.com/58087).
349 # TODO: use_system_sqlite (http://crbug.com/22208).
350 myconf+="
351 -Duse_system_bzip2=1
352 -Duse_system_flac=1
353 -Duse_system_harfbuzz=1
354 -Duse_system_icu=1
355 -Duse_system_jsoncpp=1
356 -Duse_system_libevent=1
357 -Duse_system_libjpeg=1
358 -Duse_system_libpng=1
359 -Duse_system_libwebp=1
360 -Duse_system_libxml=1
361 -Duse_system_libxslt=1
362 -Duse_system_minizip=1
363 -Duse_system_nspr=1
364 -Duse_system_re2=1
365 -Duse_system_snappy=1
366 -Duse_system_speex=1
367 -Duse_system_xdg_utils=1
368 -Duse_system_zlib=1"
369
370 # Needed for system icu - we don't need additional data files.
371 myconf+=" -Dicu_use_data_file_flag=0"
372
373 # TODO: patch gyp so that this arm conditional is not needed.
374 if ! use arm; then
375 myconf+="
376 -Duse_system_yasm=1"
377 fi
378
379 # Optional dependencies.
380 # TODO: linux_link_kerberos, bug #381289.
381 myconf+="
382 $(gyp_use cups)
383 $(gyp_use gnome use_gconf)
384 $(gyp_use gnome-keyring use_gnome_keyring)
385 $(gyp_use gnome-keyring linux_link_gnome_keyring)
386 $(gyp_use kerberos)
387 $(gyp_use pulseaudio)
388 $(gyp_use tcmalloc use_allocator tcmalloc none)"
389
390 # Use explicit library dependencies instead of dlopen.
391 # This makes breakages easier to detect by revdep-rebuild.
392 myconf+="
393 -Dlinux_link_gsettings=1
394 -Dlinux_link_libpci=1
395 -Dlinux_link_libspeechd=1
396 -Dlibspeechd_h_prefix=speech-dispatcher/"
397
398 # TODO: use the file at run time instead of effectively compiling it in.
399 myconf+="
400 -Dusb_ids_path=/usr/share/misc/usb.ids"
401
402 # Save space by removing DLOG and DCHECK messages (about 6% reduction).
403 myconf+="
404 -Dlogging_like_official_build=1"
405
406 # Never use bundled gold binary. Disable gold linker flags for now.
407 # Do not use bundled clang.
408 myconf+="
409 -Dclang=0
410 -Dhost_clang=0
411 -Dlinux_use_bundled_binutils=0
412 -Dlinux_use_bundled_gold=0
413 -Dlinux_use_gold_flags=0"
414
415 # Always support proprietary codecs.
416 myconf+=" -Dproprietary_codecs=1"
417
418 ffmpeg_branding="Chromium"
419 if ! use bindist; then
420 # Enable H.264 support in bundled ffmpeg.
421 ffmpeg_branding="Chrome"
422 fi
423 myconf+=" -Dffmpeg_branding=${ffmpeg_branding}"
424
425 # Set up Google API keys, see http://www.chromium.org/developers/how-tos/api-keys .
426 # Note: these are for Gentoo use ONLY. For your own distribution,
427 # please get your own set of keys. Feel free to contact chromium@g.o
428 # for more info.
429 myconf+=" -Dgoogle_api_key=AIzaSyDEAOvatFo0eTgsV_ZlEzx0ObmepsMzfAc
430 -Dgoogle_default_client_id=329227923882.apps.googleusercontent.com
431 -Dgoogle_default_client_secret=vgKG0NNv7GoDpbtoFNLxCUXu"
432
433 local myarch="$(tc-arch)"
434 if [[ $myarch = amd64 ]] ; then
435 target_arch=x64
436 ffmpeg_target_arch=x64
437 elif [[ $myarch = x86 ]] ; then
438 target_arch=ia32
439 ffmpeg_target_arch=ia32
440 elif [[ $myarch = arm ]] ; then
441 target_arch=arm
442 ffmpeg_target_arch=$(usex neon arm-neon arm)
443 # TODO: re-enable NaCl (NativeClient).
444 local CTARGET=${CTARGET:-${CHOST}}
445 if [[ $(tc-is-softfloat) == "no" ]]; then
446
447 myconf+=" -Darm_float_abi=hard"
448 fi
449 filter-flags "-mfpu=*"
450 use neon || myconf+=" -Darm_fpu=${ARM_FPU:-vfpv3-d16}"
451
452 if [[ ${CTARGET} == armv[78]* ]]; then
453 myconf+=" -Darmv7=1"
454 else
455 myconf+=" -Darmv7=0"
456 fi
457 myconf+=" -Dsysroot=
458 $(gyp_use neon arm_neon)
459 -Ddisable_nacl=1"
460 else
461 die "Failed to determine target arch, got '$myarch'."
462 fi
463
464 myconf+=" -Dtarget_arch=${target_arch}"
465
466 # Make sure that -Werror doesn't get added to CFLAGS by the build system.
467 # Depending on GCC version the warnings are different and we don't want
468 # the build to fail because of that.
469 myconf+=" -Dwerror="
470
471 # Disable fatal linker warnings, bug 506268.
472 myconf+=" -Ddisable_fatal_linker_warnings=1"
473
474 # Avoid CFLAGS problems, bug #352457, bug #390147.
475 if ! use custom-cflags; then
476 replace-flags "-Os" "-O2"
477 strip-flags
478
479 # Prevent linker from running out of address space, bug #471810 .
480 if use x86; then
481 filter-flags "-g*"
482 fi
483 fi
484
485 # Make sure the build system will use the right tools, bug #340795.
486 tc-export AR CC CXX RANLIB
487
488 # Tools for building programs to be executed on the build system, bug #410883.
489 export AR_host=$(tc-getBUILD_AR)
490 export CC_host=$(tc-getBUILD_CC)
491 export CXX_host=$(tc-getBUILD_CXX)
492 export LD_host=${CXX_host}
493
494 # Bug 491582.
495 export TMPDIR="${WORKDIR}/temp"
496 mkdir -m 755 "${TMPDIR}" || die
497
498 local build_ffmpeg_args=""
499 if use pic && [[ "${ffmpeg_target_arch}" == "ia32" ]]; then
500 build_ffmpeg_args+=" --disable-asm"
501 fi
502
503 # Re-configure bundled ffmpeg. See bug #491378 for example reasons.
504 einfo "Configuring bundled ffmpeg..."
505 pushd third_party/ffmpeg > /dev/null || die
506 chromium/scripts/build_ffmpeg.py linux ${ffmpeg_target_arch} \
507 --branding ${ffmpeg_branding} -- ${build_ffmpeg_args} || die
508 chromium/scripts/copy_config.sh || die
509 chromium/scripts/generate_gyp.py || die
510 popd > /dev/null || die
511
512 third_party/libaddressinput/chromium/tools/update-strings.py || die
513
514 einfo "Configuring Chromium..."
515 build/linux/unbundle/replace_gyp_files.py ${myconf} || die
516 egyp_chromium ${myconf} || die
517 }
518
519 eninja() {
520 if [[ -z ${NINJAOPTS+set} ]]; then
521 local jobs=$(makeopts_jobs)
522 local loadavg=$(makeopts_loadavg)
523
524 if [[ ${MAKEOPTS} == *-j* && ${jobs} != 999 ]]; then
525 NINJAOPTS+=" -j ${jobs}"
526 fi
527 if [[ ${MAKEOPTS} == *-l* && ${loadavg} != 999 ]]; then
528 NINJAOPTS+=" -l ${loadavg}"
529 fi
530 fi
531 set -- ninja -v ${NINJAOPTS} "$@"
532 echo "$@"
533 "$@"
534 }
535
536 src_compile() {
537 local ninja_targets="chrome chrome_sandbox chromedriver"
538
539 # Build mksnapshot and pax-mark it.
540 eninja -C out/Release mksnapshot || die
541 pax-mark m out/Release/mksnapshot
542
543 # Even though ninja autodetects number of CPUs, we respect
544 # user's options, for debugging with -j 1 or any other reason.
545 eninja -C out/Release ${ninja_targets} || die
546
547 pax-mark m out/Release/chrome
548 }
549
550 src_install() {
551 exeinto "${CHROMIUM_HOME}"
552 doexe out/Release/chrome || die
553
554 newexe out/Release/chrome_sandbox chrome-sandbox || die
555 fperms 4755 "${CHROMIUM_HOME}/chrome-sandbox"
556
557 doexe out/Release/chromedriver || die
558
559 # if ! use arm; then
560 # doexe out/Release/nacl_helper{,_bootstrap} || die
561 # insinto "${CHROMIUM_HOME}"
562 # doins out/Release/nacl_irt_*.nexe || die
563 # doins out/Release/libppGoogleNaClPluginChrome.so || die
564 # fi
565
566 local sedargs=( -e "s:/usr/lib/:/usr/$(get_libdir)/:g" )
567 if [[ -n ${CHROMIUM_SUFFIX} ]]; then
568 sedargs+=(
569 -e "s:chromium-browser:chromium-browser${CHROMIUM_SUFFIX}:g"
570 -e "s:chromium.desktop:chromium${CHROMIUM_SUFFIX}.desktop:g"
571 -e "s:plugins:plugins --user-data-dir=\${HOME}/.config/chromium${CHROMIUM_SUFFIX}:"
572 )
573 fi
574 sed "${sedargs[@]}" "${FILESDIR}/chromium-launcher-r3.sh" > chromium-launcher.sh || die
575 doexe chromium-launcher.sh
576
577 # It is important that we name the target "chromium-browser",
578 # xdg-utils expect it; bug #355517.
579 dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium-browser${CHROMIUM_SUFFIX} || die
580 # keep the old symlink around for consistency
581 dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium${CHROMIUM_SUFFIX} || die
582
583 dosym "${CHROMIUM_HOME}/chromedriver" /usr/bin/chromedriver${CHROMIUM_SUFFIX} || die
584
585 # Allow users to override command-line options, bug #357629.
586 dodir /etc/chromium || die
587 insinto /etc/chromium
588 newins "${FILESDIR}/chromium.default" "default" || die
589
590 pushd out/Release/locales > /dev/null || die
591 chromium_remove_language_paks
592 popd
593
594 insinto "${CHROMIUM_HOME}"
595 doins out/Release/*.pak || die
596
597 doins -r out/Release/locales || die
598 doins -r out/Release/resources || die
599
600 newman out/Release/chrome.1 chromium${CHROMIUM_SUFFIX}.1 || die
601 newman out/Release/chrome.1 chromium-browser${CHROMIUM_SUFFIX}.1 || die
602
603 doexe out/Release/libffmpegsumo.so || die
604 doexe out/Release/libpdf.so || die
605
606 # Install icons and desktop entry.
607 local branding size
608 for size in 16 22 24 32 48 64 128 256 ; do
609 case ${size} in
610 16|32) branding="chrome/app/theme/default_100_percent/chromium" ;;
611 *) branding="chrome/app/theme/chromium" ;;
612 esac
613 newicon -s ${size} "${branding}/product_logo_${size}.png" \
614 chromium-browser${CHROMIUM_SUFFIX}.png
615 done
616
617 local mime_types="text/html;text/xml;application/xhtml+xml;"
618 mime_types+="x-scheme-handler/http;x-scheme-handler/https;" # bug #360797
619 mime_types+="x-scheme-handler/ftp;" # bug #412185
620 mime_types+="x-scheme-handler/mailto;x-scheme-handler/webcal;" # bug #416393
621 make_desktop_entry \
622 chromium-browser${CHROMIUM_SUFFIX} \
623 "Chromium${CHROMIUM_SUFFIX}" \
624 chromium-browser${CHROMIUM_SUFFIX} \
625 "Network;WebBrowser" \
626 "MimeType=${mime_types}\nStartupWMClass=chromium-browser"
627 sed -e "/^Exec/s/$/ %U/" -i "${ED}"/usr/share/applications/*.desktop || die
628
629 # Install GNOME default application entry (bug #303100).
630 if use gnome; then
631 dodir /usr/share/gnome-control-center/default-apps || die
632 insinto /usr/share/gnome-control-center/default-apps
633 newins "${FILESDIR}"/chromium-browser.xml chromium-browser${CHROMIUM_SUFFIX}.xml || die
634 if [[ "${CHROMIUM_SUFFIX}" != "" ]]; then
635 sed "s:chromium-browser:chromium-browser${CHROMIUM_SUFFIX}:g" -i \
636 "${ED}"/usr/share/gnome-control-center/default-apps/chromium-browser${CHROMIUM_SUFFIX}.xml
637 fi
638 fi
639
640 readme.gentoo_create_doc
641 }
642
643 pkg_postinst() {
644 fdo-mime_desktop_database_update
645 gnome2_icon_cache_update
646 readme.gentoo_print_elog
647 }