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-23.0.1271.91.ebuild ChangeLog
Date: Tue, 27 Nov 2012 02:59:50
Message-Id: 20121127025935.EBD4F20C63@flycatcher.gentoo.org
1 floppym 12/11/27 02:59:35
2
3 Modified: ChangeLog
4 Added: chromium-23.0.1271.91.ebuild
5 Log:
6 Stable channel bump.
7
8 (Portage version: 2.2.0_alpha142/cvs/Linux x86_64, signed Manifest commit with key 0BBEEA1FEA4843A4)
9
10 Revision Changes Path
11 1.755 www-client/chromium/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/ChangeLog?rev=1.755&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/ChangeLog?rev=1.755&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/ChangeLog?r1=1.754&r2=1.755
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v
20 retrieving revision 1.754
21 retrieving revision 1.755
22 diff -u -r1.754 -r1.755
23 --- ChangeLog 26 Nov 2012 01:59:36 -0000 1.754
24 +++ ChangeLog 27 Nov 2012 02:59:35 -0000 1.755
25 @@ -1,6 +1,11 @@
26 # ChangeLog for www-client/chromium
27 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v 1.754 2012/11/26 01:59:36 phajdan.jr Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v 1.755 2012/11/27 02:59:35 floppym Exp $
30 +
31 +*chromium-23.0.1271.91 (27 Nov 2012)
32 +
33 + 27 Nov 2012; Mike Gilbert <floppym@g.o> +chromium-23.0.1271.91.ebuild:
34 + Stable channel bump.
35
36 26 Nov 2012; Pawel Hajdan jr <phajdan.jr@g.o>
37 chromium-25.0.1323.1.ebuild, chromium-9999-r1.ebuild:
38
39
40
41 1.1 www-client/chromium/chromium-23.0.1271.91.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/chromium-23.0.1271.91.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/chromium/chromium-23.0.1271.91.ebuild?rev=1.1&content-type=text/plain
45
46 Index: chromium-23.0.1271.91.ebuild
47 ===================================================================
48 # Copyright 1999-2012 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/www-client/chromium/chromium-23.0.1271.91.ebuild,v 1.1 2012/11/27 02:59:35 floppym Exp $
51
52 EAPI="4"
53 PYTHON_DEPEND="2:2.6"
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 \
60 pax-utils portability python toolchain-funcs versionator virtualx
61
62 DESCRIPTION="Open-source version of Google Chrome web browser"
63 HOMEPAGE="http://chromium.org/"
64 SRC_URI="http://commondatastorage.googleapis.com/chromium-browser-official/${P}.tar.bz2"
65
66 LICENSE="BSD"
67 SLOT="0"
68 KEYWORDS="~amd64 ~x86"
69 IUSE="bindist cups gnome gnome-keyring kerberos pulseaudio selinux tcmalloc"
70
71 RDEPEND="app-arch/bzip2
72 cups? (
73 dev-libs/libgcrypt
74 >=net-print/cups-1.3.11
75 )
76 >=dev-lang/v8-3.11.10.6
77 >=dev-libs/elfutils-0.149
78 dev-libs/expat
79 >=dev-libs/icu-49.1.1-r1
80 >=dev-libs/libevent-1.4.13
81 dev-libs/libxml2[icu]
82 dev-libs/libxslt
83 >=dev-libs/nss-3.12.3
84 gnome? ( >=gnome-base/gconf-2.24.0 )
85 gnome-keyring? ( >=gnome-base/gnome-keyring-2.28.2 )
86 >=media-libs/alsa-lib-1.0.19
87 media-libs/flac
88 >=media-libs/libjpeg-turbo-1.2.0-r1
89 media-libs/libpng
90 >=media-libs/libwebp-0.2.0_rc1
91 media-libs/speex
92 pulseaudio? ( media-sound/pulseaudio )
93 sys-apps/dbus
94 sys-fs/udev
95 virtual/libusb:1
96 x11-libs/gtk+:2
97 x11-libs/libXinerama
98 x11-libs/libXScrnSaver
99 x11-libs/libXtst
100 kerberos? ( virtual/krb5 )
101 selinux? (
102 sec-policy/selinux-chromium
103 sys-libs/libselinux
104 )"
105 DEPEND="${RDEPEND}
106 >=dev-lang/nacl-toolchain-newlib-0_p9093
107 dev-lang/perl
108 dev-lang/yasm
109 dev-python/ply
110 dev-python/simplejson
111 >=dev-util/gperf-3.0.3
112 >=sys-devel/bison-2.4.3
113 sys-devel/flex
114 >=sys-devel/make-3.81-r2
115 virtual/pkgconfig
116 test? ( dev-python/pyftpdlib )"
117 RDEPEND+="
118 !=www-client/chromium-9999
119 x11-misc/xdg-utils
120 virtual/ttf-fonts"
121
122 if ! has chromium_pkg_die ${EBUILD_DEATH_HOOKS}; then
123 EBUILD_DEATH_HOOKS+=" chromium_pkg_die";
124 fi
125
126 pkg_setup() {
127 if [[ "${SLOT}" == "0" ]]; then
128 CHROMIUM_SUFFIX=""
129 else
130 CHROMIUM_SUFFIX="-${SLOT}"
131 fi
132 CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser${CHROMIUM_SUFFIX}"
133
134 # Make sure the build system will use the right tools, bug #340795.
135 tc-export AR CC CXX RANLIB
136
137 # Make sure the build system will use the right python, bug #344367.
138 python_set_active_version 2
139 python_pkg_setup
140
141 if ! use selinux; then
142 chromium_suid_sandbox_check_kernel_config
143 fi
144
145 if use bindist; then
146 elog "bindist enabled: H.264 video support will be disabled."
147 else
148 elog "bindist disabled: Resulting binaries may not be legal to re-distribute."
149 fi
150 }
151
152 src_prepare() {
153 if ! use arm; then
154 ebegin "Preparing NaCl newlib toolchain"
155 pushd "${T}" >/dev/null || die
156 mkdir sdk || die
157 cp -a /usr/$(get_libdir)/nacl-toolchain-newlib sdk/nacl-sdk || die
158 mkdir -p "${S}"/native_client/toolchain/.tars || die
159 tar czf "${S}"/native_client/toolchain/.tars/naclsdk_linux_x86.tgz sdk || die
160 popd >/dev/null || die
161 eend $?
162 fi
163
164 # zlib-1.2.5.1-r1 renames the OF macro in zconf.h, bug 383371.
165 # sed -i '1i#define OF(x) x' \
166 # third_party/zlib/contrib/minizip/{ioapi,{,un}zip}.h || die
167
168 # Fix build without NaCl glibc toolchain.
169 epatch "${FILESDIR}/${PN}-ppapi-r0.patch"
170
171 # Fix unnecessary dependency on dbus-glib, bug #434346.
172 epatch "${FILESDIR}/${PN}-dbus-glib-r0.patch"
173
174 # Fix build with system ICU.
175 epatch "${FILESDIR}/${PN}-system-icu-r0.patch"
176
177 # Fix build with system speex, bug #432748.
178 epatch "${FILESDIR}/${PN}-system-speex-r0.patch"
179
180 # Missing gyp files in tarball.
181 # https://code.google.com/p/chromium/issues/detail?id=144823
182 if [[ -e chrome/test/data/nacl/nacl_test_data.gyp ]]; then
183 die "tarball fixed, please remove workaround"
184 fi
185
186 mkdir -p chrome/test/data/nacl
187 cat > chrome/test/data/nacl/nacl_test_data.gyp <<-EOF
188 {
189 'targets': [
190 {
191 'target_name': 'nacl_tests',
192 'type': 'none',
193 },
194 ],
195 }
196 EOF
197
198 epatch_user
199
200 # Remove most bundled libraries. Some are still needed.
201 find third_party -type f \! -iname '*.gyp*' \
202 \! -path 'third_party/WebKit/*' \
203 \! -path 'third_party/angle/*' \
204 \! -path 'third_party/cacheinvalidation/*' \
205 \! -path 'third_party/cld/*' \
206 \! -path 'third_party/ffmpeg/*' \
207 \! -path 'third_party/flac/flac.h' \
208 \! -path 'third_party/flot/*' \
209 \! -path 'third_party/gpsd/*' \
210 \! -path 'third_party/harfbuzz/*' \
211 \! -path 'third_party/hunspell/*' \
212 \! -path 'third_party/hyphen/*' \
213 \! -path 'third_party/iccjpeg/*' \
214 \! -path 'third_party/jsoncpp/*' \
215 \! -path 'third_party/khronos/*' \
216 \! -path 'third_party/launchpad_translations/*' \
217 \! -path 'third_party/leveldatabase/*' \
218 \! -path 'third_party/libjingle/*' \
219 \! -path 'third_party/libphonenumber/*' \
220 \! -path 'third_party/libsrtp/*' \
221 \! -path 'third_party/libusb/libusb.h' \
222 \! -path 'third_party/libva/*' \
223 \! -path 'third_party/libvpx/*' \
224 \! -path 'third_party/libxml/chromium/*' \
225 \! -path 'third_party/libXNVCtrl/*' \
226 \! -path 'third_party/libyuv/*' \
227 \! -path 'third_party/lss/*' \
228 \! -path 'third_party/mesa/*' \
229 \! -path 'third_party/modp_b64/*' \
230 \! -path 'third_party/mongoose/*' \
231 \! -path 'third_party/mt19937ar/*' \
232 \! -path 'third_party/npapi/*' \
233 \! -path 'third_party/openmax/*' \
234 \! -path 'third_party/ots/*' \
235 \! -path 'third_party/protobuf/*' \
236 \! -path 'third_party/qcms/*' \
237 \! -path 'third_party/re2/*' \
238 \! -path 'third_party/scons-2.0.1/*' \
239 \! -path 'third_party/sfntly/*' \
240 \! -path 'third_party/skia/*' \
241 \! -path 'third_party/smhasher/*' \
242 \! -path 'third_party/speex/speex.h' \
243 \! -path 'third_party/sqlite/*' \
244 \! -path 'third_party/tcmalloc/*' \
245 \! -path 'third_party/tlslite/*' \
246 \! -path 'third_party/trace-viewer/*' \
247 \! -path 'third_party/undoview/*' \
248 \! -path 'third_party/v8-i18n/*' \
249 \! -path 'third_party/webdriver/*' \
250 \! -path 'third_party/webgl_conformance/*' \
251 \! -path 'third_party/webrtc/*' \
252 \! -path 'third_party/zlib/*' \
253 -delete || die
254
255 local v8_bundled="$(chromium_bundled_v8_version)"
256 local v8_installed="$(chromium_installed_v8_version)"
257 einfo "V8 version: bundled - ${v8_bundled}; installed - ${v8_installed}"
258
259 # Remove bundled v8.
260 find v8 -type f \! -iname '*.gyp*' -delete || die
261
262 # The implementation files include v8 headers with full path,
263 # like #include "v8/include/v8.h". Make sure the system headers
264 # will be used.
265 # TODO: find a solution that can be upstreamed.
266 rmdir v8/include || die
267 ln -s /usr/include v8/include || die
268
269 # Make sure the build system will use the right python, bug #344367.
270 # Only convert directories that need it, to save time.
271 python_convert_shebangs -q -r 2 build tools
272 }
273
274 src_configure() {
275 local myconf=""
276
277 # Never tell the build system to "enable" SSE2, it has a few unexpected
278 # additions, bug #336871.
279 myconf+=" -Ddisable_sse2=1"
280
281 # Optional tcmalloc. Note it causes problems with e.g. NVIDIA
282 # drivers, bug #413637.
283 myconf+=" $(gyp_use tcmalloc linux_use_tcmalloc)"
284
285 # Disable glibc Native Client toolchain, we don't need it (bug #417019).
286 myconf+=" -Ddisable_glibc=1"
287
288 # TODO: also build with pnacl
289 myconf+=" -Ddisable_pnacl=1"
290
291 # Make it possible to remove third_party/adobe.
292 echo > "${T}/flapper_version.h" || die
293 myconf+=" -Dflapper_version_h_file=${T}/flapper_version.h"
294
295 # Use system-provided libraries.
296 # TODO: use_system_ffmpeg
297 # TODO: use_system_hunspell (upstream changes needed).
298 # TODO: use_system_speex (needs additional shims, bug #432748).
299 # TODO: use_system_ssl (http://crbug.com/58087).
300 # TODO: use_system_sqlite (http://crbug.com/22208).
301 # TODO: use_system_vpx
302 # TODO: use_system_zlib (forked, bug #432746).
303 myconf+="
304 -Duse_system_bzip2=1
305 -Duse_system_flac=1
306 -Duse_system_icu=1
307 -Duse_system_libevent=1
308 -Duse_system_libjpeg=1
309 -Duse_system_libpng=1
310 -Duse_system_libusb=1
311 -Duse_system_libwebp=1
312 -Duse_system_libxml=1
313 -Duse_system_speex=1
314 -Duse_system_v8=1
315 -Duse_system_xdg_utils=1
316 -Duse_system_yasm=1
317 -Duse_system_zlib=0"
318
319 # Optional dependencies.
320 # TODO: linux_link_kerberos, bug #381289.
321 myconf+="
322 $(gyp_use cups)
323 $(gyp_use gnome use_gconf)
324 $(gyp_use gnome-keyring use_gnome_keyring)
325 $(gyp_use gnome-keyring linux_link_gnome_keyring)
326 $(gyp_use kerberos)
327 $(gyp_use pulseaudio)
328 $(gyp_use selinux selinux)"
329
330 # Use explicit library dependencies instead of dlopen.
331 # This makes breakages easier to detect by revdep-rebuild.
332 myconf+="
333 -Dlinux_link_gsettings=1"
334
335 if ! use selinux; then
336 # Enable SUID sandbox.
337 myconf+="
338 -Dlinux_sandbox_path=${CHROMIUM_HOME}/chrome_sandbox
339 -Dlinux_sandbox_chrome_path=${CHROMIUM_HOME}/chrome"
340 fi
341
342 # Never use bundled gold binary. Disable gold linker flags for now.
343 myconf+="
344 -Dlinux_use_gold_binary=0
345 -Dlinux_use_gold_flags=0"
346
347 if ! use bindist; then
348 # Enable H.624 support in bundled ffmpeg.
349 myconf+=" -Dproprietary_codecs=1 -Dffmpeg_branding=Chrome"
350 fi
351
352 local myarch="$(tc-arch)"
353 if [[ $myarch = amd64 ]] ; then
354 myconf+=" -Dtarget_arch=x64"
355 elif [[ $myarch = x86 ]] ; then
356 myconf+=" -Dtarget_arch=ia32"
357 elif [[ $myarch = arm ]] ; then
358 # TODO: re-enable NaCl (NativeClient).
359 myconf+=" -Dtarget_arch=arm
360 -Darm_neon=0
361 -Ddisable_nacl=1"
362 else
363 die "Failed to determine target arch, got '$myarch'."
364 fi
365
366 # Make sure that -Werror doesn't get added to CFLAGS by the build system.
367 # Depending on GCC version the warnings are different and we don't want
368 # the build to fail because of that.
369 myconf+=" -Dwerror="
370
371 # Avoid CFLAGS problems, bug #352457, bug #390147.
372 if ! use custom-cflags; then
373 replace-flags "-Os" "-O2"
374 strip-flags
375 fi
376
377 egyp_chromium ${myconf} || die
378 }
379
380 src_compile() {
381 local test_targets
382 for x in base cacheinvalidation crypto \
383 googleurl gpu media net printing sql; do
384 test_targets+=" ${x}_unittests"
385 done
386
387 local make_targets="chrome chromedriver"
388 if ! use selinux; then
389 make_targets+=" chrome_sandbox"
390 fi
391 if use test; then
392 make_targets+=$test_targets
393 fi
394
395 # See bug #410883 for more info about the .host mess.
396 emake ${make_targets} BUILDTYPE=Release V=1 \
397 CC.host="$(tc-getCC)" CFLAGS.host="${CFLAGS}" \
398 CXX.host="$(tc-getCXX)" CXXFLAGS.host="${CXXFLAGS}" \
399 LINK.host="$(tc-getCXX)" LDFLAGS.host="${LDFLAGS}" \
400 AR.host="$(tc-getAR)" || die
401
402 pax-mark m out/Release/chrome
403 if use test; then
404 for x in $test_targets; do
405 pax-mark m out/Release/${x}
406 done
407 fi
408 }
409
410 src_test() {
411 # For more info see bug #350349.
412 local mylocale='en_US.utf8'
413 if ! locale -a | grep -q "$mylocale"; then
414 eerror "${PN} requires ${mylocale} locale for tests"
415 eerror "Please read the following guides for more information:"
416 eerror " http://www.gentoo.org/doc/en/guide-localization.xml"
417 eerror " http://www.gentoo.org/doc/en/utf-8.xml"
418 die "locale ${mylocale} is not supported"
419 fi
420
421 # For more info see bug #370957.
422 if [[ $UID -eq 0 ]]; then
423 die "Tests must be run as non-root. Please use FEATURES=userpriv."
424 fi
425
426 runtest() {
427 local cmd=$1
428 shift
429 local filter="--gtest_filter=$(IFS=:; echo "-${*}")"
430 einfo "${cmd}" "${filter}"
431 LC_ALL="${mylocale}" VIRTUALX_COMMAND="${cmd}" virtualmake "${filter}"
432 }
433
434 local excluded_base_unittests=(
435 "ICUStringConversionsTest.*" # bug #350347
436 "MessagePumpLibeventTest.*" # bug #398591
437 )
438 runtest out/Release/base_unittests "${excluded_base_unittests[@]}"
439
440 runtest out/Release/cacheinvalidation_unittests
441 runtest out/Release/crypto_unittests
442 runtest out/Release/googleurl_unittests
443 runtest out/Release/gpu_unittests
444 runtest out/Release/media_unittests
445
446 local excluded_net_unittests=(
447 "NetUtilTest.IDNToUnicode*" # bug 361885
448 "NetUtilTest.FormatUrl*" # see above
449 "DnsConfigServiceTest.GetSystemConfig" # bug #394883
450 "CertDatabaseNSSTest.ImportServerCert_SelfSigned" # bug #399269
451 "URLFetcher*" # bug #425764
452 "HTTPSOCSPTest.*" # bug #426630
453 "HTTPSEVCRLSetTest.*" # see above
454 "HTTPSCRLSetTest.*" # see above
455 )
456 runtest out/Release/net_unittests "${excluded_net_unittests[@]}"
457
458 runtest out/Release/printing_unittests
459 runtest out/Release/sql_unittests
460 }
461
462 src_install() {
463 exeinto "${CHROMIUM_HOME}"
464 doexe out/Release/chrome || die
465
466 if ! use selinux; then
467 doexe out/Release/chrome_sandbox || die
468 fperms 4755 "${CHROMIUM_HOME}/chrome_sandbox"
469 fi
470
471 doexe out/Release/chromedriver || die
472
473 if ! use arm; then
474 doexe out/Release/nacl_helper{,_bootstrap} || die
475 insinto "${CHROMIUM_HOME}"
476 doins out/Release/nacl_irt_*.nexe || die
477 doins out/Release/libppGoogleNaClPluginChrome.so || die
478 fi
479
480 newexe "${FILESDIR}"/chromium-launcher-r2.sh chromium-launcher.sh || die
481 if [[ "${CHROMIUM_SUFFIX}" != "" ]]; then
482 sed "s:chromium-browser:chromium-browser${CHROMIUM_SUFFIX}:g" \
483 -i "${ED}"/"${CHROMIUM_HOME}"/chromium-launcher.sh || die
484 sed "s:chromium.desktop:chromium${CHROMIUM_SUFFIX}.desktop:g" \
485 -i "${ED}"/"${CHROMIUM_HOME}"/chromium-launcher.sh || die
486 sed "s:plugins:plugins --user-data-dir=\${HOME}/.config/chromium${CHROMIUM_SUFFIX}:" \
487 -i "${ED}"/"${CHROMIUM_HOME}"/chromium-launcher.sh || die
488 fi
489
490 # It is important that we name the target "chromium-browser",
491 # xdg-utils expect it; bug #355517.
492 dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium-browser${CHROMIUM_SUFFIX} || die
493 # keep the old symlink around for consistency
494 dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium${CHROMIUM_SUFFIX} || die
495
496 # Allow users to override command-line options, bug #357629.
497 dodir /etc/chromium || die
498 insinto /etc/chromium
499 newins "${FILESDIR}/chromium.default" "default" || die
500
501 pushd out/Release/locales > /dev/null || die
502 chromium_remove_language_paks
503 popd
504
505 insinto "${CHROMIUM_HOME}"
506 doins out/Release/*.pak || die
507
508 doins -r out/Release/locales || die
509 doins -r out/Release/resources || die
510
511 newman out/Release/chrome.1 chromium${CHROMIUM_SUFFIX}.1 || die
512 newman out/Release/chrome.1 chromium-browser${CHROMIUM_SUFFIX}.1 || die
513
514 doexe out/Release/libffmpegsumo.so || die
515
516 # Install icons and desktop entry.
517 local branding size
518 for size in 16 22 24 32 48 64 128 256 ; do
519 case ${size} in
520 16|32) branding="chrome/app/theme/default_100_percent/chromium" ;;
521 *) branding="chrome/app/theme/chromium" ;;
522 esac
523 newicon -s ${size} "${branding}/product_logo_${size}.png" \
524 chromium-browser${CHROMIUM_SUFFIX}.png
525 done
526
527 local mime_types="text/html;text/xml;application/xhtml+xml;"
528 mime_types+="x-scheme-handler/http;x-scheme-handler/https;" # bug #360797
529 mime_types+="x-scheme-handler/ftp;" # bug #412185
530 mime_types+="x-scheme-handler/mailto;x-scheme-handler/webcal;" # bug #416393
531 make_desktop_entry \
532 chromium-browser${CHROMIUM_SUFFIX} \
533 "Chromium${CHROMIUM_SUFFIX}" \
534 chromium-browser${CHROMIUM_SUFFIX} \
535 "Network;WebBrowser" \
536 "MimeType=${mime_types}\nStartupWMClass=chromium-browser"
537 sed -e "/^Exec/s/$/ %U/" -i "${ED}"/usr/share/applications/*.desktop || die
538
539 # Install GNOME default application entry (bug #303100).
540 if use gnome; then
541 dodir /usr/share/gnome-control-center/default-apps || die
542 insinto /usr/share/gnome-control-center/default-apps
543 newins "${FILESDIR}"/chromium-browser.xml chromium-browser${CHROMIUM_SUFFIX}.xml || die
544 if [[ "${CHROMIUM_SUFFIX}" != "" ]]; then
545 sed "s:chromium-browser:chromium-browser${CHROMIUM_SUFFIX}:g" -i \
546 "${ED}"/usr/share/gnome-control-center/default-apps/chromium-browser${CHROMIUM_SUFFIX}.xml
547 fi
548 fi
549 }