1 |
commit: 650396f9a8fa1c676a608470862bdaa0b33c4d84 |
2 |
Author: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Apr 28 14:52:45 2017 +0000 |
4 |
Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Apr 28 14:53:11 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=650396f9 |
7 |
|
8 |
www-client/chromium: remove old |
9 |
|
10 |
Package-Manager: Portage-2.3.5_p31, Repoman-2.3.2_p61 |
11 |
|
12 |
www-client/chromium/Manifest | 3 - |
13 |
www-client/chromium/chromium-57.0.2987.133.ebuild | 645 --------------------- |
14 |
www-client/chromium/chromium-58.0.3029.14.ebuild | 651 --------------------- |
15 |
www-client/chromium/chromium-58.0.3029.19.ebuild | 652 ---------------------- |
16 |
4 files changed, 1951 deletions(-) |
17 |
|
18 |
diff --git a/www-client/chromium/Manifest b/www-client/chromium/Manifest |
19 |
index 221cf195f4f..642c18294ad 100644 |
20 |
--- a/www-client/chromium/Manifest |
21 |
+++ b/www-client/chromium/Manifest |
22 |
@@ -1,6 +1,3 @@ |
23 |
-DIST chromium-57.0.2987.133.tar.xz 525240460 SHA256 70011770a7e522c92826a3af48d3fd28a46bf8042897d072d20c748cbf828cf7 SHA512 b53fb357d3f11b45a46b3fe52a10b0d20cf8f3fedc8454ceca6b8d1ea9c526493cfeeb4472766e3f23ceba5cd53b089a2639d6a166fbfa91db05153571b59039 WHIRLPOOL 25854c4c1c9b9fde2c0bd9af7c374fe3fe78a19a34703cf54cb157a257c7408bf1bf58c199afbc16009e99bc4a3cdc578e907e78fc45bc781e59ab39b877c374 |
24 |
-DIST chromium-58.0.3029.14.tar.xz 509043400 SHA256 b7a02ec45d61516552f7377bd066ee1d77a4ededc03c4c53c18373797dc8d8c4 SHA512 b84c422965c694eee4159bd4f8c102fda5e7d8012adf195c2882f9ef3030a0433fac666de85bfcdd4e635d82a57dfa9f3d4e8000dfb8ada2e068348190a4524c WHIRLPOOL dc47733b3344f58fa1a3bc3f1dcac5088d9bbfcffa1c395547ff42367d2164f51cced3f9ad4afc7157834339dbe3fbe6790c835345533c917013770fe11ebec7 |
25 |
-DIST chromium-58.0.3029.19.tar.xz 509050504 SHA256 ffe5b52faf219bee7675460ac56b3d62a3ee9fd2001f4a854224a1445b8af5e6 SHA512 b1780d4920d14e4861b5e5895accf49d7b65d49345ec243d7d1042ca1d0246cb3b4fcfa383ea3a6ef9a2145bc526be71286af156051a058f4f699b64cce772cb WHIRLPOOL e5e57370aa06ef8ef7b1e923f684148a1035dc3c4282e6a327cbe4f6e7a472ed724e5c4edb3e5ea91ed3620ea6a9d9f23c5ddb52246ff840b7997e3b00bebc8a |
26 |
DIST chromium-58.0.3029.81.tar.xz 509252204 SHA256 5ab61b7025a5143fa1b21713479b316ec7a98e262e79e84f9c9a9656179217cb SHA512 49e8a641e6fe839880ac4cc17aa4b79875dbd0e14adcf7ad0138730334555fd57c93c1e7ebdf6f03c61528c351a5a489f56fb7d7809aef268627b186c547a4f3 WHIRLPOOL eed9d97cd4cb4d9a56864e65e797f6d126327d6e9371bdfe416fd57f0f4c9c83f37e125798a1753b5d8bc5921036bdfe064b3d7e94c3ba315a710241a6c5b179 |
27 |
DIST chromium-59.0.3063.4.tar.xz 519742312 SHA256 3ed3240fca23675f59d0bbf32884ba7c1b6d2288cf499b27d7792d499d8d6d60 SHA512 4dfb4948f4632f813b35eed3935cd771c435dce4dfbd77b698c6e7df7a19af037368293d2cd91d44353aa15de0c47cb809fa144258324116b8c18e2fde16ebff WHIRLPOOL cb183a61ce92d3e99befd2b7503100a63eaa64e33b8ae049571138cbe01d768757dc50555111d4ac11546d1cd8f73717d9904a794a3146c54d3afa1420986dc4 |
28 |
DIST chromium-59.0.3067.0.tar.xz 519365816 SHA256 a8edc9aaa2cb24fc227740f4bc3585980c6e01c3a1117b7a77a7802b6c92767f SHA512 877f53f288ec865f623ad2cdbe70d4e2a3728d5af05252275931697041a86fff7e0a0a3ef228d9169ffd2edda7ed636f8dbe1bf1abed0b9900a857a0b86455fc WHIRLPOOL 98d816351e0e3f3ddad3fd11d57e70e9c9dd82d40376e08b6a8416dbf4500aa9eec9c0ad7ee760d7db85697863bd5834223c205273f37e0900d32c1aa7b7c237 |
29 |
|
30 |
diff --git a/www-client/chromium/chromium-57.0.2987.133.ebuild b/www-client/chromium/chromium-57.0.2987.133.ebuild |
31 |
deleted file mode 100644 |
32 |
index 85185e08bc8..00000000000 |
33 |
--- a/www-client/chromium/chromium-57.0.2987.133.ebuild |
34 |
+++ /dev/null |
35 |
@@ -1,645 +0,0 @@ |
36 |
-# Copyright 1999-2017 Gentoo Foundation |
37 |
-# Distributed under the terms of the GNU General Public License v2 |
38 |
- |
39 |
-EAPI="6" |
40 |
-PYTHON_COMPAT=( python2_7 ) |
41 |
- |
42 |
-CHROMIUM_LANGS="am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu he |
43 |
- 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 |
44 |
- sv sw ta te th tr uk vi zh-CN zh-TW" |
45 |
- |
46 |
-inherit check-reqs chromium-2 eutils gnome2-utils flag-o-matic multilib multiprocessing pax-utils portability python-any-r1 readme.gentoo-r1 toolchain-funcs versionator virtualx xdg-utils |
47 |
- |
48 |
-DESCRIPTION="Open-source version of Google Chrome web browser" |
49 |
-HOMEPAGE="http://chromium.org/" |
50 |
-SRC_URI="https://commondatastorage.googleapis.com/chromium-browser-official/${P}.tar.xz" |
51 |
- |
52 |
-LICENSE="BSD" |
53 |
-SLOT="0" |
54 |
-KEYWORDS="amd64 ~arm ~arm64 x86" |
55 |
-IUSE="component-build cups gconf gnome-keyring gtk3 +hangouts kerberos neon pic +proprietary-codecs pulseaudio selinux +suid +system-ffmpeg +system-libvpx +tcmalloc widevine" |
56 |
-RESTRICT="!system-ffmpeg? ( proprietary-codecs? ( bindist ) )" |
57 |
- |
58 |
-# Native Client binaries are compiled with different set of flags, bug #452066. |
59 |
-QA_FLAGS_IGNORED=".*\.nexe" |
60 |
- |
61 |
-# Native Client binaries may be stripped by the build system, which uses the |
62 |
-# right tools for it, bug #469144 . |
63 |
-QA_PRESTRIPPED=".*\.nexe" |
64 |
- |
65 |
-COMMON_DEPEND=" |
66 |
- app-arch/bzip2:= |
67 |
- cups? ( >=net-print/cups-1.3.11:= ) |
68 |
- >=dev-libs/elfutils-0.149 |
69 |
- dev-libs/expat:= |
70 |
- dev-libs/glib:2 |
71 |
- dev-libs/icu:= |
72 |
- >=dev-libs/jsoncpp-0.5.0-r1:= |
73 |
- dev-libs/libxml2:=[icu] |
74 |
- dev-libs/libxslt:= |
75 |
- dev-libs/nspr:= |
76 |
- >=dev-libs/nss-3.14.3:= |
77 |
- >=dev-libs/re2-0.2016.05.01:= |
78 |
- gconf? ( >=gnome-base/gconf-2.24.0:= ) |
79 |
- gnome-keyring? ( >=gnome-base/libgnome-keyring-3.12:= ) |
80 |
- >=media-libs/alsa-lib-1.0.19:= |
81 |
- media-libs/fontconfig:= |
82 |
- media-libs/freetype:= |
83 |
- >=media-libs/harfbuzz-1.3.1:=[icu(+)] |
84 |
- media-libs/libexif:= |
85 |
- media-libs/libjpeg-turbo:= |
86 |
- media-libs/libpng:= |
87 |
- system-libvpx? ( media-libs/libvpx:=[postproc,svc] ) |
88 |
- media-libs/speex:= |
89 |
- pulseaudio? ( media-sound/pulseaudio:= ) |
90 |
- system-ffmpeg? ( >=media-video/ffmpeg-3:= ) |
91 |
- sys-apps/dbus:= |
92 |
- sys-apps/pciutils:= |
93 |
- >=sys-libs/libcap-2.22:= |
94 |
- virtual/udev |
95 |
- x11-libs/cairo:= |
96 |
- x11-libs/gdk-pixbuf:2 |
97 |
- x11-libs/libdrm |
98 |
- x11-libs/libX11:= |
99 |
- x11-libs/libXcomposite:= |
100 |
- x11-libs/libXcursor:= |
101 |
- x11-libs/libXdamage:= |
102 |
- x11-libs/libXext:= |
103 |
- x11-libs/libXfixes:= |
104 |
- >=x11-libs/libXi-1.6.0:= |
105 |
- x11-libs/libXinerama:= |
106 |
- x11-libs/libXrandr:= |
107 |
- x11-libs/libXrender:= |
108 |
- x11-libs/libXScrnSaver:= |
109 |
- x11-libs/libXtst:= |
110 |
- x11-libs/pango:= |
111 |
- app-arch/snappy:= |
112 |
- media-libs/flac:= |
113 |
- >=media-libs/libwebp-0.4.0:= |
114 |
- sys-libs/zlib:=[minizip] |
115 |
- kerberos? ( virtual/krb5 ) |
116 |
-" |
117 |
-# For nvidia-drivers blocker, see bug #413637 . |
118 |
-RDEPEND="${COMMON_DEPEND} |
119 |
- !=www-client/chromium-9999 |
120 |
- !<www-plugins/chrome-binary-plugins-57 |
121 |
- x11-misc/xdg-utils |
122 |
- virtual/opengl |
123 |
- virtual/ttf-fonts |
124 |
- !gtk3? ( x11-libs/gtk+:2 ) |
125 |
- gtk3? ( x11-libs/gtk+:3 ) |
126 |
- selinux? ( sec-policy/selinux-chromium ) |
127 |
- tcmalloc? ( !<x11-drivers/nvidia-drivers-331.20 ) |
128 |
- widevine? ( www-plugins/chrome-binary-plugins[widevine(-)] ) |
129 |
-" |
130 |
-# dev-vcs/git - https://bugs.gentoo.org/593476 |
131 |
-DEPEND="${COMMON_DEPEND} |
132 |
- >=app-arch/gzip-1.7 |
133 |
- !arm? ( |
134 |
- dev-lang/yasm |
135 |
- ) |
136 |
- dev-lang/perl |
137 |
- dev-perl/JSON |
138 |
- >=dev-util/gperf-3.0.3 |
139 |
- dev-util/ninja |
140 |
- sys-apps/hwids[usb(+)] |
141 |
- >=sys-devel/bison-2.4.3 |
142 |
- sys-devel/flex |
143 |
- virtual/pkgconfig |
144 |
- dev-vcs/git |
145 |
- x11-libs/gtk+:2 |
146 |
- x11-libs/gtk+:3 |
147 |
- $(python_gen_any_dep ' |
148 |
- dev-python/beautifulsoup:python-2[${PYTHON_USEDEP}] |
149 |
- >=dev-python/beautifulsoup-4.3.2:4[${PYTHON_USEDEP}] |
150 |
- dev-python/html5lib[${PYTHON_USEDEP}] |
151 |
- dev-python/simplejson[${PYTHON_USEDEP}] |
152 |
- ') |
153 |
-" |
154 |
- |
155 |
-# Keep this in sync with the python_gen_any_dep call. |
156 |
-python_check_deps() { |
157 |
- has_version --host-root "dev-python/beautifulsoup:python-2[${PYTHON_USEDEP}]" && |
158 |
- has_version --host-root ">=dev-python/beautifulsoup-4.3.2:4[${PYTHON_USEDEP}]" && |
159 |
- has_version --host-root "dev-python/html5lib[${PYTHON_USEDEP}]" && |
160 |
- has_version --host-root "dev-python/simplejson[${PYTHON_USEDEP}]" |
161 |
-} |
162 |
- |
163 |
-if ! has chromium_pkg_die ${EBUILD_DEATH_HOOKS}; then |
164 |
- EBUILD_DEATH_HOOKS+=" chromium_pkg_die"; |
165 |
-fi |
166 |
- |
167 |
-DISABLE_AUTOFORMATTING="yes" |
168 |
-DOC_CONTENTS=" |
169 |
-Some web pages may require additional fonts to display properly. |
170 |
-Try installing some of the following packages if some characters |
171 |
-are not displayed properly: |
172 |
-- media-fonts/arphicfonts |
173 |
-- media-fonts/bitstream-cyberbit |
174 |
-- media-fonts/droid |
175 |
-- media-fonts/ipamonafont |
176 |
-- media-fonts/noto |
177 |
-- media-fonts/ja-ipafonts |
178 |
-- media-fonts/takao-fonts |
179 |
-- media-fonts/wqy-microhei |
180 |
-- media-fonts/wqy-zenhei |
181 |
- |
182 |
-Depending on your desktop environment, you may need |
183 |
-to install additional packages to get icons on the Downloads page. |
184 |
- |
185 |
-For KDE, the required package is kde-frameworks/oxygen-icons. |
186 |
- |
187 |
-For other desktop environments, try one of the following: |
188 |
-- x11-themes/gnome-icon-theme |
189 |
-- x11-themes/tango-icon-theme |
190 |
-" |
191 |
- |
192 |
-pre_build_checks() { |
193 |
- if [[ ${MERGE_TYPE} != binary ]]; then |
194 |
- local -x CPP="$(tc-getCXX) -E" |
195 |
- if tc-is-clang && ! version_is_at_least "3.9.1" "$(clang-fullversion)"; then |
196 |
- # bugs: #601654 |
197 |
- die "At least clang 3.9.1 is required" |
198 |
- fi |
199 |
- if tc-is-gcc && ! version_is_at_least 4.9 "$(gcc-version)"; then |
200 |
- # bugs: #535730, #525374, #518668, #600288 |
201 |
- die "At least gcc 4.9 is required" |
202 |
- fi |
203 |
- fi |
204 |
- |
205 |
- # Check build requirements, bug #541816 and bug #471810 . |
206 |
- CHECKREQS_MEMORY="3G" |
207 |
- CHECKREQS_DISK_BUILD="5G" |
208 |
- eshopts_push -s extglob |
209 |
- if is-flagq '-g?(gdb)?([1-9])'; then |
210 |
- CHECKREQS_DISK_BUILD="25G" |
211 |
- if ! use component-build; then |
212 |
- CHECKREQS_MEMORY="16G" |
213 |
- fi |
214 |
- fi |
215 |
- eshopts_pop |
216 |
- check-reqs_pkg_setup |
217 |
-} |
218 |
- |
219 |
-pkg_pretend() { |
220 |
- pre_build_checks |
221 |
-} |
222 |
- |
223 |
-pkg_setup() { |
224 |
- pre_build_checks |
225 |
- |
226 |
- # Make sure the build system will use the right python, bug #344367. |
227 |
- python-any-r1_pkg_setup |
228 |
- |
229 |
- chromium_suid_sandbox_check_kernel_config |
230 |
-} |
231 |
- |
232 |
-src_prepare() { |
233 |
- local PATCHES=( |
234 |
- "${FILESDIR}/${PN}-widevine-r1.patch" |
235 |
- "${FILESDIR}/${PN}-FORTIFY_SOURCE.patch" |
236 |
- "${FILESDIR}/chromium-57-gcc4.patch" |
237 |
- ) |
238 |
- |
239 |
- use system-ffmpeg && PATCHES+=( "${FILESDIR}/${PN}-system-ffmpeg-r4.patch" ) |
240 |
- |
241 |
- default |
242 |
- |
243 |
- local keeplibs=( |
244 |
- base/third_party/dmg_fp |
245 |
- base/third_party/dynamic_annotations |
246 |
- base/third_party/icu |
247 |
- base/third_party/nspr |
248 |
- base/third_party/superfasthash |
249 |
- base/third_party/symbolize |
250 |
- base/third_party/valgrind |
251 |
- base/third_party/xdg_mime |
252 |
- base/third_party/xdg_user_dirs |
253 |
- breakpad/src/third_party/curl |
254 |
- chrome/third_party/mozilla_security_manager |
255 |
- courgette/third_party |
256 |
- net/third_party/mozilla_security_manager |
257 |
- net/third_party/nss |
258 |
- third_party/WebKit |
259 |
- third_party/analytics |
260 |
- third_party/angle |
261 |
- third_party/angle/src/common/third_party/numerics |
262 |
- third_party/angle/src/third_party/compiler |
263 |
- third_party/angle/src/third_party/libXNVCtrl |
264 |
- third_party/angle/src/third_party/murmurhash |
265 |
- third_party/angle/src/third_party/trace_event |
266 |
- third_party/boringssl |
267 |
- third_party/brotli |
268 |
- third_party/cacheinvalidation |
269 |
- third_party/catapult |
270 |
- third_party/catapult/third_party/polymer |
271 |
- third_party/catapult/third_party/py_vulcanize |
272 |
- third_party/catapult/third_party/py_vulcanize/third_party/rcssmin |
273 |
- third_party/catapult/third_party/py_vulcanize/third_party/rjsmin |
274 |
- third_party/catapult/tracing/third_party/d3 |
275 |
- third_party/catapult/tracing/third_party/gl-matrix |
276 |
- third_party/catapult/tracing/third_party/jszip |
277 |
- third_party/catapult/tracing/third_party/mannwhitneyu |
278 |
- third_party/ced |
279 |
- third_party/cld_2 |
280 |
- third_party/cld_3 |
281 |
- third_party/cros_system_api |
282 |
- third_party/devscripts |
283 |
- third_party/dom_distiller_js |
284 |
- third_party/fips181 |
285 |
- third_party/flatbuffers |
286 |
- third_party/flot |
287 |
- third_party/google_input_tools |
288 |
- third_party/google_input_tools/third_party/closure_library |
289 |
- third_party/google_input_tools/third_party/closure_library/third_party/closure |
290 |
- third_party/hunspell |
291 |
- third_party/iccjpeg |
292 |
- third_party/inspector_protocol |
293 |
- third_party/jinja2 |
294 |
- third_party/jstemplate |
295 |
- third_party/khronos |
296 |
- third_party/leveldatabase |
297 |
- third_party/libXNVCtrl |
298 |
- third_party/libaddressinput |
299 |
- third_party/libjingle |
300 |
- third_party/libphonenumber |
301 |
- third_party/libsecret |
302 |
- third_party/libsrtp |
303 |
- third_party/libudev |
304 |
- third_party/libusb |
305 |
- third_party/libwebm |
306 |
- third_party/libxml/chromium |
307 |
- third_party/libyuv |
308 |
- third_party/lss |
309 |
- third_party/lzma_sdk |
310 |
- third_party/markupsafe |
311 |
- third_party/mesa |
312 |
- third_party/modp_b64 |
313 |
- third_party/mt19937ar |
314 |
- third_party/openh264 |
315 |
- third_party/openmax_dl |
316 |
- third_party/opus |
317 |
- third_party/ots |
318 |
- third_party/pdfium |
319 |
- third_party/pdfium/third_party/agg23 |
320 |
- third_party/pdfium/third_party/base |
321 |
- third_party/pdfium/third_party/bigint |
322 |
- third_party/pdfium/third_party/freetype |
323 |
- third_party/pdfium/third_party/lcms2-2.6 |
324 |
- third_party/pdfium/third_party/libjpeg |
325 |
- third_party/pdfium/third_party/libopenjpeg20 |
326 |
- third_party/pdfium/third_party/libpng16 |
327 |
- third_party/pdfium/third_party/libtiff |
328 |
- third_party/pdfium/third_party/zlib_v128 |
329 |
- third_party/ply |
330 |
- third_party/polymer |
331 |
- third_party/protobuf |
332 |
- third_party/protobuf/third_party/six |
333 |
- third_party/qcms |
334 |
- third_party/sfntly |
335 |
- third_party/skia |
336 |
- third_party/smhasher |
337 |
- third_party/sqlite |
338 |
- third_party/tcmalloc |
339 |
- third_party/usrsctp |
340 |
- third_party/web-animations-js |
341 |
- third_party/webdriver |
342 |
- third_party/webrtc |
343 |
- third_party/widevine |
344 |
- third_party/woff2 |
345 |
- third_party/x86inc |
346 |
- third_party/zlib/google |
347 |
- url/third_party/mozilla |
348 |
- v8/src/third_party/valgrind |
349 |
- v8/third_party/inspector_protocol |
350 |
- |
351 |
- # gyp -> gn leftovers |
352 |
- base/third_party/libevent |
353 |
- third_party/adobe |
354 |
- third_party/speech-dispatcher |
355 |
- third_party/usb_ids |
356 |
- third_party/xdg-utils |
357 |
- third_party/yasm/run_yasm.py |
358 |
- ) |
359 |
- if ! use system-ffmpeg; then |
360 |
- keeplibs+=( third_party/ffmpeg ) |
361 |
- fi |
362 |
- if ! use system-libvpx; then |
363 |
- keeplibs+=( third_party/libvpx ) |
364 |
- keeplibs+=( third_party/libvpx/source/libvpx/third_party/x86inc ) |
365 |
- fi |
366 |
- |
367 |
- # Remove most bundled libraries. Some are still needed. |
368 |
- build/linux/unbundle/remove_bundled_libraries.py "${keeplibs[@]}" --do-remove || die |
369 |
-} |
370 |
- |
371 |
-src_configure() { |
372 |
- local myconf_gn="" |
373 |
- |
374 |
- # GN needs explicit config for Debug/Release as opposed to inferring it from build directory. |
375 |
- myconf_gn+=" is_debug=false" |
376 |
- |
377 |
- # Component build isn't generally intended for use by end users. It's mostly useful |
378 |
- # for development and debugging. |
379 |
- myconf_gn+=" is_component_build=$(usex component-build true false)" |
380 |
- |
381 |
- # Disable nacl, we can't build without pnacl (http://crbug.com/269560). |
382 |
- myconf_gn+=" enable_nacl=false" |
383 |
- |
384 |
- # Use system-provided libraries. |
385 |
- # TODO: use_system_hunspell (upstream changes needed). |
386 |
- # TODO: use_system_libsrtp (bug #459932). |
387 |
- # TODO: use_system_libusb (http://crbug.com/266149). |
388 |
- # TODO: use_system_opus (https://code.google.com/p/webrtc/issues/detail?id=3077). |
389 |
- # TODO: use_system_protobuf (bug #525560). |
390 |
- # TODO: use_system_ssl (http://crbug.com/58087). |
391 |
- # TODO: use_system_sqlite (http://crbug.com/22208). |
392 |
- |
393 |
- # libevent: https://bugs.gentoo.org/593458 |
394 |
- local gn_system_libraries=( |
395 |
- flac |
396 |
- harfbuzz-ng |
397 |
- icu |
398 |
- libjpeg |
399 |
- libpng |
400 |
- libwebp |
401 |
- libxml |
402 |
- libxslt |
403 |
- re2 |
404 |
- snappy |
405 |
- yasm |
406 |
- zlib |
407 |
- ) |
408 |
- if use system-ffmpeg; then |
409 |
- gn_system_libraries+=( ffmpeg ) |
410 |
- fi |
411 |
- if use system-libvpx; then |
412 |
- gn_system_libraries+=( libvpx ) |
413 |
- fi |
414 |
- build/linux/unbundle/replace_gn_files.py --system-libraries "${gn_system_libraries[@]}" || die |
415 |
- |
416 |
- # Optional dependencies. |
417 |
- myconf_gn+=" enable_hangout_services_extension=$(usex hangouts true false)" |
418 |
- myconf_gn+=" enable_widevine=$(usex widevine true false)" |
419 |
- myconf_gn+=" use_cups=$(usex cups true false)" |
420 |
- myconf_gn+=" use_gconf=$(usex gconf true false)" |
421 |
- myconf_gn+=" use_gnome_keyring=$(usex gnome-keyring true false)" |
422 |
- myconf_gn+=" use_gtk3=$(usex gtk3 true false)" |
423 |
- myconf_gn+=" use_kerberos=$(usex kerberos true false)" |
424 |
- myconf_gn+=" use_pulseaudio=$(usex pulseaudio true false)" |
425 |
- |
426 |
- # TODO: link_pulseaudio=true for GN. |
427 |
- |
428 |
- myconf_gn+=" fieldtrial_testing_like_official_build=true" |
429 |
- |
430 |
- if tc-is-clang; then |
431 |
- myconf_gn+=" is_clang=true clang_base_path=\"/usr\" clang_use_chrome_plugins=false" |
432 |
- else |
433 |
- myconf_gn+=" is_clang=false" |
434 |
- fi |
435 |
- |
436 |
- # Never use bundled gold binary. Disable gold linker flags for now. |
437 |
- # Do not use bundled clang. |
438 |
- # Trying to use gold results in linker crash. |
439 |
- myconf_gn+=" use_gold=false use_sysroot=false linux_use_bundled_binutils=false" |
440 |
- |
441 |
- ffmpeg_branding="$(usex proprietary-codecs Chrome Chromium)" |
442 |
- myconf_gn+=" proprietary_codecs=$(usex proprietary-codecs true false)" |
443 |
- myconf_gn+=" ffmpeg_branding=\"${ffmpeg_branding}\"" |
444 |
- |
445 |
- # Set up Google API keys, see http://www.chromium.org/developers/how-tos/api-keys . |
446 |
- # Note: these are for Gentoo use ONLY. For your own distribution, |
447 |
- # please get your own set of keys. Feel free to contact chromium@g.o |
448 |
- # for more info. |
449 |
- local google_api_key="AIzaSyDEAOvatFo0eTgsV_ZlEzx0ObmepsMzfAc" |
450 |
- local google_default_client_id="329227923882.apps.googleusercontent.com" |
451 |
- local google_default_client_secret="vgKG0NNv7GoDpbtoFNLxCUXu" |
452 |
- myconf_gn+=" google_api_key=\"${google_api_key}\"" |
453 |
- myconf_gn+=" google_default_client_id=\"${google_default_client_id}\"" |
454 |
- myconf_gn+=" google_default_client_secret=\"${google_default_client_secret}\"" |
455 |
- |
456 |
- local myarch="$(tc-arch)" |
457 |
- if [[ $myarch = amd64 ]] ; then |
458 |
- target_arch=x64 |
459 |
- ffmpeg_target_arch=x64 |
460 |
- elif [[ $myarch = x86 ]] ; then |
461 |
- target_arch=ia32 |
462 |
- ffmpeg_target_arch=ia32 |
463 |
- elif [[ $myarch = arm64 ]] ; then |
464 |
- target_arch=arm64 |
465 |
- ffmpeg_target_arch=arm64 |
466 |
- elif [[ $myarch = arm ]] ; then |
467 |
- target_arch=arm |
468 |
- ffmpeg_target_arch=$(usex neon arm-neon arm) |
469 |
- else |
470 |
- die "Failed to determine target arch, got '$myarch'." |
471 |
- fi |
472 |
- |
473 |
- # Make sure that -Werror doesn't get added to CFLAGS by the build system. |
474 |
- # Depending on GCC version the warnings are different and we don't want |
475 |
- # the build to fail because of that. |
476 |
- myconf_gn+=" treat_warnings_as_errors=false" |
477 |
- |
478 |
- # Disable fatal linker warnings, bug 506268. |
479 |
- myconf_gn+=" fatal_linker_warnings=false" |
480 |
- |
481 |
- # Avoid CFLAGS problems, bug #352457, bug #390147. |
482 |
- if ! use custom-cflags; then |
483 |
- replace-flags "-Os" "-O2" |
484 |
- strip-flags |
485 |
- |
486 |
- # Prevent linker from running out of address space, bug #471810 . |
487 |
- if use x86; then |
488 |
- filter-flags "-g*" |
489 |
- fi |
490 |
- |
491 |
- # Prevent libvpx build failures. Bug 530248, 544702, 546984. |
492 |
- if [[ ${myarch} == amd64 || ${myarch} == x86 ]]; then |
493 |
- filter-flags -mno-mmx -mno-sse2 -mno-ssse3 -mno-sse4.1 -mno-avx -mno-avx2 |
494 |
- fi |
495 |
- fi |
496 |
- |
497 |
- # Make sure the build system will use the right tools, bug #340795. |
498 |
- tc-export AR CC CXX NM |
499 |
- |
500 |
- # https://bugs.gentoo.org/588596 |
501 |
- append-cxxflags $(test-flags-CXX -fno-delete-null-pointer-checks) |
502 |
- |
503 |
- # Define a custom toolchain for GN |
504 |
- myconf_gn+=" custom_toolchain=\"${FILESDIR}/toolchain:default\"" |
505 |
- |
506 |
- # Tools for building programs to be executed on the build system, bug #410883. |
507 |
- if tc-is-cross-compiler; then |
508 |
- export AR_host=$(tc-getBUILD_AR) |
509 |
- export CC_host=$(tc-getBUILD_CC) |
510 |
- export CXX_host=$(tc-getBUILD_CXX) |
511 |
- export NM_host=$(tc-getBUILD_NM) |
512 |
- fi |
513 |
- |
514 |
- # Bug 491582. |
515 |
- export TMPDIR="${WORKDIR}/temp" |
516 |
- mkdir -p -m 755 "${TMPDIR}" || die |
517 |
- |
518 |
- if ! use system-ffmpeg; then |
519 |
- local build_ffmpeg_args="" |
520 |
- if use pic && [[ "${ffmpeg_target_arch}" == "ia32" ]]; then |
521 |
- build_ffmpeg_args+=" --disable-asm" |
522 |
- fi |
523 |
- |
524 |
- # Re-configure bundled ffmpeg. See bug #491378 for example reasons. |
525 |
- einfo "Configuring bundled ffmpeg..." |
526 |
- pushd third_party/ffmpeg > /dev/null || die |
527 |
- chromium/scripts/build_ffmpeg.py linux ${ffmpeg_target_arch} \ |
528 |
- --branding ${ffmpeg_branding} -- ${build_ffmpeg_args} || die |
529 |
- chromium/scripts/copy_config.sh || die |
530 |
- chromium/scripts/generate_gn.py || die |
531 |
- popd > /dev/null || die |
532 |
- fi |
533 |
- |
534 |
- third_party/libaddressinput/chromium/tools/update-strings.py || die |
535 |
- |
536 |
- touch chrome/test/data/webui/i18n_process_css_test.html || die |
537 |
- |
538 |
- einfo "Configuring Chromium..." |
539 |
- # TODO: bootstrapped gn binary hangs when using tcmalloc with portage's sandbox. |
540 |
- tools/gn/bootstrap/bootstrap.py -v --gn-gen-args "${myconf_gn} use_allocator=\"none\"" || die |
541 |
- myconf_gn+=" use_allocator=$(usex tcmalloc \"tcmalloc\" \"none\")" |
542 |
- out/Release/gn gen --args="${myconf_gn}" out/Release || die |
543 |
-} |
544 |
- |
545 |
-eninja() { |
546 |
- if [[ -z ${NINJAOPTS+set} ]]; then |
547 |
- local jobs=$(makeopts_jobs) |
548 |
- local loadavg=$(makeopts_loadavg) |
549 |
- |
550 |
- if [[ ${MAKEOPTS} == *-j* && ${jobs} != 999 ]]; then |
551 |
- NINJAOPTS+=" -j ${jobs}" |
552 |
- fi |
553 |
- if [[ ${MAKEOPTS} == *-l* && ${loadavg} != 999 ]]; then |
554 |
- NINJAOPTS+=" -l ${loadavg}" |
555 |
- fi |
556 |
- fi |
557 |
- set -- ninja -v ${NINJAOPTS} "$@" |
558 |
- echo "$@" |
559 |
- "$@" |
560 |
-} |
561 |
- |
562 |
-src_compile() { |
563 |
- local ninja_targets="chrome chromedriver" |
564 |
- if use suid; then |
565 |
- ninja_targets+=" chrome_sandbox" |
566 |
- fi |
567 |
- |
568 |
- # Build mksnapshot and pax-mark it. |
569 |
- eninja -C out/Release mksnapshot || die |
570 |
- pax-mark m out/Release/mksnapshot |
571 |
- |
572 |
- # Even though ninja autodetects number of CPUs, we respect |
573 |
- # user's options, for debugging with -j 1 or any other reason. |
574 |
- eninja -C out/Release ${ninja_targets} || die |
575 |
- |
576 |
- pax-mark m out/Release/chrome |
577 |
-} |
578 |
- |
579 |
-src_install() { |
580 |
- local CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser" |
581 |
- exeinto "${CHROMIUM_HOME}" |
582 |
- doexe out/Release/chrome |
583 |
- |
584 |
- if use suid; then |
585 |
- newexe out/Release/chrome_sandbox chrome-sandbox |
586 |
- fperms 4755 "${CHROMIUM_HOME}/chrome-sandbox" |
587 |
- fi |
588 |
- |
589 |
- doexe out/Release/chromedriver |
590 |
- |
591 |
- # if ! use arm; then |
592 |
- # doexe out/Release/nacl_helper{,_bootstrap} || die |
593 |
- # insinto "${CHROMIUM_HOME}" |
594 |
- # doins out/Release/nacl_irt_*.nexe || die |
595 |
- # doins out/Release/libppGoogleNaClPluginChrome.so || die |
596 |
- # fi |
597 |
- |
598 |
- local sedargs=( -e "s:/usr/lib/:/usr/$(get_libdir)/:g" ) |
599 |
- sed "${sedargs[@]}" "${FILESDIR}/chromium-launcher-r3.sh" > chromium-launcher.sh || die |
600 |
- doexe chromium-launcher.sh |
601 |
- |
602 |
- # It is important that we name the target "chromium-browser", |
603 |
- # xdg-utils expect it; bug #355517. |
604 |
- dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium-browser |
605 |
- # keep the old symlink around for consistency |
606 |
- dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium |
607 |
- |
608 |
- dosym "${CHROMIUM_HOME}/chromedriver" /usr/bin/chromedriver |
609 |
- |
610 |
- # Allow users to override command-line options, bug #357629. |
611 |
- insinto /etc/chromium |
612 |
- newins "${FILESDIR}/chromium.default" "default" |
613 |
- |
614 |
- pushd out/Release/locales > /dev/null || die |
615 |
- chromium_remove_language_paks |
616 |
- popd |
617 |
- |
618 |
- if use widevine; then |
619 |
- # These will be provided by chrome-binary-plugins |
620 |
- rm out/Release/libwidevinecdm*.so || die |
621 |
- fi |
622 |
- |
623 |
- insinto "${CHROMIUM_HOME}" |
624 |
- doins out/Release/*.bin |
625 |
- doins out/Release/*.pak |
626 |
- doins out/Release/*.so |
627 |
- |
628 |
- # Needed by bundled icu |
629 |
- # doins out/Release/icudtl.dat |
630 |
- |
631 |
- doins -r out/Release/locales |
632 |
- doins -r out/Release/resources |
633 |
- |
634 |
- newman out/Release/chrome.1 chromium.1 |
635 |
- newman out/Release/chrome.1 chromium-browser.1 |
636 |
- |
637 |
- # Install icons and desktop entry. |
638 |
- local branding size |
639 |
- for size in 16 22 24 32 48 64 128 256 ; do |
640 |
- case ${size} in |
641 |
- 16|32) branding="chrome/app/theme/default_100_percent/chromium" ;; |
642 |
- *) branding="chrome/app/theme/chromium" ;; |
643 |
- esac |
644 |
- newicon -s ${size} "${branding}/product_logo_${size}.png" \ |
645 |
- chromium-browser.png |
646 |
- done |
647 |
- |
648 |
- local mime_types="text/html;text/xml;application/xhtml+xml;" |
649 |
- mime_types+="x-scheme-handler/http;x-scheme-handler/https;" # bug #360797 |
650 |
- mime_types+="x-scheme-handler/ftp;" # bug #412185 |
651 |
- mime_types+="x-scheme-handler/mailto;x-scheme-handler/webcal;" # bug #416393 |
652 |
- make_desktop_entry \ |
653 |
- chromium-browser \ |
654 |
- "Chromium" \ |
655 |
- chromium-browser \ |
656 |
- "Network;WebBrowser" \ |
657 |
- "MimeType=${mime_types}\nStartupWMClass=chromium-browser" |
658 |
- sed -e "/^Exec/s/$/ %U/" -i "${ED}"/usr/share/applications/*.desktop || die |
659 |
- |
660 |
- # Install GNOME default application entry (bug #303100). |
661 |
- insinto /usr/share/gnome-control-center/default-apps |
662 |
- newins "${FILESDIR}"/chromium-browser.xml chromium-browser.xml |
663 |
- |
664 |
- readme.gentoo_create_doc |
665 |
-} |
666 |
- |
667 |
-pkg_preinst() { |
668 |
- gnome2_icon_savelist |
669 |
-} |
670 |
- |
671 |
-pkg_postrm() { |
672 |
- gnome2_icon_cache_update |
673 |
- xdg_desktop_database_update |
674 |
-} |
675 |
- |
676 |
-pkg_postinst() { |
677 |
- gnome2_icon_cache_update |
678 |
- xdg_desktop_database_update |
679 |
- readme.gentoo_print_elog |
680 |
-} |
681 |
|
682 |
diff --git a/www-client/chromium/chromium-58.0.3029.14.ebuild b/www-client/chromium/chromium-58.0.3029.14.ebuild |
683 |
deleted file mode 100644 |
684 |
index df09c5655f0..00000000000 |
685 |
--- a/www-client/chromium/chromium-58.0.3029.14.ebuild |
686 |
+++ /dev/null |
687 |
@@ -1,651 +0,0 @@ |
688 |
-# Copyright 1999-2017 Gentoo Foundation |
689 |
-# Distributed under the terms of the GNU General Public License v2 |
690 |
- |
691 |
-EAPI="6" |
692 |
-PYTHON_COMPAT=( python2_7 ) |
693 |
- |
694 |
-CHROMIUM_LANGS="am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu he |
695 |
- 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 |
696 |
- sv sw ta te th tr uk vi zh-CN zh-TW" |
697 |
- |
698 |
-inherit check-reqs chromium-2 eutils gnome2-utils flag-o-matic multilib multiprocessing pax-utils portability python-any-r1 readme.gentoo-r1 toolchain-funcs versionator virtualx xdg-utils |
699 |
- |
700 |
-DESCRIPTION="Open-source version of Google Chrome web browser" |
701 |
-HOMEPAGE="http://chromium.org/" |
702 |
-SRC_URI="https://commondatastorage.googleapis.com/chromium-browser-official/${P}.tar.xz" |
703 |
- |
704 |
-LICENSE="BSD" |
705 |
-SLOT="0" |
706 |
-KEYWORDS="~amd64 ~arm ~arm64 ~x86" |
707 |
-IUSE="component-build cups gconf gnome-keyring gtk3 +hangouts kerberos neon pic +proprietary-codecs pulseaudio selinux +suid +system-ffmpeg +system-libvpx +tcmalloc widevine" |
708 |
-RESTRICT="!system-ffmpeg? ( proprietary-codecs? ( bindist ) )" |
709 |
- |
710 |
-# Native Client binaries are compiled with different set of flags, bug #452066. |
711 |
-QA_FLAGS_IGNORED=".*\.nexe" |
712 |
- |
713 |
-# Native Client binaries may be stripped by the build system, which uses the |
714 |
-# right tools for it, bug #469144 . |
715 |
-QA_PRESTRIPPED=".*\.nexe" |
716 |
- |
717 |
-COMMON_DEPEND=" |
718 |
- app-arch/bzip2:= |
719 |
- cups? ( >=net-print/cups-1.3.11:= ) |
720 |
- >=dev-libs/elfutils-0.149 |
721 |
- dev-libs/expat:= |
722 |
- dev-libs/glib:2 |
723 |
- dev-libs/icu:= |
724 |
- >=dev-libs/jsoncpp-0.5.0-r1:= |
725 |
- dev-libs/libxml2:=[icu] |
726 |
- dev-libs/libxslt:= |
727 |
- dev-libs/nspr:= |
728 |
- >=dev-libs/nss-3.14.3:= |
729 |
- >=dev-libs/re2-0.2016.05.01:= |
730 |
- gconf? ( >=gnome-base/gconf-2.24.0:= ) |
731 |
- gnome-keyring? ( >=gnome-base/libgnome-keyring-3.12:= ) |
732 |
- >=media-libs/alsa-lib-1.0.19:= |
733 |
- media-libs/fontconfig:= |
734 |
- media-libs/freetype:= |
735 |
- >=media-libs/harfbuzz-1.3.1:=[icu(+)] |
736 |
- media-libs/libexif:= |
737 |
- media-libs/libjpeg-turbo:= |
738 |
- media-libs/libpng:= |
739 |
- system-libvpx? ( media-libs/libvpx:=[svc] ) |
740 |
- media-libs/speex:= |
741 |
- pulseaudio? ( media-sound/pulseaudio:= ) |
742 |
- system-ffmpeg? ( >=media-video/ffmpeg-3:= ) |
743 |
- sys-apps/dbus:= |
744 |
- sys-apps/pciutils:= |
745 |
- >=sys-libs/libcap-2.22:= |
746 |
- virtual/udev |
747 |
- x11-libs/cairo:= |
748 |
- x11-libs/gdk-pixbuf:2 |
749 |
- x11-libs/libdrm |
750 |
- x11-libs/libX11:= |
751 |
- x11-libs/libXcomposite:= |
752 |
- x11-libs/libXcursor:= |
753 |
- x11-libs/libXdamage:= |
754 |
- x11-libs/libXext:= |
755 |
- x11-libs/libXfixes:= |
756 |
- >=x11-libs/libXi-1.6.0:= |
757 |
- x11-libs/libXinerama:= |
758 |
- x11-libs/libXrandr:= |
759 |
- x11-libs/libXrender:= |
760 |
- x11-libs/libXScrnSaver:= |
761 |
- x11-libs/libXtst:= |
762 |
- x11-libs/pango:= |
763 |
- app-arch/snappy:= |
764 |
- media-libs/flac:= |
765 |
- >=media-libs/libwebp-0.4.0:= |
766 |
- sys-libs/zlib:=[minizip] |
767 |
- kerberos? ( virtual/krb5 ) |
768 |
-" |
769 |
-# For nvidia-drivers blocker, see bug #413637 . |
770 |
-RDEPEND="${COMMON_DEPEND} |
771 |
- !=www-client/chromium-9999 |
772 |
- !<www-plugins/chrome-binary-plugins-57 |
773 |
- x11-misc/xdg-utils |
774 |
- virtual/opengl |
775 |
- virtual/ttf-fonts |
776 |
- !gtk3? ( x11-libs/gtk+:2 ) |
777 |
- gtk3? ( x11-libs/gtk+:3 ) |
778 |
- selinux? ( sec-policy/selinux-chromium ) |
779 |
- tcmalloc? ( !<x11-drivers/nvidia-drivers-331.20 ) |
780 |
- widevine? ( www-plugins/chrome-binary-plugins[widevine(-)] ) |
781 |
-" |
782 |
-# dev-vcs/git - https://bugs.gentoo.org/593476 |
783 |
-DEPEND="${COMMON_DEPEND} |
784 |
- >=app-arch/gzip-1.7 |
785 |
- !arm? ( |
786 |
- dev-lang/yasm |
787 |
- ) |
788 |
- dev-lang/perl |
789 |
- dev-perl/JSON |
790 |
- >=dev-util/gperf-3.0.3 |
791 |
- dev-util/ninja |
792 |
- net-libs/nodejs |
793 |
- sys-apps/hwids[usb(+)] |
794 |
- >=sys-devel/bison-2.4.3 |
795 |
- sys-devel/flex |
796 |
- virtual/pkgconfig |
797 |
- dev-vcs/git |
798 |
- x11-libs/gtk+:2 |
799 |
- x11-libs/gtk+:3 |
800 |
- $(python_gen_any_dep ' |
801 |
- dev-python/beautifulsoup:python-2[${PYTHON_USEDEP}] |
802 |
- >=dev-python/beautifulsoup-4.3.2:4[${PYTHON_USEDEP}] |
803 |
- dev-python/html5lib[${PYTHON_USEDEP}] |
804 |
- dev-python/simplejson[${PYTHON_USEDEP}] |
805 |
- ') |
806 |
-" |
807 |
- |
808 |
-# Keep this in sync with the python_gen_any_dep call. |
809 |
-python_check_deps() { |
810 |
- has_version --host-root "dev-python/beautifulsoup:python-2[${PYTHON_USEDEP}]" && |
811 |
- has_version --host-root ">=dev-python/beautifulsoup-4.3.2:4[${PYTHON_USEDEP}]" && |
812 |
- has_version --host-root "dev-python/html5lib[${PYTHON_USEDEP}]" && |
813 |
- has_version --host-root "dev-python/simplejson[${PYTHON_USEDEP}]" |
814 |
-} |
815 |
- |
816 |
-if ! has chromium_pkg_die ${EBUILD_DEATH_HOOKS}; then |
817 |
- EBUILD_DEATH_HOOKS+=" chromium_pkg_die"; |
818 |
-fi |
819 |
- |
820 |
-DISABLE_AUTOFORMATTING="yes" |
821 |
-DOC_CONTENTS=" |
822 |
-Some web pages may require additional fonts to display properly. |
823 |
-Try installing some of the following packages if some characters |
824 |
-are not displayed properly: |
825 |
-- media-fonts/arphicfonts |
826 |
-- media-fonts/bitstream-cyberbit |
827 |
-- media-fonts/droid |
828 |
-- media-fonts/ipamonafont |
829 |
-- media-fonts/noto |
830 |
-- media-fonts/ja-ipafonts |
831 |
-- media-fonts/takao-fonts |
832 |
-- media-fonts/wqy-microhei |
833 |
-- media-fonts/wqy-zenhei |
834 |
- |
835 |
-Depending on your desktop environment, you may need |
836 |
-to install additional packages to get icons on the Downloads page. |
837 |
- |
838 |
-For KDE, the required package is kde-frameworks/oxygen-icons. |
839 |
- |
840 |
-For other desktop environments, try one of the following: |
841 |
-- x11-themes/gnome-icon-theme |
842 |
-- x11-themes/tango-icon-theme |
843 |
-" |
844 |
- |
845 |
-pre_build_checks() { |
846 |
- if [[ ${MERGE_TYPE} != binary ]]; then |
847 |
- local -x CPP="$(tc-getCXX) -E" |
848 |
- if tc-is-clang && ! version_is_at_least "3.9.1" "$(clang-fullversion)"; then |
849 |
- # bugs: #601654 |
850 |
- die "At least clang 3.9.1 is required" |
851 |
- fi |
852 |
- if tc-is-gcc && ! version_is_at_least 4.8 "$(gcc-version)"; then |
853 |
- # bugs: #535730, #525374, #518668, #600288 |
854 |
- die "At least gcc 4.8 is required" |
855 |
- fi |
856 |
- fi |
857 |
- |
858 |
- # Check build requirements, bug #541816 and bug #471810 . |
859 |
- CHECKREQS_MEMORY="3G" |
860 |
- CHECKREQS_DISK_BUILD="5G" |
861 |
- eshopts_push -s extglob |
862 |
- if is-flagq '-g?(gdb)?([1-9])'; then |
863 |
- CHECKREQS_DISK_BUILD="25G" |
864 |
- if ! use component-build; then |
865 |
- CHECKREQS_MEMORY="16G" |
866 |
- fi |
867 |
- fi |
868 |
- eshopts_pop |
869 |
- check-reqs_pkg_setup |
870 |
-} |
871 |
- |
872 |
-pkg_pretend() { |
873 |
- pre_build_checks |
874 |
-} |
875 |
- |
876 |
-pkg_setup() { |
877 |
- pre_build_checks |
878 |
- |
879 |
- # Make sure the build system will use the right python, bug #344367. |
880 |
- python-any-r1_pkg_setup |
881 |
- |
882 |
- chromium_suid_sandbox_check_kernel_config |
883 |
-} |
884 |
- |
885 |
-src_prepare() { |
886 |
- local PATCHES=( |
887 |
- "${FILESDIR}/${PN}-widevine-r1.patch" |
888 |
- "${FILESDIR}/${PN}-FORTIFY_SOURCE.patch" |
889 |
- "${FILESDIR}/${PN}-gn-bootstrap-r2.patch" |
890 |
- ) |
891 |
- |
892 |
- use system-ffmpeg && PATCHES+=( "${FILESDIR}/${PN}-system-ffmpeg-r4.patch" ) |
893 |
- |
894 |
- default |
895 |
- |
896 |
- mkdir -p third_party/node/linux/node-linux-x64/bin || die |
897 |
- ln -s /usr/bin/node third_party/node/linux/node-linux-x64/bin/node || die |
898 |
- |
899 |
- local keeplibs=( |
900 |
- base/third_party/dmg_fp |
901 |
- base/third_party/dynamic_annotations |
902 |
- base/third_party/icu |
903 |
- base/third_party/nspr |
904 |
- base/third_party/superfasthash |
905 |
- base/third_party/symbolize |
906 |
- base/third_party/valgrind |
907 |
- base/third_party/xdg_mime |
908 |
- base/third_party/xdg_user_dirs |
909 |
- breakpad/src/third_party/curl |
910 |
- chrome/third_party/mozilla_security_manager |
911 |
- courgette/third_party |
912 |
- net/third_party/mozilla_security_manager |
913 |
- net/third_party/nss |
914 |
- third_party/WebKit |
915 |
- third_party/analytics |
916 |
- third_party/angle |
917 |
- third_party/angle/src/common/third_party/numerics |
918 |
- third_party/angle/src/third_party/compiler |
919 |
- third_party/angle/src/third_party/libXNVCtrl |
920 |
- third_party/angle/src/third_party/murmurhash |
921 |
- third_party/angle/src/third_party/trace_event |
922 |
- third_party/boringssl |
923 |
- third_party/brotli |
924 |
- third_party/cacheinvalidation |
925 |
- third_party/catapult |
926 |
- third_party/catapult/third_party/polymer |
927 |
- third_party/catapult/third_party/py_vulcanize |
928 |
- third_party/catapult/third_party/py_vulcanize/third_party/rcssmin |
929 |
- third_party/catapult/third_party/py_vulcanize/third_party/rjsmin |
930 |
- third_party/catapult/tracing/third_party/d3 |
931 |
- third_party/catapult/tracing/third_party/gl-matrix |
932 |
- third_party/catapult/tracing/third_party/jszip |
933 |
- third_party/catapult/tracing/third_party/mannwhitneyu |
934 |
- third_party/ced |
935 |
- third_party/cld_2 |
936 |
- third_party/cld_3 |
937 |
- third_party/cros_system_api |
938 |
- third_party/devscripts |
939 |
- third_party/dom_distiller_js |
940 |
- third_party/fips181 |
941 |
- third_party/flatbuffers |
942 |
- third_party/flot |
943 |
- third_party/google_input_tools |
944 |
- third_party/google_input_tools/third_party/closure_library |
945 |
- third_party/google_input_tools/third_party/closure_library/third_party/closure |
946 |
- third_party/hunspell |
947 |
- third_party/iccjpeg |
948 |
- third_party/inspector_protocol |
949 |
- third_party/jinja2 |
950 |
- third_party/jstemplate |
951 |
- third_party/khronos |
952 |
- third_party/leveldatabase |
953 |
- third_party/libXNVCtrl |
954 |
- third_party/libaddressinput |
955 |
- third_party/libjingle |
956 |
- third_party/libphonenumber |
957 |
- third_party/libsecret |
958 |
- third_party/libsrtp |
959 |
- third_party/libudev |
960 |
- third_party/libusb |
961 |
- third_party/libwebm |
962 |
- third_party/libxml/chromium |
963 |
- third_party/libyuv |
964 |
- third_party/lss |
965 |
- third_party/lzma_sdk |
966 |
- third_party/markupsafe |
967 |
- third_party/mesa |
968 |
- third_party/modp_b64 |
969 |
- third_party/mt19937ar |
970 |
- third_party/node |
971 |
- third_party/node/node_modules/vulcanize/third_party/UglifyJS2 |
972 |
- third_party/openh264 |
973 |
- third_party/openmax_dl |
974 |
- third_party/opus |
975 |
- third_party/ots |
976 |
- third_party/pdfium |
977 |
- third_party/pdfium/third_party/agg23 |
978 |
- third_party/pdfium/third_party/base |
979 |
- third_party/pdfium/third_party/bigint |
980 |
- third_party/pdfium/third_party/freetype |
981 |
- third_party/pdfium/third_party/lcms2-2.6 |
982 |
- third_party/pdfium/third_party/libjpeg |
983 |
- third_party/pdfium/third_party/libopenjpeg20 |
984 |
- third_party/pdfium/third_party/libpng16 |
985 |
- third_party/pdfium/third_party/libtiff |
986 |
- third_party/pdfium/third_party/zlib_v128 |
987 |
- third_party/ply |
988 |
- third_party/polymer |
989 |
- third_party/protobuf |
990 |
- third_party/protobuf/third_party/six |
991 |
- third_party/qcms |
992 |
- third_party/sfntly |
993 |
- third_party/skia |
994 |
- third_party/smhasher |
995 |
- third_party/sqlite |
996 |
- third_party/tcmalloc |
997 |
- third_party/usrsctp |
998 |
- third_party/web-animations-js |
999 |
- third_party/webdriver |
1000 |
- third_party/webrtc |
1001 |
- third_party/widevine |
1002 |
- third_party/woff2 |
1003 |
- third_party/x86inc |
1004 |
- third_party/zlib/google |
1005 |
- url/third_party/mozilla |
1006 |
- v8/src/third_party/valgrind |
1007 |
- v8/third_party/inspector_protocol |
1008 |
- |
1009 |
- # gyp -> gn leftovers |
1010 |
- base/third_party/libevent |
1011 |
- third_party/adobe |
1012 |
- third_party/speech-dispatcher |
1013 |
- third_party/usb_ids |
1014 |
- third_party/xdg-utils |
1015 |
- third_party/yasm/run_yasm.py |
1016 |
- ) |
1017 |
- if ! use system-ffmpeg; then |
1018 |
- keeplibs+=( third_party/ffmpeg ) |
1019 |
- fi |
1020 |
- if ! use system-libvpx; then |
1021 |
- keeplibs+=( third_party/libvpx ) |
1022 |
- keeplibs+=( third_party/libvpx/source/libvpx/third_party/x86inc ) |
1023 |
- fi |
1024 |
- |
1025 |
- # Remove most bundled libraries. Some are still needed. |
1026 |
- build/linux/unbundle/remove_bundled_libraries.py "${keeplibs[@]}" --do-remove || die |
1027 |
-} |
1028 |
- |
1029 |
-src_configure() { |
1030 |
- local myconf_gn="" |
1031 |
- |
1032 |
- # GN needs explicit config for Debug/Release as opposed to inferring it from build directory. |
1033 |
- myconf_gn+=" is_debug=false" |
1034 |
- |
1035 |
- # Component build isn't generally intended for use by end users. It's mostly useful |
1036 |
- # for development and debugging. |
1037 |
- myconf_gn+=" is_component_build=$(usex component-build true false)" |
1038 |
- |
1039 |
- # Disable nacl, we can't build without pnacl (http://crbug.com/269560). |
1040 |
- myconf_gn+=" enable_nacl=false" |
1041 |
- |
1042 |
- # Use system-provided libraries. |
1043 |
- # TODO: use_system_hunspell (upstream changes needed). |
1044 |
- # TODO: use_system_libsrtp (bug #459932). |
1045 |
- # TODO: use_system_libusb (http://crbug.com/266149). |
1046 |
- # TODO: use_system_opus (https://code.google.com/p/webrtc/issues/detail?id=3077). |
1047 |
- # TODO: use_system_protobuf (bug #525560). |
1048 |
- # TODO: use_system_ssl (http://crbug.com/58087). |
1049 |
- # TODO: use_system_sqlite (http://crbug.com/22208). |
1050 |
- |
1051 |
- # libevent: https://bugs.gentoo.org/593458 |
1052 |
- local gn_system_libraries=( |
1053 |
- flac |
1054 |
- harfbuzz-ng |
1055 |
- icu |
1056 |
- libjpeg |
1057 |
- libpng |
1058 |
- libwebp |
1059 |
- libxml |
1060 |
- libxslt |
1061 |
- re2 |
1062 |
- snappy |
1063 |
- yasm |
1064 |
- zlib |
1065 |
- ) |
1066 |
- if use system-ffmpeg; then |
1067 |
- gn_system_libraries+=( ffmpeg ) |
1068 |
- fi |
1069 |
- if use system-libvpx; then |
1070 |
- gn_system_libraries+=( libvpx ) |
1071 |
- fi |
1072 |
- build/linux/unbundle/replace_gn_files.py --system-libraries "${gn_system_libraries[@]}" || die |
1073 |
- |
1074 |
- # Optional dependencies. |
1075 |
- myconf_gn+=" enable_hangout_services_extension=$(usex hangouts true false)" |
1076 |
- myconf_gn+=" enable_widevine=$(usex widevine true false)" |
1077 |
- myconf_gn+=" use_cups=$(usex cups true false)" |
1078 |
- myconf_gn+=" use_gconf=$(usex gconf true false)" |
1079 |
- myconf_gn+=" use_gnome_keyring=$(usex gnome-keyring true false)" |
1080 |
- myconf_gn+=" use_gtk3=$(usex gtk3 true false)" |
1081 |
- myconf_gn+=" use_kerberos=$(usex kerberos true false)" |
1082 |
- myconf_gn+=" use_pulseaudio=$(usex pulseaudio true false)" |
1083 |
- |
1084 |
- # TODO: link_pulseaudio=true for GN. |
1085 |
- |
1086 |
- myconf_gn+=" fieldtrial_testing_like_official_build=true" |
1087 |
- |
1088 |
- if tc-is-clang; then |
1089 |
- myconf_gn+=" is_clang=true clang_base_path=\"/usr\" clang_use_chrome_plugins=false" |
1090 |
- else |
1091 |
- myconf_gn+=" is_clang=false" |
1092 |
- fi |
1093 |
- |
1094 |
- # Never use bundled gold binary. Disable gold linker flags for now. |
1095 |
- # Do not use bundled clang. |
1096 |
- # Trying to use gold results in linker crash. |
1097 |
- myconf_gn+=" use_gold=false use_sysroot=false linux_use_bundled_binutils=false" |
1098 |
- |
1099 |
- ffmpeg_branding="$(usex proprietary-codecs Chrome Chromium)" |
1100 |
- myconf_gn+=" proprietary_codecs=$(usex proprietary-codecs true false)" |
1101 |
- myconf_gn+=" ffmpeg_branding=\"${ffmpeg_branding}\"" |
1102 |
- |
1103 |
- # Set up Google API keys, see http://www.chromium.org/developers/how-tos/api-keys . |
1104 |
- # Note: these are for Gentoo use ONLY. For your own distribution, |
1105 |
- # please get your own set of keys. Feel free to contact chromium@g.o |
1106 |
- # for more info. |
1107 |
- local google_api_key="AIzaSyDEAOvatFo0eTgsV_ZlEzx0ObmepsMzfAc" |
1108 |
- local google_default_client_id="329227923882.apps.googleusercontent.com" |
1109 |
- local google_default_client_secret="vgKG0NNv7GoDpbtoFNLxCUXu" |
1110 |
- myconf_gn+=" google_api_key=\"${google_api_key}\"" |
1111 |
- myconf_gn+=" google_default_client_id=\"${google_default_client_id}\"" |
1112 |
- myconf_gn+=" google_default_client_secret=\"${google_default_client_secret}\"" |
1113 |
- |
1114 |
- local myarch="$(tc-arch)" |
1115 |
- if [[ $myarch = amd64 ]] ; then |
1116 |
- target_arch=x64 |
1117 |
- ffmpeg_target_arch=x64 |
1118 |
- elif [[ $myarch = x86 ]] ; then |
1119 |
- target_arch=ia32 |
1120 |
- ffmpeg_target_arch=ia32 |
1121 |
- elif [[ $myarch = arm64 ]] ; then |
1122 |
- target_arch=arm64 |
1123 |
- ffmpeg_target_arch=arm64 |
1124 |
- elif [[ $myarch = arm ]] ; then |
1125 |
- target_arch=arm |
1126 |
- ffmpeg_target_arch=$(usex neon arm-neon arm) |
1127 |
- else |
1128 |
- die "Failed to determine target arch, got '$myarch'." |
1129 |
- fi |
1130 |
- |
1131 |
- # Make sure that -Werror doesn't get added to CFLAGS by the build system. |
1132 |
- # Depending on GCC version the warnings are different and we don't want |
1133 |
- # the build to fail because of that. |
1134 |
- myconf_gn+=" treat_warnings_as_errors=false" |
1135 |
- |
1136 |
- # Disable fatal linker warnings, bug 506268. |
1137 |
- myconf_gn+=" fatal_linker_warnings=false" |
1138 |
- |
1139 |
- # Avoid CFLAGS problems, bug #352457, bug #390147. |
1140 |
- if ! use custom-cflags; then |
1141 |
- replace-flags "-Os" "-O2" |
1142 |
- strip-flags |
1143 |
- |
1144 |
- # Prevent linker from running out of address space, bug #471810 . |
1145 |
- if use x86; then |
1146 |
- filter-flags "-g*" |
1147 |
- fi |
1148 |
- |
1149 |
- # Prevent libvpx build failures. Bug 530248, 544702, 546984. |
1150 |
- if [[ ${myarch} == amd64 || ${myarch} == x86 ]]; then |
1151 |
- filter-flags -mno-mmx -mno-sse2 -mno-ssse3 -mno-sse4.1 -mno-avx -mno-avx2 |
1152 |
- fi |
1153 |
- fi |
1154 |
- |
1155 |
- # Make sure the build system will use the right tools, bug #340795. |
1156 |
- tc-export AR CC CXX NM |
1157 |
- |
1158 |
- # https://bugs.gentoo.org/588596 |
1159 |
- append-cxxflags $(test-flags-CXX -fno-delete-null-pointer-checks) |
1160 |
- |
1161 |
- # Define a custom toolchain for GN |
1162 |
- myconf_gn+=" custom_toolchain=\"${FILESDIR}/toolchain:default\"" |
1163 |
- |
1164 |
- # Tools for building programs to be executed on the build system, bug #410883. |
1165 |
- if tc-is-cross-compiler; then |
1166 |
- export AR_host=$(tc-getBUILD_AR) |
1167 |
- export CC_host=$(tc-getBUILD_CC) |
1168 |
- export CXX_host=$(tc-getBUILD_CXX) |
1169 |
- export NM_host=$(tc-getBUILD_NM) |
1170 |
- fi |
1171 |
- |
1172 |
- # Bug 491582. |
1173 |
- export TMPDIR="${WORKDIR}/temp" |
1174 |
- mkdir -p -m 755 "${TMPDIR}" || die |
1175 |
- |
1176 |
- if ! use system-ffmpeg; then |
1177 |
- local build_ffmpeg_args="" |
1178 |
- if use pic && [[ "${ffmpeg_target_arch}" == "ia32" ]]; then |
1179 |
- build_ffmpeg_args+=" --disable-asm" |
1180 |
- fi |
1181 |
- |
1182 |
- # Re-configure bundled ffmpeg. See bug #491378 for example reasons. |
1183 |
- einfo "Configuring bundled ffmpeg..." |
1184 |
- pushd third_party/ffmpeg > /dev/null || die |
1185 |
- chromium/scripts/build_ffmpeg.py linux ${ffmpeg_target_arch} \ |
1186 |
- --branding ${ffmpeg_branding} -- ${build_ffmpeg_args} || die |
1187 |
- chromium/scripts/copy_config.sh || die |
1188 |
- chromium/scripts/generate_gn.py || die |
1189 |
- popd > /dev/null || die |
1190 |
- fi |
1191 |
- |
1192 |
- third_party/libaddressinput/chromium/tools/update-strings.py || die |
1193 |
- |
1194 |
- touch chrome/test/data/webui/i18n_process_css_test.html || die |
1195 |
- |
1196 |
- einfo "Configuring Chromium..." |
1197 |
- # TODO: bootstrapped gn binary hangs when using tcmalloc with portage's sandbox. |
1198 |
- tools/gn/bootstrap/bootstrap.py -v --gn-gen-args "${myconf_gn} use_allocator=\"none\"" || die |
1199 |
- myconf_gn+=" use_allocator=$(usex tcmalloc \"tcmalloc\" \"none\")" |
1200 |
- out/Release/gn gen --args="${myconf_gn}" out/Release || die |
1201 |
-} |
1202 |
- |
1203 |
-eninja() { |
1204 |
- if [[ -z ${NINJAOPTS+set} ]]; then |
1205 |
- local jobs=$(makeopts_jobs) |
1206 |
- local loadavg=$(makeopts_loadavg) |
1207 |
- |
1208 |
- if [[ ${MAKEOPTS} == *-j* && ${jobs} != 999 ]]; then |
1209 |
- NINJAOPTS+=" -j ${jobs}" |
1210 |
- fi |
1211 |
- if [[ ${MAKEOPTS} == *-l* && ${loadavg} != 999 ]]; then |
1212 |
- NINJAOPTS+=" -l ${loadavg}" |
1213 |
- fi |
1214 |
- fi |
1215 |
- set -- ninja -v ${NINJAOPTS} "$@" |
1216 |
- echo "$@" |
1217 |
- "$@" |
1218 |
-} |
1219 |
- |
1220 |
-src_compile() { |
1221 |
- local ninja_targets="chrome chromedriver" |
1222 |
- if use suid; then |
1223 |
- ninja_targets+=" chrome_sandbox" |
1224 |
- fi |
1225 |
- |
1226 |
- # Build mksnapshot and pax-mark it. |
1227 |
- eninja -C out/Release mksnapshot || die |
1228 |
- pax-mark m out/Release/mksnapshot |
1229 |
- |
1230 |
- # Even though ninja autodetects number of CPUs, we respect |
1231 |
- # user's options, for debugging with -j 1 or any other reason. |
1232 |
- eninja -C out/Release ${ninja_targets} || die |
1233 |
- |
1234 |
- pax-mark m out/Release/chrome |
1235 |
-} |
1236 |
- |
1237 |
-src_install() { |
1238 |
- local CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser" |
1239 |
- exeinto "${CHROMIUM_HOME}" |
1240 |
- doexe out/Release/chrome |
1241 |
- |
1242 |
- if use suid; then |
1243 |
- newexe out/Release/chrome_sandbox chrome-sandbox |
1244 |
- fperms 4755 "${CHROMIUM_HOME}/chrome-sandbox" |
1245 |
- fi |
1246 |
- |
1247 |
- doexe out/Release/chromedriver |
1248 |
- |
1249 |
- # if ! use arm; then |
1250 |
- # doexe out/Release/nacl_helper{,_bootstrap} || die |
1251 |
- # insinto "${CHROMIUM_HOME}" |
1252 |
- # doins out/Release/nacl_irt_*.nexe || die |
1253 |
- # doins out/Release/libppGoogleNaClPluginChrome.so || die |
1254 |
- # fi |
1255 |
- |
1256 |
- local sedargs=( -e "s:/usr/lib/:/usr/$(get_libdir)/:g" ) |
1257 |
- sed "${sedargs[@]}" "${FILESDIR}/chromium-launcher-r3.sh" > chromium-launcher.sh || die |
1258 |
- doexe chromium-launcher.sh |
1259 |
- |
1260 |
- # It is important that we name the target "chromium-browser", |
1261 |
- # xdg-utils expect it; bug #355517. |
1262 |
- dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium-browser |
1263 |
- # keep the old symlink around for consistency |
1264 |
- dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium |
1265 |
- |
1266 |
- dosym "${CHROMIUM_HOME}/chromedriver" /usr/bin/chromedriver |
1267 |
- |
1268 |
- # Allow users to override command-line options, bug #357629. |
1269 |
- insinto /etc/chromium |
1270 |
- newins "${FILESDIR}/chromium.default" "default" |
1271 |
- |
1272 |
- pushd out/Release/locales > /dev/null || die |
1273 |
- chromium_remove_language_paks |
1274 |
- popd |
1275 |
- |
1276 |
- if use widevine; then |
1277 |
- # These will be provided by chrome-binary-plugins |
1278 |
- rm out/Release/libwidevinecdm*.so || die |
1279 |
- fi |
1280 |
- |
1281 |
- insinto "${CHROMIUM_HOME}" |
1282 |
- doins out/Release/*.bin |
1283 |
- doins out/Release/*.pak |
1284 |
- doins out/Release/*.so |
1285 |
- |
1286 |
- # Needed by bundled icu |
1287 |
- # doins out/Release/icudtl.dat |
1288 |
- |
1289 |
- doins -r out/Release/locales |
1290 |
- doins -r out/Release/resources |
1291 |
- |
1292 |
- newman out/Release/chrome.1 chromium.1 |
1293 |
- newman out/Release/chrome.1 chromium-browser.1 |
1294 |
- |
1295 |
- # Install icons and desktop entry. |
1296 |
- local branding size |
1297 |
- for size in 16 22 24 32 48 64 128 256 ; do |
1298 |
- case ${size} in |
1299 |
- 16|32) branding="chrome/app/theme/default_100_percent/chromium" ;; |
1300 |
- *) branding="chrome/app/theme/chromium" ;; |
1301 |
- esac |
1302 |
- newicon -s ${size} "${branding}/product_logo_${size}.png" \ |
1303 |
- chromium-browser.png |
1304 |
- done |
1305 |
- |
1306 |
- local mime_types="text/html;text/xml;application/xhtml+xml;" |
1307 |
- mime_types+="x-scheme-handler/http;x-scheme-handler/https;" # bug #360797 |
1308 |
- mime_types+="x-scheme-handler/ftp;" # bug #412185 |
1309 |
- mime_types+="x-scheme-handler/mailto;x-scheme-handler/webcal;" # bug #416393 |
1310 |
- make_desktop_entry \ |
1311 |
- chromium-browser \ |
1312 |
- "Chromium" \ |
1313 |
- chromium-browser \ |
1314 |
- "Network;WebBrowser" \ |
1315 |
- "MimeType=${mime_types}\nStartupWMClass=chromium-browser" |
1316 |
- sed -e "/^Exec/s/$/ %U/" -i "${ED}"/usr/share/applications/*.desktop || die |
1317 |
- |
1318 |
- # Install GNOME default application entry (bug #303100). |
1319 |
- insinto /usr/share/gnome-control-center/default-apps |
1320 |
- newins "${FILESDIR}"/chromium-browser.xml chromium-browser.xml |
1321 |
- |
1322 |
- readme.gentoo_create_doc |
1323 |
-} |
1324 |
- |
1325 |
-pkg_preinst() { |
1326 |
- gnome2_icon_savelist |
1327 |
-} |
1328 |
- |
1329 |
-pkg_postrm() { |
1330 |
- gnome2_icon_cache_update |
1331 |
- xdg_desktop_database_update |
1332 |
-} |
1333 |
- |
1334 |
-pkg_postinst() { |
1335 |
- gnome2_icon_cache_update |
1336 |
- xdg_desktop_database_update |
1337 |
- readme.gentoo_print_elog |
1338 |
-} |
1339 |
|
1340 |
diff --git a/www-client/chromium/chromium-58.0.3029.19.ebuild b/www-client/chromium/chromium-58.0.3029.19.ebuild |
1341 |
deleted file mode 100644 |
1342 |
index 306b006b032..00000000000 |
1343 |
--- a/www-client/chromium/chromium-58.0.3029.19.ebuild |
1344 |
+++ /dev/null |
1345 |
@@ -1,652 +0,0 @@ |
1346 |
-# Copyright 1999-2017 Gentoo Foundation |
1347 |
-# Distributed under the terms of the GNU General Public License v2 |
1348 |
- |
1349 |
-EAPI="6" |
1350 |
-PYTHON_COMPAT=( python2_7 ) |
1351 |
- |
1352 |
-CHROMIUM_LANGS="am ar bg bn ca cs da de el en-GB es es-419 et fa fi fil fr gu he |
1353 |
- 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 |
1354 |
- sv sw ta te th tr uk vi zh-CN zh-TW" |
1355 |
- |
1356 |
-inherit check-reqs chromium-2 eutils gnome2-utils flag-o-matic multilib multiprocessing pax-utils portability python-any-r1 readme.gentoo-r1 toolchain-funcs versionator virtualx xdg-utils |
1357 |
- |
1358 |
-DESCRIPTION="Open-source version of Google Chrome web browser" |
1359 |
-HOMEPAGE="http://chromium.org/" |
1360 |
-SRC_URI="https://commondatastorage.googleapis.com/chromium-browser-official/${P}.tar.xz" |
1361 |
- |
1362 |
-LICENSE="BSD" |
1363 |
-SLOT="0" |
1364 |
-KEYWORDS="~amd64 ~arm ~arm64 ~x86" |
1365 |
-IUSE="component-build cups gconf gnome-keyring gtk3 +hangouts kerberos neon pic +proprietary-codecs pulseaudio selinux +suid +system-ffmpeg +system-libvpx +tcmalloc widevine" |
1366 |
-RESTRICT="!system-ffmpeg? ( proprietary-codecs? ( bindist ) )" |
1367 |
- |
1368 |
-# Native Client binaries are compiled with different set of flags, bug #452066. |
1369 |
-QA_FLAGS_IGNORED=".*\.nexe" |
1370 |
- |
1371 |
-# Native Client binaries may be stripped by the build system, which uses the |
1372 |
-# right tools for it, bug #469144 . |
1373 |
-QA_PRESTRIPPED=".*\.nexe" |
1374 |
- |
1375 |
-COMMON_DEPEND=" |
1376 |
- app-arch/bzip2:= |
1377 |
- cups? ( >=net-print/cups-1.3.11:= ) |
1378 |
- >=dev-libs/elfutils-0.149 |
1379 |
- dev-libs/expat:= |
1380 |
- dev-libs/glib:2 |
1381 |
- dev-libs/icu:= |
1382 |
- >=dev-libs/jsoncpp-0.5.0-r1:= |
1383 |
- dev-libs/libxml2:=[icu] |
1384 |
- dev-libs/libxslt:= |
1385 |
- dev-libs/nspr:= |
1386 |
- >=dev-libs/nss-3.14.3:= |
1387 |
- >=dev-libs/re2-0.2016.05.01:= |
1388 |
- gconf? ( >=gnome-base/gconf-2.24.0:= ) |
1389 |
- gnome-keyring? ( >=gnome-base/libgnome-keyring-3.12:= ) |
1390 |
- >=media-libs/alsa-lib-1.0.19:= |
1391 |
- media-libs/fontconfig:= |
1392 |
- media-libs/freetype:= |
1393 |
- >=media-libs/harfbuzz-1.3.1:=[icu(+)] |
1394 |
- media-libs/libexif:= |
1395 |
- media-libs/libjpeg-turbo:= |
1396 |
- media-libs/libpng:= |
1397 |
- system-libvpx? ( media-libs/libvpx:=[postproc,svc] ) |
1398 |
- media-libs/speex:= |
1399 |
- pulseaudio? ( media-sound/pulseaudio:= ) |
1400 |
- system-ffmpeg? ( >=media-video/ffmpeg-3:= ) |
1401 |
- sys-apps/dbus:= |
1402 |
- sys-apps/pciutils:= |
1403 |
- >=sys-libs/libcap-2.22:= |
1404 |
- virtual/udev |
1405 |
- x11-libs/cairo:= |
1406 |
- x11-libs/gdk-pixbuf:2 |
1407 |
- x11-libs/libdrm |
1408 |
- x11-libs/libX11:= |
1409 |
- x11-libs/libXcomposite:= |
1410 |
- x11-libs/libXcursor:= |
1411 |
- x11-libs/libXdamage:= |
1412 |
- x11-libs/libXext:= |
1413 |
- x11-libs/libXfixes:= |
1414 |
- >=x11-libs/libXi-1.6.0:= |
1415 |
- x11-libs/libXinerama:= |
1416 |
- x11-libs/libXrandr:= |
1417 |
- x11-libs/libXrender:= |
1418 |
- x11-libs/libXScrnSaver:= |
1419 |
- x11-libs/libXtst:= |
1420 |
- x11-libs/pango:= |
1421 |
- app-arch/snappy:= |
1422 |
- media-libs/flac:= |
1423 |
- >=media-libs/libwebp-0.4.0:= |
1424 |
- sys-libs/zlib:=[minizip] |
1425 |
- kerberos? ( virtual/krb5 ) |
1426 |
-" |
1427 |
-# For nvidia-drivers blocker, see bug #413637 . |
1428 |
-RDEPEND="${COMMON_DEPEND} |
1429 |
- !=www-client/chromium-9999 |
1430 |
- !<www-plugins/chrome-binary-plugins-57 |
1431 |
- x11-misc/xdg-utils |
1432 |
- virtual/opengl |
1433 |
- virtual/ttf-fonts |
1434 |
- !gtk3? ( x11-libs/gtk+:2 ) |
1435 |
- gtk3? ( x11-libs/gtk+:3 ) |
1436 |
- selinux? ( sec-policy/selinux-chromium ) |
1437 |
- tcmalloc? ( !<x11-drivers/nvidia-drivers-331.20 ) |
1438 |
- widevine? ( www-plugins/chrome-binary-plugins[widevine(-)] ) |
1439 |
-" |
1440 |
-# dev-vcs/git - https://bugs.gentoo.org/593476 |
1441 |
-DEPEND="${COMMON_DEPEND} |
1442 |
- >=app-arch/gzip-1.7 |
1443 |
- !arm? ( |
1444 |
- dev-lang/yasm |
1445 |
- ) |
1446 |
- dev-lang/perl |
1447 |
- dev-perl/JSON |
1448 |
- >=dev-util/gperf-3.0.3 |
1449 |
- dev-util/ninja |
1450 |
- net-libs/nodejs |
1451 |
- sys-apps/hwids[usb(+)] |
1452 |
- >=sys-devel/bison-2.4.3 |
1453 |
- sys-devel/flex |
1454 |
- virtual/pkgconfig |
1455 |
- dev-vcs/git |
1456 |
- x11-libs/gtk+:2 |
1457 |
- x11-libs/gtk+:3 |
1458 |
- $(python_gen_any_dep ' |
1459 |
- dev-python/beautifulsoup:python-2[${PYTHON_USEDEP}] |
1460 |
- >=dev-python/beautifulsoup-4.3.2:4[${PYTHON_USEDEP}] |
1461 |
- dev-python/html5lib[${PYTHON_USEDEP}] |
1462 |
- dev-python/simplejson[${PYTHON_USEDEP}] |
1463 |
- ') |
1464 |
-" |
1465 |
- |
1466 |
-# Keep this in sync with the python_gen_any_dep call. |
1467 |
-python_check_deps() { |
1468 |
- has_version --host-root "dev-python/beautifulsoup:python-2[${PYTHON_USEDEP}]" && |
1469 |
- has_version --host-root ">=dev-python/beautifulsoup-4.3.2:4[${PYTHON_USEDEP}]" && |
1470 |
- has_version --host-root "dev-python/html5lib[${PYTHON_USEDEP}]" && |
1471 |
- has_version --host-root "dev-python/simplejson[${PYTHON_USEDEP}]" |
1472 |
-} |
1473 |
- |
1474 |
-if ! has chromium_pkg_die ${EBUILD_DEATH_HOOKS}; then |
1475 |
- EBUILD_DEATH_HOOKS+=" chromium_pkg_die"; |
1476 |
-fi |
1477 |
- |
1478 |
-DISABLE_AUTOFORMATTING="yes" |
1479 |
-DOC_CONTENTS=" |
1480 |
-Some web pages may require additional fonts to display properly. |
1481 |
-Try installing some of the following packages if some characters |
1482 |
-are not displayed properly: |
1483 |
-- media-fonts/arphicfonts |
1484 |
-- media-fonts/bitstream-cyberbit |
1485 |
-- media-fonts/droid |
1486 |
-- media-fonts/ipamonafont |
1487 |
-- media-fonts/noto |
1488 |
-- media-fonts/ja-ipafonts |
1489 |
-- media-fonts/takao-fonts |
1490 |
-- media-fonts/wqy-microhei |
1491 |
-- media-fonts/wqy-zenhei |
1492 |
- |
1493 |
-Depending on your desktop environment, you may need |
1494 |
-to install additional packages to get icons on the Downloads page. |
1495 |
- |
1496 |
-For KDE, the required package is kde-frameworks/oxygen-icons. |
1497 |
- |
1498 |
-For other desktop environments, try one of the following: |
1499 |
-- x11-themes/gnome-icon-theme |
1500 |
-- x11-themes/tango-icon-theme |
1501 |
-" |
1502 |
- |
1503 |
-pre_build_checks() { |
1504 |
- if [[ ${MERGE_TYPE} != binary ]]; then |
1505 |
- local -x CPP="$(tc-getCXX) -E" |
1506 |
- if tc-is-clang && ! version_is_at_least "3.9.1" "$(clang-fullversion)"; then |
1507 |
- # bugs: #601654 |
1508 |
- die "At least clang 3.9.1 is required" |
1509 |
- fi |
1510 |
- if tc-is-gcc && ! version_is_at_least 4.8 "$(gcc-version)"; then |
1511 |
- # bugs: #535730, #525374, #518668, #600288 |
1512 |
- die "At least gcc 4.8 is required" |
1513 |
- fi |
1514 |
- fi |
1515 |
- |
1516 |
- # Check build requirements, bug #541816 and bug #471810 . |
1517 |
- CHECKREQS_MEMORY="3G" |
1518 |
- CHECKREQS_DISK_BUILD="5G" |
1519 |
- eshopts_push -s extglob |
1520 |
- if is-flagq '-g?(gdb)?([1-9])'; then |
1521 |
- CHECKREQS_DISK_BUILD="25G" |
1522 |
- if ! use component-build; then |
1523 |
- CHECKREQS_MEMORY="16G" |
1524 |
- fi |
1525 |
- fi |
1526 |
- eshopts_pop |
1527 |
- check-reqs_pkg_setup |
1528 |
-} |
1529 |
- |
1530 |
-pkg_pretend() { |
1531 |
- pre_build_checks |
1532 |
-} |
1533 |
- |
1534 |
-pkg_setup() { |
1535 |
- pre_build_checks |
1536 |
- |
1537 |
- # Make sure the build system will use the right python, bug #344367. |
1538 |
- python-any-r1_pkg_setup |
1539 |
- |
1540 |
- chromium_suid_sandbox_check_kernel_config |
1541 |
-} |
1542 |
- |
1543 |
-src_prepare() { |
1544 |
- local PATCHES=( |
1545 |
- "${FILESDIR}/${PN}-widevine-r1.patch" |
1546 |
- "${FILESDIR}/${PN}-FORTIFY_SOURCE.patch" |
1547 |
- "${FILESDIR}/${PN}-gn-bootstrap-r2.patch" |
1548 |
- "${FILESDIR}/skia-avx2.patch" |
1549 |
- ) |
1550 |
- |
1551 |
- use system-ffmpeg && PATCHES+=( "${FILESDIR}/${PN}-system-ffmpeg-r4.patch" ) |
1552 |
- |
1553 |
- default |
1554 |
- |
1555 |
- mkdir -p third_party/node/linux/node-linux-x64/bin || die |
1556 |
- ln -s "${EPREFIX}"/usr/bin/node third_party/node/linux/node-linux-x64/bin/node || die |
1557 |
- |
1558 |
- local keeplibs=( |
1559 |
- base/third_party/dmg_fp |
1560 |
- base/third_party/dynamic_annotations |
1561 |
- base/third_party/icu |
1562 |
- base/third_party/nspr |
1563 |
- base/third_party/superfasthash |
1564 |
- base/third_party/symbolize |
1565 |
- base/third_party/valgrind |
1566 |
- base/third_party/xdg_mime |
1567 |
- base/third_party/xdg_user_dirs |
1568 |
- breakpad/src/third_party/curl |
1569 |
- chrome/third_party/mozilla_security_manager |
1570 |
- courgette/third_party |
1571 |
- net/third_party/mozilla_security_manager |
1572 |
- net/third_party/nss |
1573 |
- third_party/WebKit |
1574 |
- third_party/analytics |
1575 |
- third_party/angle |
1576 |
- third_party/angle/src/common/third_party/numerics |
1577 |
- third_party/angle/src/third_party/compiler |
1578 |
- third_party/angle/src/third_party/libXNVCtrl |
1579 |
- third_party/angle/src/third_party/murmurhash |
1580 |
- third_party/angle/src/third_party/trace_event |
1581 |
- third_party/boringssl |
1582 |
- third_party/brotli |
1583 |
- third_party/cacheinvalidation |
1584 |
- third_party/catapult |
1585 |
- third_party/catapult/third_party/polymer |
1586 |
- third_party/catapult/third_party/py_vulcanize |
1587 |
- third_party/catapult/third_party/py_vulcanize/third_party/rcssmin |
1588 |
- third_party/catapult/third_party/py_vulcanize/third_party/rjsmin |
1589 |
- third_party/catapult/tracing/third_party/d3 |
1590 |
- third_party/catapult/tracing/third_party/gl-matrix |
1591 |
- third_party/catapult/tracing/third_party/jszip |
1592 |
- third_party/catapult/tracing/third_party/mannwhitneyu |
1593 |
- third_party/ced |
1594 |
- third_party/cld_2 |
1595 |
- third_party/cld_3 |
1596 |
- third_party/cros_system_api |
1597 |
- third_party/devscripts |
1598 |
- third_party/dom_distiller_js |
1599 |
- third_party/fips181 |
1600 |
- third_party/flatbuffers |
1601 |
- third_party/flot |
1602 |
- third_party/google_input_tools |
1603 |
- third_party/google_input_tools/third_party/closure_library |
1604 |
- third_party/google_input_tools/third_party/closure_library/third_party/closure |
1605 |
- third_party/hunspell |
1606 |
- third_party/iccjpeg |
1607 |
- third_party/inspector_protocol |
1608 |
- third_party/jinja2 |
1609 |
- third_party/jstemplate |
1610 |
- third_party/khronos |
1611 |
- third_party/leveldatabase |
1612 |
- third_party/libXNVCtrl |
1613 |
- third_party/libaddressinput |
1614 |
- third_party/libjingle |
1615 |
- third_party/libphonenumber |
1616 |
- third_party/libsecret |
1617 |
- third_party/libsrtp |
1618 |
- third_party/libudev |
1619 |
- third_party/libusb |
1620 |
- third_party/libwebm |
1621 |
- third_party/libxml/chromium |
1622 |
- third_party/libyuv |
1623 |
- third_party/lss |
1624 |
- third_party/lzma_sdk |
1625 |
- third_party/markupsafe |
1626 |
- third_party/mesa |
1627 |
- third_party/modp_b64 |
1628 |
- third_party/mt19937ar |
1629 |
- third_party/node |
1630 |
- third_party/node/node_modules/vulcanize/third_party/UglifyJS2 |
1631 |
- third_party/openh264 |
1632 |
- third_party/openmax_dl |
1633 |
- third_party/opus |
1634 |
- third_party/ots |
1635 |
- third_party/pdfium |
1636 |
- third_party/pdfium/third_party/agg23 |
1637 |
- third_party/pdfium/third_party/base |
1638 |
- third_party/pdfium/third_party/bigint |
1639 |
- third_party/pdfium/third_party/freetype |
1640 |
- third_party/pdfium/third_party/lcms2-2.6 |
1641 |
- third_party/pdfium/third_party/libjpeg |
1642 |
- third_party/pdfium/third_party/libopenjpeg20 |
1643 |
- third_party/pdfium/third_party/libpng16 |
1644 |
- third_party/pdfium/third_party/libtiff |
1645 |
- third_party/pdfium/third_party/zlib_v128 |
1646 |
- third_party/ply |
1647 |
- third_party/polymer |
1648 |
- third_party/protobuf |
1649 |
- third_party/protobuf/third_party/six |
1650 |
- third_party/qcms |
1651 |
- third_party/sfntly |
1652 |
- third_party/skia |
1653 |
- third_party/smhasher |
1654 |
- third_party/sqlite |
1655 |
- third_party/tcmalloc |
1656 |
- third_party/usrsctp |
1657 |
- third_party/web-animations-js |
1658 |
- third_party/webdriver |
1659 |
- third_party/webrtc |
1660 |
- third_party/widevine |
1661 |
- third_party/woff2 |
1662 |
- third_party/x86inc |
1663 |
- third_party/zlib/google |
1664 |
- url/third_party/mozilla |
1665 |
- v8/src/third_party/valgrind |
1666 |
- v8/third_party/inspector_protocol |
1667 |
- |
1668 |
- # gyp -> gn leftovers |
1669 |
- base/third_party/libevent |
1670 |
- third_party/adobe |
1671 |
- third_party/speech-dispatcher |
1672 |
- third_party/usb_ids |
1673 |
- third_party/xdg-utils |
1674 |
- third_party/yasm/run_yasm.py |
1675 |
- ) |
1676 |
- if ! use system-ffmpeg; then |
1677 |
- keeplibs+=( third_party/ffmpeg ) |
1678 |
- fi |
1679 |
- if ! use system-libvpx; then |
1680 |
- keeplibs+=( third_party/libvpx ) |
1681 |
- keeplibs+=( third_party/libvpx/source/libvpx/third_party/x86inc ) |
1682 |
- fi |
1683 |
- |
1684 |
- # Remove most bundled libraries. Some are still needed. |
1685 |
- build/linux/unbundle/remove_bundled_libraries.py "${keeplibs[@]}" --do-remove || die |
1686 |
-} |
1687 |
- |
1688 |
-src_configure() { |
1689 |
- local myconf_gn="" |
1690 |
- |
1691 |
- # GN needs explicit config for Debug/Release as opposed to inferring it from build directory. |
1692 |
- myconf_gn+=" is_debug=false" |
1693 |
- |
1694 |
- # Component build isn't generally intended for use by end users. It's mostly useful |
1695 |
- # for development and debugging. |
1696 |
- myconf_gn+=" is_component_build=$(usex component-build true false)" |
1697 |
- |
1698 |
- # Disable nacl, we can't build without pnacl (http://crbug.com/269560). |
1699 |
- myconf_gn+=" enable_nacl=false" |
1700 |
- |
1701 |
- # Use system-provided libraries. |
1702 |
- # TODO: use_system_hunspell (upstream changes needed). |
1703 |
- # TODO: use_system_libsrtp (bug #459932). |
1704 |
- # TODO: use_system_libusb (http://crbug.com/266149). |
1705 |
- # TODO: use_system_opus (https://code.google.com/p/webrtc/issues/detail?id=3077). |
1706 |
- # TODO: use_system_protobuf (bug #525560). |
1707 |
- # TODO: use_system_ssl (http://crbug.com/58087). |
1708 |
- # TODO: use_system_sqlite (http://crbug.com/22208). |
1709 |
- |
1710 |
- # libevent: https://bugs.gentoo.org/593458 |
1711 |
- local gn_system_libraries=( |
1712 |
- flac |
1713 |
- harfbuzz-ng |
1714 |
- icu |
1715 |
- libjpeg |
1716 |
- libpng |
1717 |
- libwebp |
1718 |
- libxml |
1719 |
- libxslt |
1720 |
- re2 |
1721 |
- snappy |
1722 |
- yasm |
1723 |
- zlib |
1724 |
- ) |
1725 |
- if use system-ffmpeg; then |
1726 |
- gn_system_libraries+=( ffmpeg ) |
1727 |
- fi |
1728 |
- if use system-libvpx; then |
1729 |
- gn_system_libraries+=( libvpx ) |
1730 |
- fi |
1731 |
- build/linux/unbundle/replace_gn_files.py --system-libraries "${gn_system_libraries[@]}" || die |
1732 |
- |
1733 |
- # Optional dependencies. |
1734 |
- myconf_gn+=" enable_hangout_services_extension=$(usex hangouts true false)" |
1735 |
- myconf_gn+=" enable_widevine=$(usex widevine true false)" |
1736 |
- myconf_gn+=" use_cups=$(usex cups true false)" |
1737 |
- myconf_gn+=" use_gconf=$(usex gconf true false)" |
1738 |
- myconf_gn+=" use_gnome_keyring=$(usex gnome-keyring true false)" |
1739 |
- myconf_gn+=" use_gtk3=$(usex gtk3 true false)" |
1740 |
- myconf_gn+=" use_kerberos=$(usex kerberos true false)" |
1741 |
- myconf_gn+=" use_pulseaudio=$(usex pulseaudio true false)" |
1742 |
- |
1743 |
- # TODO: link_pulseaudio=true for GN. |
1744 |
- |
1745 |
- myconf_gn+=" fieldtrial_testing_like_official_build=true" |
1746 |
- |
1747 |
- if tc-is-clang; then |
1748 |
- myconf_gn+=" is_clang=true clang_base_path=\"/usr\" clang_use_chrome_plugins=false" |
1749 |
- else |
1750 |
- myconf_gn+=" is_clang=false" |
1751 |
- fi |
1752 |
- |
1753 |
- # Never use bundled gold binary. Disable gold linker flags for now. |
1754 |
- # Do not use bundled clang. |
1755 |
- # Trying to use gold results in linker crash. |
1756 |
- myconf_gn+=" use_gold=false use_sysroot=false linux_use_bundled_binutils=false" |
1757 |
- |
1758 |
- ffmpeg_branding="$(usex proprietary-codecs Chrome Chromium)" |
1759 |
- myconf_gn+=" proprietary_codecs=$(usex proprietary-codecs true false)" |
1760 |
- myconf_gn+=" ffmpeg_branding=\"${ffmpeg_branding}\"" |
1761 |
- |
1762 |
- # Set up Google API keys, see http://www.chromium.org/developers/how-tos/api-keys . |
1763 |
- # Note: these are for Gentoo use ONLY. For your own distribution, |
1764 |
- # please get your own set of keys. Feel free to contact chromium@g.o |
1765 |
- # for more info. |
1766 |
- local google_api_key="AIzaSyDEAOvatFo0eTgsV_ZlEzx0ObmepsMzfAc" |
1767 |
- local google_default_client_id="329227923882.apps.googleusercontent.com" |
1768 |
- local google_default_client_secret="vgKG0NNv7GoDpbtoFNLxCUXu" |
1769 |
- myconf_gn+=" google_api_key=\"${google_api_key}\"" |
1770 |
- myconf_gn+=" google_default_client_id=\"${google_default_client_id}\"" |
1771 |
- myconf_gn+=" google_default_client_secret=\"${google_default_client_secret}\"" |
1772 |
- |
1773 |
- local myarch="$(tc-arch)" |
1774 |
- if [[ $myarch = amd64 ]] ; then |
1775 |
- target_arch=x64 |
1776 |
- ffmpeg_target_arch=x64 |
1777 |
- elif [[ $myarch = x86 ]] ; then |
1778 |
- target_arch=ia32 |
1779 |
- ffmpeg_target_arch=ia32 |
1780 |
- elif [[ $myarch = arm64 ]] ; then |
1781 |
- target_arch=arm64 |
1782 |
- ffmpeg_target_arch=arm64 |
1783 |
- elif [[ $myarch = arm ]] ; then |
1784 |
- target_arch=arm |
1785 |
- ffmpeg_target_arch=$(usex neon arm-neon arm) |
1786 |
- else |
1787 |
- die "Failed to determine target arch, got '$myarch'." |
1788 |
- fi |
1789 |
- |
1790 |
- # Make sure that -Werror doesn't get added to CFLAGS by the build system. |
1791 |
- # Depending on GCC version the warnings are different and we don't want |
1792 |
- # the build to fail because of that. |
1793 |
- myconf_gn+=" treat_warnings_as_errors=false" |
1794 |
- |
1795 |
- # Disable fatal linker warnings, bug 506268. |
1796 |
- myconf_gn+=" fatal_linker_warnings=false" |
1797 |
- |
1798 |
- # Avoid CFLAGS problems, bug #352457, bug #390147. |
1799 |
- if ! use custom-cflags; then |
1800 |
- replace-flags "-Os" "-O2" |
1801 |
- strip-flags |
1802 |
- |
1803 |
- # Prevent linker from running out of address space, bug #471810 . |
1804 |
- if use x86; then |
1805 |
- filter-flags "-g*" |
1806 |
- fi |
1807 |
- |
1808 |
- # Prevent libvpx build failures. Bug 530248, 544702, 546984. |
1809 |
- if [[ ${myarch} == amd64 || ${myarch} == x86 ]]; then |
1810 |
- filter-flags -mno-mmx -mno-sse2 -mno-ssse3 -mno-sse4.1 -mno-avx -mno-avx2 |
1811 |
- fi |
1812 |
- fi |
1813 |
- |
1814 |
- # Make sure the build system will use the right tools, bug #340795. |
1815 |
- tc-export AR CC CXX NM |
1816 |
- |
1817 |
- # https://bugs.gentoo.org/588596 |
1818 |
- append-cxxflags $(test-flags-CXX -fno-delete-null-pointer-checks) |
1819 |
- |
1820 |
- # Define a custom toolchain for GN |
1821 |
- myconf_gn+=" custom_toolchain=\"${FILESDIR}/toolchain:default\"" |
1822 |
- |
1823 |
- # Tools for building programs to be executed on the build system, bug #410883. |
1824 |
- if tc-is-cross-compiler; then |
1825 |
- export AR_host=$(tc-getBUILD_AR) |
1826 |
- export CC_host=$(tc-getBUILD_CC) |
1827 |
- export CXX_host=$(tc-getBUILD_CXX) |
1828 |
- export NM_host=$(tc-getBUILD_NM) |
1829 |
- fi |
1830 |
- |
1831 |
- # Bug 491582. |
1832 |
- export TMPDIR="${WORKDIR}/temp" |
1833 |
- mkdir -p -m 755 "${TMPDIR}" || die |
1834 |
- |
1835 |
- if ! use system-ffmpeg; then |
1836 |
- local build_ffmpeg_args="" |
1837 |
- if use pic && [[ "${ffmpeg_target_arch}" == "ia32" ]]; then |
1838 |
- build_ffmpeg_args+=" --disable-asm" |
1839 |
- fi |
1840 |
- |
1841 |
- # Re-configure bundled ffmpeg. See bug #491378 for example reasons. |
1842 |
- einfo "Configuring bundled ffmpeg..." |
1843 |
- pushd third_party/ffmpeg > /dev/null || die |
1844 |
- chromium/scripts/build_ffmpeg.py linux ${ffmpeg_target_arch} \ |
1845 |
- --branding ${ffmpeg_branding} -- ${build_ffmpeg_args} || die |
1846 |
- chromium/scripts/copy_config.sh || die |
1847 |
- chromium/scripts/generate_gn.py || die |
1848 |
- popd > /dev/null || die |
1849 |
- fi |
1850 |
- |
1851 |
- third_party/libaddressinput/chromium/tools/update-strings.py || die |
1852 |
- |
1853 |
- touch chrome/test/data/webui/i18n_process_css_test.html || die |
1854 |
- |
1855 |
- einfo "Configuring Chromium..." |
1856 |
- # TODO: bootstrapped gn binary hangs when using tcmalloc with portage's sandbox. |
1857 |
- tools/gn/bootstrap/bootstrap.py -v --gn-gen-args "${myconf_gn} use_allocator=\"none\"" || die |
1858 |
- myconf_gn+=" use_allocator=$(usex tcmalloc \"tcmalloc\" \"none\")" |
1859 |
- out/Release/gn gen --args="${myconf_gn}" out/Release || die |
1860 |
-} |
1861 |
- |
1862 |
-eninja() { |
1863 |
- if [[ -z ${NINJAOPTS+set} ]]; then |
1864 |
- local jobs=$(makeopts_jobs) |
1865 |
- local loadavg=$(makeopts_loadavg) |
1866 |
- |
1867 |
- if [[ ${MAKEOPTS} == *-j* && ${jobs} != 999 ]]; then |
1868 |
- NINJAOPTS+=" -j ${jobs}" |
1869 |
- fi |
1870 |
- if [[ ${MAKEOPTS} == *-l* && ${loadavg} != 999 ]]; then |
1871 |
- NINJAOPTS+=" -l ${loadavg}" |
1872 |
- fi |
1873 |
- fi |
1874 |
- set -- ninja -v ${NINJAOPTS} "$@" |
1875 |
- echo "$@" |
1876 |
- "$@" |
1877 |
-} |
1878 |
- |
1879 |
-src_compile() { |
1880 |
- local ninja_targets="chrome chromedriver" |
1881 |
- if use suid; then |
1882 |
- ninja_targets+=" chrome_sandbox" |
1883 |
- fi |
1884 |
- |
1885 |
- # Build mksnapshot and pax-mark it. |
1886 |
- eninja -C out/Release mksnapshot || die |
1887 |
- pax-mark m out/Release/mksnapshot |
1888 |
- |
1889 |
- # Even though ninja autodetects number of CPUs, we respect |
1890 |
- # user's options, for debugging with -j 1 or any other reason. |
1891 |
- eninja -C out/Release ${ninja_targets} || die |
1892 |
- |
1893 |
- pax-mark m out/Release/chrome |
1894 |
-} |
1895 |
- |
1896 |
-src_install() { |
1897 |
- local CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser" |
1898 |
- exeinto "${CHROMIUM_HOME}" |
1899 |
- doexe out/Release/chrome |
1900 |
- |
1901 |
- if use suid; then |
1902 |
- newexe out/Release/chrome_sandbox chrome-sandbox |
1903 |
- fperms 4755 "${CHROMIUM_HOME}/chrome-sandbox" |
1904 |
- fi |
1905 |
- |
1906 |
- doexe out/Release/chromedriver |
1907 |
- |
1908 |
- # if ! use arm; then |
1909 |
- # doexe out/Release/nacl_helper{,_bootstrap} || die |
1910 |
- # insinto "${CHROMIUM_HOME}" |
1911 |
- # doins out/Release/nacl_irt_*.nexe || die |
1912 |
- # doins out/Release/libppGoogleNaClPluginChrome.so || die |
1913 |
- # fi |
1914 |
- |
1915 |
- local sedargs=( -e "s:/usr/lib/:/usr/$(get_libdir)/:g" ) |
1916 |
- sed "${sedargs[@]}" "${FILESDIR}/chromium-launcher-r3.sh" > chromium-launcher.sh || die |
1917 |
- doexe chromium-launcher.sh |
1918 |
- |
1919 |
- # It is important that we name the target "chromium-browser", |
1920 |
- # xdg-utils expect it; bug #355517. |
1921 |
- dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium-browser |
1922 |
- # keep the old symlink around for consistency |
1923 |
- dosym "${CHROMIUM_HOME}/chromium-launcher.sh" /usr/bin/chromium |
1924 |
- |
1925 |
- dosym "${CHROMIUM_HOME}/chromedriver" /usr/bin/chromedriver |
1926 |
- |
1927 |
- # Allow users to override command-line options, bug #357629. |
1928 |
- insinto /etc/chromium |
1929 |
- newins "${FILESDIR}/chromium.default" "default" |
1930 |
- |
1931 |
- pushd out/Release/locales > /dev/null || die |
1932 |
- chromium_remove_language_paks |
1933 |
- popd |
1934 |
- |
1935 |
- if use widevine; then |
1936 |
- # These will be provided by chrome-binary-plugins |
1937 |
- rm out/Release/libwidevinecdm*.so || die |
1938 |
- fi |
1939 |
- |
1940 |
- insinto "${CHROMIUM_HOME}" |
1941 |
- doins out/Release/*.bin |
1942 |
- doins out/Release/*.pak |
1943 |
- doins out/Release/*.so |
1944 |
- |
1945 |
- # Needed by bundled icu |
1946 |
- # doins out/Release/icudtl.dat |
1947 |
- |
1948 |
- doins -r out/Release/locales |
1949 |
- doins -r out/Release/resources |
1950 |
- |
1951 |
- newman out/Release/chrome.1 chromium.1 |
1952 |
- newman out/Release/chrome.1 chromium-browser.1 |
1953 |
- |
1954 |
- # Install icons and desktop entry. |
1955 |
- local branding size |
1956 |
- for size in 16 22 24 32 48 64 128 256 ; do |
1957 |
- case ${size} in |
1958 |
- 16|32) branding="chrome/app/theme/default_100_percent/chromium" ;; |
1959 |
- *) branding="chrome/app/theme/chromium" ;; |
1960 |
- esac |
1961 |
- newicon -s ${size} "${branding}/product_logo_${size}.png" \ |
1962 |
- chromium-browser.png |
1963 |
- done |
1964 |
- |
1965 |
- local mime_types="text/html;text/xml;application/xhtml+xml;" |
1966 |
- mime_types+="x-scheme-handler/http;x-scheme-handler/https;" # bug #360797 |
1967 |
- mime_types+="x-scheme-handler/ftp;" # bug #412185 |
1968 |
- mime_types+="x-scheme-handler/mailto;x-scheme-handler/webcal;" # bug #416393 |
1969 |
- make_desktop_entry \ |
1970 |
- chromium-browser \ |
1971 |
- "Chromium" \ |
1972 |
- chromium-browser \ |
1973 |
- "Network;WebBrowser" \ |
1974 |
- "MimeType=${mime_types}\nStartupWMClass=chromium-browser" |
1975 |
- sed -e "/^Exec/s/$/ %U/" -i "${ED}"/usr/share/applications/*.desktop || die |
1976 |
- |
1977 |
- # Install GNOME default application entry (bug #303100). |
1978 |
- insinto /usr/share/gnome-control-center/default-apps |
1979 |
- newins "${FILESDIR}"/chromium-browser.xml chromium-browser.xml |
1980 |
- |
1981 |
- readme.gentoo_create_doc |
1982 |
-} |
1983 |
- |
1984 |
-pkg_preinst() { |
1985 |
- gnome2_icon_savelist |
1986 |
-} |
1987 |
- |
1988 |
-pkg_postrm() { |
1989 |
- gnome2_icon_cache_update |
1990 |
- xdg_desktop_database_update |
1991 |
-} |
1992 |
- |
1993 |
-pkg_postinst() { |
1994 |
- gnome2_icon_cache_update |
1995 |
- xdg_desktop_database_update |
1996 |
- readme.gentoo_print_elog |
1997 |
-} |