summaryrefslogtreecommitdiff
path: root/www-client/chromium
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-12-25 17:37:52 +0000
committerV3n3RiX <venerix@redcorelinux.org>2017-12-25 17:37:52 +0000
commit2f51c9978dda4c6e8debca43e4235ecc86914032 (patch)
treebc41e1c4383040034174c327504f702c8517a123 /www-client/chromium
parent51536d2fe4697ba9114d611178bb9e20d3d5b729 (diff)
gentoo resync : 25.12.2017
Diffstat (limited to 'www-client/chromium')
-rw-r--r--www-client/chromium/Manifest3
-rw-r--r--www-client/chromium/chromium-65.0.3298.3.ebuild676
-rw-r--r--www-client/chromium/files/chromium-gcc-u2f.patch45
3 files changed, 724 insertions, 0 deletions
diff --git a/www-client/chromium/Manifest b/www-client/chromium/Manifest
index 8d909dc30e6a..850ccf1711ed 100644
--- a/www-client/chromium/Manifest
+++ b/www-client/chromium/Manifest
@@ -4,6 +4,7 @@ AUX chromium-browser.xml 407 BLAKE2B 168d78b0855546ca559cfb51aff0bc85d5e6ae974c2
AUX chromium-clang-r1.patch 808 BLAKE2B f3f6cfc679b65f214e6667dc29e4241ae9344be02b5cddd1c25a6410c205e3ad1cf182719b4ba795a5b065fc736c0175803fdaad66439ed2989fc27ff9a12758 SHA512 dfb81895fb78983e5adba54351d94e9174aa6a523c5a78738aad8223330cde6739dea6d82328d603f693a2d5810df890eccc4bed202d73875c9c97be506936e5
AUX chromium-clang-r2.patch 731 BLAKE2B 6a0560107c89ab4406d62700312bb4437b49b5b1feace304c6db309460b74f630dd59c424f152ebf6a1d88025c14b7162d14a38afde6e74a87ca04d3424fd9b6 SHA512 f5edc9b573269a7a6944e17019fa858e7162c548400eceabdabe695d7e10d3179b7593415ec3eaef226defdd1628fd8c9cc66c0b46ebe6ac1afe5035a319c379
AUX chromium-cups-r0.patch 1350 BLAKE2B 91c32a88d5a03ba4f16e54a4498cf6de121b8d6dfbb76630afc69925bfa192c456f6d1349e0ba0b9f71373608ce983910630bf2f278ca884ec8bde4d132b9201 SHA512 404aea01f732132c65fc66c60926c671daad0a1d9446422d36eb6788820f1d23a2bea9d81971f7341f4c36d157bfc9c840b58d7f5f62a913b789d00362c7d005
+AUX chromium-gcc-u2f.patch 1670 BLAKE2B 9d83331ec5e9d4ef3b58e9119c7c152abe61daf8b32e168662de9e734d935c24913b603c631d148ed1cb7b5364e751cbb9bcc7e58e5c34f375958898fc0cf8f5 SHA512 f10486ef46940fa740ca2d7e8225924704a4f89b709ef3dfb7ad128865982c220f8971d169515d9d1be08ee112aef1cac95281f0a5af4615256d9760966545f1
AUX chromium-gcc5-r4.patch 3648 BLAKE2B 44ad25ba69e100f7df35a2532ad1c8e55acf9dbbdcb1c28000c755748ef62848d325c7e379e06d1a0567dbda0e3f97808755ef90e2b7a197aa74a786d0280ca0 SHA512 6b6d80c8adfbb317003712b94cfdf733af48ee5f32d10b6f6e8599cd08b7a9d8b73e6cec2902ed55eb0a962ba9c9cf14a70299e132ec7bfec29806ed23836791
AUX chromium-gcc5-r5.patch 568 BLAKE2B 9c4979a0eb540f490844a368173d7bb6a0f101daca5ea4ab5213fbda62e0a615ee2e0d674a550ded59b7a29aa9193782664e71a614e9c7387061b3d347423994 SHA512 f1878f6960f0f6cad723e2f26ffeed7fc6c2c0e468098d5f08d7e305d644375436c5d7c1698d79bc9f3625fd5736793132d088e68f543838a073c2be68fe5882
AUX chromium-gn-bootstrap-r22.patch 355 BLAKE2B 8a74d22f93d452e6be173a434d36618326264f648a5567bc0bacbea523ec08fed7b45631c645bef056c9e9d2adf6d1322e319778817adc05dd0abf83fb4f339c SHA512 617b5009f30c7da7a5523cd0be3c1e8c4d8c396401191e0b7dd46126a352a0318ce64947f05557cc94e8a7b5a8cffb3b11265ac1961650f8a3e8541fce2969fd
@@ -17,8 +18,10 @@ DIST chromium-63.0.3239.108.tar.xz 534294640 BLAKE2B f0f87115e91d7a2aa331cbab054
DIST chromium-64.0.3282.24.tar.xz 482195676 BLAKE2B fdbe03cd5ee936913300beba18faf2a14b07a28a3904642bb4aef076c69914e1d058bde076e8f093836c4b5c548b7aa33c292b283f2807104ee5f5ebf87d6c91 SHA512 84bf757cf7a5ce08f81c4d2ef7b628b4bc393f457b81df8d86a4420a5cf68b61e01d5add6c6b221cbaf19f85b411228770d2c821e81cd8b0c16e27a455a96dff
DIST chromium-64.0.3282.39.tar.xz 482357636 BLAKE2B 7e7209aa1c4584210b552e82b29c57af549492c85e96204b15c3d27d9ed3c89b7109c9bc539709ecc7221147c2cd4957b6dacf18bfa358c2568175e39eeb4a84 SHA512 16d7c16b218fb42a1371fe105b87a04fce0397df0912824fd443667a1b93ee65b1b9f7c8c3007bea8fc241e6a1b6cb4fa29a4f37c83b3fdfdd8ed6a6523e6906
DIST chromium-65.0.3294.5.tar.xz 484687920 BLAKE2B 2d4d30ea83bfa0d5753eecd4ea735ec5d81097867b7c32c190853adee372c5032dac549c064fb22688555ef6231a3e2e43b274735883285f91a0a2d9c7a151ec SHA512 089bcc7eba7d5a2a964b5b6e94c7735653582cd6925325b9bdb2788bd4abb4b3cbc8c71f5c77004600864106a18da3fddda0adaa53ad54a96efe21498e45f23a
+DIST chromium-65.0.3298.3.tar.xz 485716108 BLAKE2B 185b3f683b2a732343fa5f98b24171f1d3cf2cf8eeb63c56efa7699f6b038d2a7eea4f9277b0b7ee2fdfa207a4f13edbaf2cc9a591a79ec4d058a131ce44366b SHA512 f1ed9a403036e87da7897f173eeb1aa71fe2650efc5ef5b98f814c7d4d9c879971597f9ded11324c86d6edc7f12f3bcf2786a6fb022e9697dbdb8eae086e18b7
EBUILD chromium-63.0.3239.108.ebuild 19805 BLAKE2B c11e610a7f7f498e351d0250a2c68459fda3cdbd1c18abadfd61ef4fe88998125807de58b2e39b6f364dc8b165b1195d11e32b5eea8df14e1d28a08915e84a99 SHA512 d0c44d2057568e092f6f955946df78ef8579114b200b233b2b45d878cb97439bcba1dca78bf3ff40386b5bb4a9c7670de5bbcca34572094abc7dcfeb3f5324fb
EBUILD chromium-64.0.3282.24.ebuild 20052 BLAKE2B 6c8983cbba2db73f4cf0d445f39f12dd9e9b880990f701ac695421e9bad1296431747af2b1d3d1f90cd2d21eaf96b910cd274b47bf571af03e0abdb71a1b30b3 SHA512 fbe825d7ceee78a90943c539cfcdcacd33808a7be82180b2397d2ef5c09732e1d40acf1d534ba76fabdad2175bed04e47d23a381b140fc4fa922530a91c93529
EBUILD chromium-64.0.3282.39.ebuild 20103 BLAKE2B 30c7112270da507add602cb6251d22c29fb9ad280098b35a638ae749e90a2381598225a37e904e27126cea8aa843b831ba4b28a8c6c445c9b3d5ab43e14c63b2 SHA512 32a05d704a2e4dd44c53c03c792ea06a010884f5aa3f88ce4dc285ccc6c185d7fab32bc3ecee688657975ed46c176e8c665d7da59231b7d84c41bb533cd8aceb
EBUILD chromium-65.0.3294.5.ebuild 20338 BLAKE2B a992c3d16e340f53ed575941b7ec48c8a254286be84f468f93e45eab707f95e13dde6c70c67296239e83defd5a7552cea527057e9733020ed575dd5aba8d7276 SHA512 f5b8fa9c52c98d601c4d0848c51789c6cfb3e18f6e0de541add26ef50a78c32fab1e6adcb483db9ad0af35734e77607f010ece461f4f88cce18e4633fae3620b
+EBUILD chromium-65.0.3298.3.ebuild 20238 BLAKE2B e18a665d5707a2a596e87013ea0b1eb2448a8905acf5aed286a3dc635aef21ba573caf5b2f9ca3aeae64189ecb67a1a244945022045a88a8c097a18cf4252463 SHA512 562ff9adf572787e149cedb557b796181b0a76b3e8a741b90b804d89fc09d565538cf57d83cb27644b90d79b01b3a8520b6f82f8fe6d27636138392a724a5213
MISC metadata.xml 1336 BLAKE2B 77878a208aff8c9744fca1874e9f692dc6dd55484303274012288c01def548cb96e0d428125613c84f49966adae9702c430ff1ca61c7df5654d1fda4ac9aa22d SHA512 028de2d2f3068ec95dc586b1d5b40cc4f69feba6ca685038427c606005ffc1ede58d056b0502822be83e28217182adc5305e81a7de8fd49f3162250a476cc1a0
diff --git a/www-client/chromium/chromium-65.0.3298.3.ebuild b/www-client/chromium/chromium-65.0.3298.3.ebuild
new file mode 100644
index 000000000000..04bbef975cf8
--- /dev/null
+++ b/www-client/chromium/chromium-65.0.3298.3.ebuild
@@ -0,0 +1,676 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="6"
+PYTHON_COMPAT=( python2_7 )
+
+CHROMIUM_LANGS="am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu he
+ 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
+ sv sw ta te th tr uk vi zh-CN zh-TW"
+
+inherit check-reqs chromium-2 eutils gnome2-utils flag-o-matic multilib ninja-utils pax-utils portability python-any-r1 readme.gentoo-r1 toolchain-funcs versionator xdg-utils
+
+DESCRIPTION="Open-source version of Google Chrome web browser"
+HOMEPAGE="http://chromium.org/"
+SRC_URI="https://commondatastorage.googleapis.com/chromium-browser-official/${P}.tar.xz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~x86"
+IUSE="component-build cups gnome-keyring +hangouts kerberos neon pic +proprietary-codecs pulseaudio selinux +suid +system-ffmpeg +system-icu +system-libvpx +tcmalloc widevine"
+RESTRICT="!system-ffmpeg? ( proprietary-codecs? ( bindist ) )"
+
+COMMON_DEPEND="
+ app-arch/bzip2:=
+ cups? ( >=net-print/cups-1.3.11:= )
+ dev-libs/expat:=
+ dev-libs/glib:2
+ system-icu? ( >=dev-libs/icu-59:= )
+ >=dev-libs/libxml2-2.9.4-r3:=[icu]
+ dev-libs/libxslt:=
+ dev-libs/nspr:=
+ >=dev-libs/nss-3.14.3:=
+ >=dev-libs/re2-0.2016.05.01:=
+ gnome-keyring? ( >=gnome-base/libgnome-keyring-3.12:= )
+ >=media-libs/alsa-lib-1.0.19:=
+ media-libs/fontconfig:=
+ media-libs/freetype:=
+ >=media-libs/harfbuzz-1.5.0:=[icu(-)]
+ media-libs/libjpeg-turbo:=
+ media-libs/libpng:=
+ system-libvpx? ( media-libs/libvpx:=[postproc,svc] )
+ >=media-libs/openh264-1.6.0:=
+ pulseaudio? ( media-sound/pulseaudio:= )
+ system-ffmpeg? (
+ >=media-video/ffmpeg-3:=
+ || (
+ media-video/ffmpeg[-samba]
+ >=net-fs/samba-4.5.10-r1[-debug(-)]
+ )
+ !=net-fs/samba-4.5.12
+ media-libs/opus:=
+ )
+ sys-apps/dbus:=
+ sys-apps/pciutils:=
+ virtual/udev
+ x11-libs/cairo:=
+ x11-libs/gdk-pixbuf:2
+ x11-libs/gtk+:3[X]
+ x11-libs/libX11:=
+ x11-libs/libXcomposite:=
+ x11-libs/libXcursor:=
+ x11-libs/libXdamage:=
+ x11-libs/libXext:=
+ x11-libs/libXfixes:=
+ >=x11-libs/libXi-1.6.0:=
+ x11-libs/libXrandr:=
+ x11-libs/libXrender:=
+ x11-libs/libXScrnSaver:=
+ x11-libs/libXtst:=
+ x11-libs/pango:=
+ app-arch/snappy:=
+ media-libs/flac:=
+ >=media-libs/libwebp-0.4.0:=
+ sys-libs/zlib:=[minizip]
+ kerberos? ( virtual/krb5 )
+"
+# For nvidia-drivers blocker, see bug #413637 .
+RDEPEND="${COMMON_DEPEND}
+ !=www-client/chromium-9999
+ !<www-plugins/chrome-binary-plugins-57
+ x11-misc/xdg-utils
+ virtual/opengl
+ virtual/ttf-fonts
+ selinux? ( sec-policy/selinux-chromium )
+ tcmalloc? ( !<x11-drivers/nvidia-drivers-331.20 )
+ widevine? ( www-plugins/chrome-binary-plugins[widevine(-)] )
+"
+# dev-vcs/git - https://bugs.gentoo.org/593476
+# sys-apps/sandbox - https://crbug.com/586444
+DEPEND="${COMMON_DEPEND}
+ >=app-arch/gzip-1.7
+ !arm? (
+ dev-lang/yasm
+ )
+ dev-lang/perl
+ >=dev-util/gperf-3.0.3
+ >=dev-util/ninja-1.7.2
+ >=net-libs/nodejs-6.9.4
+ sys-apps/hwids[usb(+)]
+ >=sys-devel/bison-2.4.3
+ sys-devel/flex
+ virtual/pkgconfig
+ dev-vcs/git
+ $(python_gen_any_dep '
+ dev-python/beautifulsoup:python-2[${PYTHON_USEDEP}]
+ >=dev-python/beautifulsoup-4.3.2:4[${PYTHON_USEDEP}]
+ dev-python/html5lib[${PYTHON_USEDEP}]
+ dev-python/simplejson[${PYTHON_USEDEP}]
+ ')
+"
+
+# Keep this in sync with the python_gen_any_dep call.
+python_check_deps() {
+ has_version --host-root "dev-python/beautifulsoup:python-2[${PYTHON_USEDEP}]" &&
+ has_version --host-root ">=dev-python/beautifulsoup-4.3.2:4[${PYTHON_USEDEP}]" &&
+ has_version --host-root "dev-python/html5lib[${PYTHON_USEDEP}]" &&
+ has_version --host-root "dev-python/simplejson[${PYTHON_USEDEP}]"
+}
+
+if ! has chromium_pkg_die ${EBUILD_DEATH_HOOKS}; then
+ EBUILD_DEATH_HOOKS+=" chromium_pkg_die";
+fi
+
+DISABLE_AUTOFORMATTING="yes"
+DOC_CONTENTS="
+Some web pages may require additional fonts to display properly.
+Try installing some of the following packages if some characters
+are not displayed properly:
+- media-fonts/arphicfonts
+- media-fonts/bitstream-cyberbit
+- media-fonts/droid
+- media-fonts/ipamonafont
+- media-fonts/noto
+- media-fonts/ja-ipafonts
+- media-fonts/takao-fonts
+- media-fonts/wqy-microhei
+- media-fonts/wqy-zenhei
+
+To fix broken icons on the Downloads page, you should install an icon
+theme that covers the appropriate MIME types, and configure this as your
+GTK+ icon theme.
+"
+
+PATCHES=(
+ "${FILESDIR}/chromium-widevine-r1.patch"
+ "${FILESDIR}/chromium-FORTIFY_SOURCE-r2.patch"
+ "${FILESDIR}/chromium-webrtc-r0.patch"
+ "${FILESDIR}/chromium-memcpy-r0.patch"
+ "${FILESDIR}/chromium-clang-r2.patch"
+ "${FILESDIR}/chromium-gcc-u2f.patch"
+)
+
+pre_build_checks() {
+ if [[ ${MERGE_TYPE} != binary ]]; then
+ local -x CPP="$(tc-getCXX) -E"
+ if tc-is-clang && ! version_is_at_least "3.9.1" "$(clang-fullversion)"; then
+ # bugs: #601654
+ die "At least clang 3.9.1 is required"
+ fi
+ if tc-is-gcc && ! version_is_at_least 5.0 "$(gcc-version)"; then
+ # bugs: #535730, #525374, #518668, #600288, #627356
+ die "At least gcc 5.0 is required"
+ fi
+ fi
+
+ # Check build requirements, bug #541816 and bug #471810 .
+ CHECKREQS_MEMORY="3G"
+ CHECKREQS_DISK_BUILD="5G"
+ eshopts_push -s extglob
+ if is-flagq '-g?(gdb)?([1-9])'; then
+ CHECKREQS_DISK_BUILD="25G"
+ if ! use component-build; then
+ CHECKREQS_MEMORY="16G"
+ fi
+ fi
+ eshopts_pop
+ check-reqs_pkg_setup
+}
+
+pkg_pretend() {
+ pre_build_checks
+}
+
+pkg_setup() {
+ pre_build_checks
+
+ chromium_suid_sandbox_check_kernel_config
+}
+
+src_prepare() {
+ # Calling this here supports resumption via FEATURES=keepwork
+ python_setup
+
+ default
+
+ mkdir -p third_party/node/linux/node-linux-x64/bin || die
+ ln -s "${EPREFIX}"/usr/bin/node third_party/node/linux/node-linux-x64/bin/node || die
+
+ local keeplibs=(
+ base/third_party/dmg_fp
+ base/third_party/dynamic_annotations
+ base/third_party/icu
+ base/third_party/nspr
+ base/third_party/superfasthash
+ base/third_party/symbolize
+ base/third_party/valgrind
+ base/third_party/xdg_mime
+ base/third_party/xdg_user_dirs
+ chrome/third_party/mozilla_security_manager
+ courgette/third_party
+ net/third_party/mozilla_security_manager
+ net/third_party/nss
+ third_party/WebKit
+ third_party/analytics
+ third_party/angle
+ third_party/angle/src/common/third_party/base
+ third_party/angle/src/common/third_party/smhasher
+ third_party/angle/src/third_party/compiler
+ third_party/angle/src/third_party/libXNVCtrl
+ third_party/angle/src/third_party/trace_event
+ third_party/blink
+ third_party/boringssl
+ third_party/boringssl/src/third_party/fiat
+ third_party/breakpad
+ third_party/breakpad/breakpad/src/third_party/curl
+ third_party/brotli
+ third_party/cacheinvalidation
+ third_party/catapult
+ third_party/catapult/common/py_vulcanize/third_party/rcssmin
+ third_party/catapult/common/py_vulcanize/third_party/rjsmin
+ third_party/catapult/third_party/polymer
+ third_party/catapult/tracing/third_party/d3
+ third_party/catapult/tracing/third_party/gl-matrix
+ third_party/catapult/tracing/third_party/jszip
+ third_party/catapult/tracing/third_party/mannwhitneyu
+ third_party/catapult/tracing/third_party/oboe
+ third_party/catapult/tracing/third_party/pako
+ third_party/ced
+ third_party/cld_3
+ third_party/crc32c
+ third_party/cros_system_api
+ third_party/devscripts
+ third_party/dom_distiller_js
+ third_party/fips181
+ third_party/flatbuffers
+ third_party/flot
+ third_party/freetype
+ third_party/glslang-angle
+ third_party/google_input_tools
+ third_party/google_input_tools/third_party/closure_library
+ third_party/google_input_tools/third_party/closure_library/third_party/closure
+ third_party/googletest
+ third_party/hunspell
+ third_party/iccjpeg
+ third_party/inspector_protocol
+ third_party/jinja2
+ third_party/jstemplate
+ third_party/khronos
+ third_party/leveldatabase
+ third_party/libXNVCtrl
+ third_party/libaddressinput
+ third_party/libaom
+ third_party/libaom/source/libaom/third_party/x86inc
+ third_party/libjingle
+ third_party/libphonenumber
+ third_party/libsecret
+ third_party/libsrtp
+ third_party/libudev
+ third_party/libwebm
+ third_party/libxml/chromium
+ third_party/libyuv
+ third_party/lss
+ third_party/lzma_sdk
+ third_party/markupsafe
+ third_party/mesa
+ third_party/metrics_proto
+ third_party/modp_b64
+ third_party/mt19937ar
+ third_party/node
+ third_party/node/node_modules/polymer-bundler/lib/third_party/UglifyJS2
+ third_party/openmax_dl
+ third_party/ots
+ third_party/pdfium
+ third_party/pdfium/third_party/agg23
+ third_party/pdfium/third_party/base
+ third_party/pdfium/third_party/build
+ third_party/pdfium/third_party/bigint
+ third_party/pdfium/third_party/freetype
+ third_party/pdfium/third_party/lcms
+ third_party/pdfium/third_party/libopenjpeg20
+ third_party/pdfium/third_party/libpng16
+ third_party/pdfium/third_party/libtiff
+ third_party/ply
+ third_party/polymer
+ third_party/protobuf
+ third_party/protobuf/third_party/six
+ third_party/qcms
+ third_party/s2cellid
+ third_party/sfntly
+ third_party/skia
+ third_party/skia/third_party/gif
+ third_party/skia/third_party/vulkan
+ third_party/smhasher
+ third_party/spirv-headers
+ third_party/spirv-tools-angle
+ third_party/sqlite
+ third_party/swiftshader
+ third_party/swiftshader/third_party/llvm-subzero
+ third_party/swiftshader/third_party/subzero
+ third_party/usrsctp
+ third_party/vulkan
+ third_party/vulkan-validation-layers
+ third_party/web-animations-js
+ third_party/webdriver
+ third_party/webrtc
+ third_party/widevine
+ third_party/woff2
+ third_party/zlib/google
+ url/third_party/mozilla
+ v8/src/third_party/valgrind
+ v8/src/third_party/utf8-decoder
+ v8/third_party/inspector_protocol
+
+ # gyp -> gn leftovers
+ base/third_party/libevent
+ third_party/adobe
+ third_party/speech-dispatcher
+ third_party/usb_ids
+ third_party/xdg-utils
+ third_party/yasm/run_yasm.py
+ )
+ if ! use system-ffmpeg; then
+ keeplibs+=( third_party/ffmpeg third_party/opus )
+ fi
+ if ! use system-icu; then
+ keeplibs+=( third_party/icu )
+ fi
+ if ! use system-libvpx; then
+ keeplibs+=( third_party/libvpx )
+ keeplibs+=( third_party/libvpx/source/libvpx/third_party/x86inc )
+ fi
+ if use tcmalloc; then
+ keeplibs+=( third_party/tcmalloc )
+ fi
+
+ # Remove most bundled libraries. Some are still needed.
+ build/linux/unbundle/remove_bundled_libraries.py "${keeplibs[@]}" --do-remove || die
+}
+
+bootstrap_gn() {
+ if tc-is-cross-compiler; then
+ local -x AR=${BUILD_AR}
+ local -x CC=${BUILD_CC}
+ local -x CXX=${BUILD_CXX}
+ local -x NM=${BUILD_NM}
+ local -x CFLAGS=${BUILD_CFLAGS}
+ local -x CXXFLAGS=${BUILD_CXXFLAGS}
+ local -x LDFLAGS=${BUILD_LDFLAGS}
+ fi
+ einfo "Building GN..."
+ set -- tools/gn/bootstrap/bootstrap.py -s -v --no-clean
+ echo "$@"
+ "$@" || die
+}
+
+src_configure() {
+ # Calling this here supports resumption via FEATURES=keepwork
+ python_setup
+
+ local myconf_gn=""
+
+ # GN needs explicit config for Debug/Release as opposed to inferring it from build directory.
+ myconf_gn+=" is_debug=false"
+
+ # Component build isn't generally intended for use by end users. It's mostly useful
+ # for development and debugging.
+ myconf_gn+=" is_component_build=$(usex component-build true false)"
+
+ myconf_gn+=" use_allocator=$(usex tcmalloc \"tcmalloc\" \"none\")"
+
+ # Disable nacl, we can't build without pnacl (http://crbug.com/269560).
+ myconf_gn+=" enable_nacl=false"
+
+ # Use system-provided libraries.
+ # TODO: freetype -- remove sources (https://bugs.chromium.org/p/pdfium/issues/detail?id=733).
+ # TODO: use_system_hunspell (upstream changes needed).
+ # TODO: use_system_libsrtp (bug #459932).
+ # TODO: use_system_protobuf (bug #525560).
+ # TODO: use_system_ssl (http://crbug.com/58087).
+ # TODO: use_system_sqlite (http://crbug.com/22208).
+
+ # libevent: https://bugs.gentoo.org/593458
+ local gn_system_libraries=(
+ flac
+ fontconfig
+ freetype
+ # Need harfbuzz_from_pkgconfig target
+ #harfbuzz-ng
+ libdrm
+ libjpeg
+ libpng
+ libwebp
+ libxml
+ libxslt
+ openh264
+ re2
+ snappy
+ yasm
+ zlib
+ )
+ if use system-ffmpeg; then
+ gn_system_libraries+=( ffmpeg opus )
+ fi
+ if use system-icu; then
+ gn_system_libraries+=( icu )
+ fi
+ if use system-libvpx; then
+ gn_system_libraries+=( libvpx )
+ fi
+ build/linux/unbundle/replace_gn_files.py --system-libraries "${gn_system_libraries[@]}" || die
+
+ # See dependency logic in third_party/BUILD.gn
+ myconf_gn+=" use_system_harfbuzz=true"
+
+ # Optional dependencies.
+ myconf_gn+=" enable_hangout_services_extension=$(usex hangouts true false)"
+ myconf_gn+=" enable_widevine=$(usex widevine true false)"
+ myconf_gn+=" use_cups=$(usex cups true false)"
+ myconf_gn+=" use_gconf=false"
+ myconf_gn+=" use_gnome_keyring=$(usex gnome-keyring true false)"
+ myconf_gn+=" use_kerberos=$(usex kerberos true false)"
+ myconf_gn+=" use_pulseaudio=$(usex pulseaudio true false)"
+
+ # TODO: link_pulseaudio=true for GN.
+
+ myconf_gn+=" fieldtrial_testing_like_official_build=true"
+
+ if tc-is-clang; then
+ myconf_gn+=" is_clang=true clang_use_chrome_plugins=false"
+ else
+ myconf_gn+=" is_clang=false"
+ fi
+
+ # Never use bundled gold binary. Disable gold linker flags for now.
+ # Do not use bundled clang.
+ # Trying to use gold results in linker crash.
+ myconf_gn+=" use_gold=false use_sysroot=false linux_use_bundled_binutils=false use_custom_libcxx=false"
+
+ # Disable forced lld, bug 641556
+ myconf_gn+=" use_lld=false"
+
+ ffmpeg_branding="$(usex proprietary-codecs Chrome Chromium)"
+ myconf_gn+=" proprietary_codecs=$(usex proprietary-codecs true false)"
+ myconf_gn+=" ffmpeg_branding=\"${ffmpeg_branding}\""
+
+ # Set up Google API keys, see http://www.chromium.org/developers/how-tos/api-keys .
+ # Note: these are for Gentoo use ONLY. For your own distribution,
+ # please get your own set of keys. Feel free to contact chromium@gentoo.org
+ # for more info.
+ local google_api_key="AIzaSyDEAOvatFo0eTgsV_ZlEzx0ObmepsMzfAc"
+ local google_default_client_id="329227923882.apps.googleusercontent.com"
+ local google_default_client_secret="vgKG0NNv7GoDpbtoFNLxCUXu"
+ myconf_gn+=" google_api_key=\"${google_api_key}\""
+ myconf_gn+=" google_default_client_id=\"${google_default_client_id}\""
+ myconf_gn+=" google_default_client_secret=\"${google_default_client_secret}\""
+
+ local myarch="$(tc-arch)"
+ if [[ $myarch = amd64 ]] ; then
+ myconf_gn+=" target_cpu=\"x64\""
+ ffmpeg_target_arch=x64
+ elif [[ $myarch = x86 ]] ; then
+ myconf_gn+=" target_cpu=\"x86\""
+ ffmpeg_target_arch=ia32
+ elif [[ $myarch = arm64 ]] ; then
+ myconf_gn+=" target_cpu=\"arm64\""
+ ffmpeg_target_arch=arm64
+ elif [[ $myarch = arm ]] ; then
+ myconf_gn+=" target_cpu=\"arm\""
+ ffmpeg_target_arch=$(usex neon arm-neon arm)
+ else
+ die "Failed to determine target arch, got '$myarch'."
+ fi
+
+ # Make sure that -Werror doesn't get added to CFLAGS by the build system.
+ # Depending on GCC version the warnings are different and we don't want
+ # the build to fail because of that.
+ myconf_gn+=" treat_warnings_as_errors=false"
+
+ # Disable fatal linker warnings, bug 506268.
+ myconf_gn+=" fatal_linker_warnings=false"
+
+ # Avoid CFLAGS problems, bug #352457, bug #390147.
+ if ! use custom-cflags; then
+ replace-flags "-Os" "-O2"
+ strip-flags
+
+ # Prevent linker from running out of address space, bug #471810 .
+ if use x86; then
+ filter-flags "-g*"
+ fi
+
+ # Prevent libvpx build failures. Bug 530248, 544702, 546984.
+ if [[ ${myarch} == amd64 || ${myarch} == x86 ]]; then
+ filter-flags -mno-mmx -mno-sse2 -mno-ssse3 -mno-sse4.1 -mno-avx -mno-avx2
+ fi
+ fi
+
+ # Make sure the build system will use the right tools, bug #340795.
+ tc-export AR CC CXX NM
+
+ # Define a custom toolchain for GN
+ myconf_gn+=" custom_toolchain=\"//build/toolchain/linux/unbundle:default\""
+
+ if tc-is-cross-compiler; then
+ tc-export BUILD_{AR,CC,CXX,NM}
+ myconf_gn+=" host_toolchain=\"//build/toolchain/linux/unbundle:host\""
+ myconf_gn+=" v8_snapshot_toolchain=\"//build/toolchain/linux/unbundle:host\""
+ else
+ myconf_gn+=" host_toolchain=\"//build/toolchain/linux/unbundle:default\""
+ fi
+
+ # https://bugs.gentoo.org/588596
+ append-cxxflags $(test-flags-CXX -fno-delete-null-pointer-checks)
+
+ # Bug 491582.
+ export TMPDIR="${WORKDIR}/temp"
+ mkdir -p -m 755 "${TMPDIR}" || die
+
+ if ! use system-ffmpeg; then
+ local build_ffmpeg_args=""
+ if use pic && [[ "${ffmpeg_target_arch}" == "ia32" ]]; then
+ build_ffmpeg_args+=" --disable-asm"
+ fi
+
+ # Re-configure bundled ffmpeg. See bug #491378 for example reasons.
+ einfo "Configuring bundled ffmpeg..."
+ pushd third_party/ffmpeg > /dev/null || die
+ chromium/scripts/build_ffmpeg.py linux ${ffmpeg_target_arch} \
+ --branding ${ffmpeg_branding} -- ${build_ffmpeg_args} || die
+ chromium/scripts/copy_config.sh || die
+ chromium/scripts/generate_gn.py || die
+ popd > /dev/null || die
+ fi
+
+ bootstrap_gn
+
+ einfo "Configuring Chromium..."
+ set -- out/Release/gn gen --args="${myconf_gn} ${EXTRA_GN}" out/Release
+ echo "$@"
+ "$@" || die
+}
+
+src_compile() {
+ # Calling this here supports resumption via FEATURES=keepwork
+ python_setup
+
+ # Build mksnapshot and pax-mark it.
+ local x
+ for x in mksnapshot v8_context_snapshot_generator; do
+ if tc-is-cross-compiler; then
+ eninja -C out/Release "host/${x}"
+ pax-mark m "out/Release/host/${x}"
+ else
+ eninja -C out/Release "${x}"
+ pax-mark m "out/Release/${x}"
+ fi
+ done
+
+ # Work around circular dep issue
+ # https://chromium-review.googlesource.com/c/chromium/src/+/617768
+ eninja -C out/Release gen/ui/accessibility/ax_enums.h
+
+ # Even though ninja autodetects number of CPUs, we respect
+ # user's options, for debugging with -j 1 or any other reason.
+ eninja -C out/Release chrome chromedriver
+ use suid && eninja -C out/Release chrome_sandbox
+
+ pax-mark m out/Release/chrome
+}
+
+src_install() {
+ local CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser"
+ exeinto "${CHROMIUM_HOME}"
+ doexe out/Release/chrome
+
+ if use suid; then
+ newexe out/Release/chrome_sandbox chrome-sandbox
+ fperms 4755 "${CHROMIUM_HOME}/chrome-sandbox"
+ fi
+
+ doexe out/Release/chromedriver
+
+ local sedargs=( -e "s:/usr/lib/:/usr/$(get_libdir)/:g" )
+ sed "${sedargs[@]}" "${FILESDIR}/chromium-launcher-r3.sh" > chromium-launcher.sh || die
+ doexe chromium-launcher.sh
+
+ # It is important that we name the target "chromium-browser",
+ # xdg-utils expect it; bug #355517.
+ dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium-browser
+ # keep the old symlink around for consistency
+ dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium
+
+ dosym "${CHROMIUM_HOME}/chromedriver" /usr/bin/chromedriver
+
+ # Allow users to override command-line options, bug #357629.
+ insinto /etc/chromium
+ newins "${FILESDIR}/chromium.default" "default"
+
+ pushd out/Release/locales > /dev/null || die
+ chromium_remove_language_paks
+ popd
+
+ if use widevine; then
+ # These will be provided by chrome-binary-plugins
+ rm out/Release/libwidevinecdm*.so || die
+ fi
+
+ insinto "${CHROMIUM_HOME}"
+ doins out/Release/*.bin
+ doins out/Release/*.pak
+ doins out/Release/*.so
+
+ if ! use system-icu; then
+ doins out/Release/icudtl.dat
+ fi
+
+ doins -r out/Release/locales
+ doins -r out/Release/resources
+
+ insinto "${CHROMIUM_HOME}/swiftshader"
+ doins out/Release/swiftshader/*.so
+
+ # Install icons and desktop entry.
+ local branding size
+ for size in 16 22 24 32 48 64 128 256 ; do
+ case ${size} in
+ 16|32) branding="chrome/app/theme/default_100_percent/chromium" ;;
+ *) branding="chrome/app/theme/chromium" ;;
+ esac
+ newicon -s ${size} "${branding}/product_logo_${size}.png" \
+ chromium-browser.png
+ done
+
+ local mime_types="text/html;text/xml;application/xhtml+xml;"
+ mime_types+="x-scheme-handler/http;x-scheme-handler/https;" # bug #360797
+ mime_types+="x-scheme-handler/ftp;" # bug #412185
+ mime_types+="x-scheme-handler/mailto;x-scheme-handler/webcal;" # bug #416393
+ make_desktop_entry \
+ chromium-browser \
+ "Chromium" \
+ chromium-browser \
+ "Network;WebBrowser" \
+ "MimeType=${mime_types}\nStartupWMClass=chromium-browser"
+ sed -e "/^Exec/s/$/ %U/" -i "${ED}"/usr/share/applications/*.desktop || die
+
+ # Install GNOME default application entry (bug #303100).
+ insinto /usr/share/gnome-control-center/default-apps
+ newins "${FILESDIR}"/chromium-browser.xml chromium-browser.xml
+
+ readme.gentoo_create_doc
+}
+
+pkg_preinst() {
+ gnome2_icon_savelist
+}
+
+pkg_postrm() {
+ gnome2_icon_cache_update
+ xdg_desktop_database_update
+}
+
+pkg_postinst() {
+ gnome2_icon_cache_update
+ xdg_desktop_database_update
+ readme.gentoo_print_elog
+}
diff --git a/www-client/chromium/files/chromium-gcc-u2f.patch b/www-client/chromium/files/chromium-gcc-u2f.patch
new file mode 100644
index 000000000000..20608da58d00
--- /dev/null
+++ b/www-client/chromium/files/chromium-gcc-u2f.patch
@@ -0,0 +1,45 @@
+From ee7f5ecc3b869660ded9882a9904cc7c6db7dc0d Mon Sep 17 00:00:00 2001
+From: Jose Dapena Paz <jose.dapena@lge.com>
+Date: Tue, 19 Dec 2017 19:25:00 +0000
+Subject: [PATCH] GCC build: workaround GCC bad "this" handling on lambda by
+ not using lambda.
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This is a workaround for the bug in GCC "Inconsistent `this->`
+required when calling member function in a lambda
+capturing `this` through another function"
+https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67274
+
+This fix just replaces the foreach call using lambda with a
+regular C++ for-each-like for (:) construct in u2f discovery.
+
+Change-Id: I9ddf212a7687e02cd7d2d2b43cf76e21dd5dada2
+Reviewed-on: https://chromium-review.googlesource.com/833886
+Reviewed-by: Jan Wilken Dörrie <jdoerrie@chromium.org>
+Commit-Queue: José Dapena Paz <jose.dapena@lge.com>
+Cr-Commit-Position: refs/heads/master@{#525104}
+---
+ device/u2f/u2f_hid_discovery.cc | 5 ++---
+ 1 file changed, 2 insertions(+), 3 deletions(-)
+
+diff --git a/device/u2f/u2f_hid_discovery.cc b/device/u2f/u2f_hid_discovery.cc
+index 0695778d2aab..6c4e71179ce7 100644
+--- a/device/u2f/u2f_hid_discovery.cc
++++ b/device/u2f/u2f_hid_discovery.cc
+@@ -55,9 +55,8 @@ void U2fHidDiscovery::DeviceRemoved(
+
+ void U2fHidDiscovery::OnGetDevices(
+ std::vector<device::mojom::HidDeviceInfoPtr> device_infos) {
+- std::for_each(
+- device_infos.begin(), device_infos.end(),
+- [this](auto& device_info) { DeviceAdded(std::move(device_info)); });
++ for (auto& device_info : device_infos)
++ DeviceAdded(std::move(device_info));
+ NotifyDiscoveryStarted(true);
+ }
+
+--
+2.15.1
+