1 |
commit: a0f61be8a83c5fb4c088d60a8bf0acaaa27ac3bb |
2 |
Author: Mart Raudsepp <leio <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Feb 17 21:38:08 2020 +0000 |
4 |
Commit: Mart Raudsepp <leio <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Feb 17 21:53:22 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a0f61be8 |
7 |
|
8 |
net-libs/webkit-gtk: security cleanup |
9 |
|
10 |
Bug: https://bugs.gentoo.org/709612 |
11 |
Package-Manager: Portage-2.3.84, Repoman-2.3.20 |
12 |
Signed-off-by: Mart Raudsepp <leio <AT> gentoo.org> |
13 |
|
14 |
net-libs/webkit-gtk/Manifest | 1 - |
15 |
.../files/2.26.3-fix-noGL-wayland-build.patch | 39 --- |
16 |
net-libs/webkit-gtk/webkit-gtk-2.26.3-r1.ebuild | 287 --------------------- |
17 |
net-libs/webkit-gtk/webkit-gtk-2.26.3.ebuild | 287 --------------------- |
18 |
4 files changed, 614 deletions(-) |
19 |
|
20 |
diff --git a/net-libs/webkit-gtk/Manifest b/net-libs/webkit-gtk/Manifest |
21 |
index 963bb2a94ad..cc4924be113 100644 |
22 |
--- a/net-libs/webkit-gtk/Manifest |
23 |
+++ b/net-libs/webkit-gtk/Manifest |
24 |
@@ -1,3 +1,2 @@ |
25 |
DIST webkitgtk-2.24.4.tar.xz 17575784 BLAKE2B c30683ea365a50d7def572305b49278343d67739f9bd3cfd78cb08b5cc87b5453504df9b09752f8d6483b18b9b812f3d3cddc084762cfa8990fcc651660b89c2 SHA512 1d713955a735ae2e2229beea7bda7f518a6247c6aa7f5753aeb5b5c6395339d451d0d146f7188e7ba65cb82ea5a74a5e73e956fe59d5f5f97659a44af33df112 |
26 |
-DIST webkitgtk-2.26.3.tar.xz 19331900 BLAKE2B 14c31b0f640b0f859a3c1eeda542f176f6c7981270c5be3225556eb4a1027a2511039cf0f33682faa93846c4ca5ed64158574a9b8a662a4a200b97cad28d5ed0 SHA512 9575c86ab5752c09841878cf55134e7de9a87200e55017859cd02affb1cadd58031a7b6f67a580e87a1dfe4fc830fed9774ba289e7244d3ead9eb9328e76d7c9 |
27 |
DIST webkitgtk-2.26.4.tar.xz 19329636 BLAKE2B 9dc88bf9e2bec4f3ccc316f4967e991595fa17151ad74781ea514e72700f2bd1f3ed32c5ee662eb1d04fa023e7c33ad1215078415b67c939ee0d4f6d55358d4a SHA512 b4d96672d0a41fb7591dd312254fc1b7a85e632923bf2d954d79d395306db96d5a6b4f85e24ea4ba0a447e45e29a41882249c26f6b2d6d572225abefcf28a474 |
28 |
|
29 |
diff --git a/net-libs/webkit-gtk/files/2.26.3-fix-noGL-wayland-build.patch b/net-libs/webkit-gtk/files/2.26.3-fix-noGL-wayland-build.patch |
30 |
deleted file mode 100644 |
31 |
index 4549f1712e6..00000000000 |
32 |
--- a/net-libs/webkit-gtk/files/2.26.3-fix-noGL-wayland-build.patch |
33 |
+++ /dev/null |
34 |
@@ -1,39 +0,0 @@ |
35 |
-From 874dceeafc08edc979093509dff3ee6a8b25c432 Mon Sep 17 00:00:00 2001 |
36 |
-From: "commit-queue@××××××.org" |
37 |
- <commit-queue@××××××.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc> |
38 |
-Date: Thu, 19 Sep 2019 02:34:49 +0000 |
39 |
-Subject: [PATCH] [GTK] Compilation errors when GL is disabled |
40 |
- https://bugs.webkit.org/show_bug.cgi?id=200223 |
41 |
- |
42 |
-Fix following compilation error when building with ENABLE_OPENGL=OFF |
43 |
-../../Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp:123:51: error: use of undeclared identifier 'WaylandCompositor' |
44 |
-parameters.waylandCompositorDisplayName = WaylandCompositor::singleton().displayName(); |
45 |
- ^ |
46 |
-Patch by Yury Semikhatsky <yurys@××××××××.org> on 2019-09-18 |
47 |
-Reviewed by Philippe Normand. |
48 |
- |
49 |
-* UIProcess/glib/WebProcessPoolGLib.cpp: |
50 |
-(WebKit::WebProcessPool::platformInitializeWebProcess): only make a call when using EGL, this matches |
51 |
-guards in WaylandCompositor.h. The condition was changed in r245807. |
52 |
- |
53 |
-git-svn-id: https://svn.webkit.org/repository/webkit/trunk@250077 268f45cc-cd09-0410-ab3c-d52691b4dbfc |
54 |
---- |
55 |
- Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp | 2 +- |
56 |
- 1 file changed, 1 insertion(+), 1 deletion(-) |
57 |
- |
58 |
-diff --git a/Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp b/Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp |
59 |
-index 37ece2f4576..a380a25fa4b 100644 |
60 |
---- a/Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp |
61 |
-+++ b/Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp |
62 |
-@@ -119,7 +119,7 @@ void WebProcessPool::platformInitializeWebProcess(const WebProcessProxy& process |
63 |
- parameters.hostClientFileDescriptor = wpe_renderer_host_create_client(); |
64 |
- parameters.implementationLibraryName = FileSystem::fileSystemRepresentation(wpe_loader_get_loaded_implementation_library_name()); |
65 |
- } |
66 |
--#else |
67 |
-+#elif USE(EGL) |
68 |
- parameters.waylandCompositorDisplayName = WaylandCompositor::singleton().displayName(); |
69 |
- #endif |
70 |
- } |
71 |
--- |
72 |
-2.20.1 |
73 |
- |
74 |
|
75 |
diff --git a/net-libs/webkit-gtk/webkit-gtk-2.26.3-r1.ebuild b/net-libs/webkit-gtk/webkit-gtk-2.26.3-r1.ebuild |
76 |
deleted file mode 100644 |
77 |
index 859e268912a..00000000000 |
78 |
--- a/net-libs/webkit-gtk/webkit-gtk-2.26.3-r1.ebuild |
79 |
+++ /dev/null |
80 |
@@ -1,287 +0,0 @@ |
81 |
-# Copyright 1999-2020 Gentoo Authors |
82 |
-# Distributed under the terms of the GNU General Public License v2 |
83 |
- |
84 |
-EAPI=6 |
85 |
-CMAKE_MAKEFILE_GENERATOR="ninja" |
86 |
-PYTHON_COMPAT=( python{3_6,3_7} ) |
87 |
-USE_RUBY="ruby24 ruby25 ruby26 ruby27" |
88 |
-CMAKE_MIN_VERSION=3.10 |
89 |
- |
90 |
-inherit check-reqs cmake-utils flag-o-matic gnome2 pax-utils python-any-r1 ruby-single toolchain-funcs virtualx |
91 |
- |
92 |
-MY_P="webkitgtk-${PV}" |
93 |
-DESCRIPTION="Open source web browser engine" |
94 |
-HOMEPAGE="https://www.webkitgtk.org" |
95 |
-SRC_URI="https://www.webkitgtk.org/releases/${MY_P}.tar.xz" |
96 |
- |
97 |
-LICENSE="LGPL-2+ BSD" |
98 |
-SLOT="4/37" # soname version of libwebkit2gtk-4.0 |
99 |
-KEYWORDS="~amd64 ~ia64 ~ppc64 ~sparc ~x86" |
100 |
- |
101 |
-IUSE="aqua coverage +egl +geolocation gles2-only gnome-keyring +gstreamer gtk-doc +introspection +jpeg2k +jumbo-build libnotify +opengl seccomp spell wayland +X" |
102 |
- |
103 |
-# gstreamer with opengl/gles2 needs egl |
104 |
-REQUIRED_USE=" |
105 |
- gles2-only? ( egl !opengl ) |
106 |
- gstreamer? ( opengl? ( egl ) ) |
107 |
- wayland? ( egl ) |
108 |
- || ( aqua wayland X ) |
109 |
-" |
110 |
- |
111 |
-# Tests fail to link for inexplicable reasons |
112 |
-# https://bugs.webkit.org/show_bug.cgi?id=148210 |
113 |
-RESTRICT="test" |
114 |
- |
115 |
-# Aqua support in gtk3 is untested |
116 |
-# Dependencies found at Source/cmake/OptionsGTK.cmake |
117 |
-# Various compile-time optionals for gtk+-3.22.0 - ensure it |
118 |
-# Missing WebRTC support, but ENABLE_MEDIA_STREAM/ENABLE_WEB_RTC is experimental upstream (PRIVATE OFF) and shouldn't be used yet in 2.26 |
119 |
-# >=gst-plugins-opus-1.14.4-r1 for opusparse (required by MSE) |
120 |
-wpe_depend=" |
121 |
- >=gui-libs/libwpe-1.3.0:1.0 |
122 |
- >=gui-libs/wpebackend-fdo-1.3.1:1.0 |
123 |
-" |
124 |
-RDEPEND=" |
125 |
- >=x11-libs/cairo-1.16.0:=[X?] |
126 |
- >=media-libs/fontconfig-2.13.0:1.0 |
127 |
- >=media-libs/freetype-2.9.0:2 |
128 |
- >=dev-libs/libgcrypt-1.7.0:0= |
129 |
- >=x11-libs/gtk+-3.22.0:3[aqua?,introspection?,wayland?,X?] |
130 |
- >=media-libs/harfbuzz-1.4.2:=[icu(+)] |
131 |
- >=dev-libs/icu-3.8.1-r1:= |
132 |
- virtual/jpeg:0= |
133 |
- >=net-libs/libsoup-2.54:2.4[introspection?] |
134 |
- >=dev-libs/libxml2-2.8.0:2 |
135 |
- >=media-libs/libpng-1.4:0= |
136 |
- dev-db/sqlite:3= |
137 |
- sys-libs/zlib:0 |
138 |
- >=dev-libs/atk-2.16.0 |
139 |
- media-libs/libwebp:= |
140 |
- |
141 |
- >=dev-libs/glib-2.44.0:2 |
142 |
- >=dev-libs/libxslt-1.1.7 |
143 |
- media-libs/woff2 |
144 |
- gnome-keyring? ( app-crypt/libsecret ) |
145 |
- introspection? ( >=dev-libs/gobject-introspection-1.32.0:= ) |
146 |
- dev-libs/libtasn1:= |
147 |
- spell? ( >=app-text/enchant-0.22:2 ) |
148 |
- gstreamer? ( |
149 |
- >=media-libs/gstreamer-1.14:1.0 |
150 |
- >=media-libs/gst-plugins-base-1.14:1.0[egl?,opengl?] |
151 |
- gles2-only? ( media-libs/gst-plugins-base:1.0[gles2] ) |
152 |
- >=media-plugins/gst-plugins-opus-1.14.4-r1:1.0 |
153 |
- >=media-libs/gst-plugins-bad-1.14:1.0 ) |
154 |
- |
155 |
- X? ( |
156 |
- x11-libs/libX11 |
157 |
- x11-libs/libXcomposite |
158 |
- x11-libs/libXdamage |
159 |
- x11-libs/libXrender |
160 |
- x11-libs/libXt ) |
161 |
- |
162 |
- libnotify? ( x11-libs/libnotify ) |
163 |
- dev-libs/hyphen |
164 |
- jpeg2k? ( >=media-libs/openjpeg-2.2.0:2= ) |
165 |
- |
166 |
- egl? ( media-libs/mesa[egl] ) |
167 |
- gles2-only? ( media-libs/mesa[gles2] ) |
168 |
- opengl? ( virtual/opengl ) |
169 |
- wayland? ( |
170 |
- opengl? ( ${wpe_depend} ) |
171 |
- gles2-only? ( ${wpe_depend} ) |
172 |
- ) |
173 |
- |
174 |
- seccomp? ( |
175 |
- >=sys-apps/bubblewrap-0.3.1 |
176 |
- sys-libs/libseccomp |
177 |
- sys-apps/xdg-dbus-proxy |
178 |
- ) |
179 |
-" |
180 |
-unset wpe_depend |
181 |
-# paxctl needed for bug #407085 |
182 |
-# Need real bison, not yacc |
183 |
-DEPEND="${RDEPEND} |
184 |
- ${PYTHON_DEPS} |
185 |
- ${RUBY_DEPS} |
186 |
- >=app-accessibility/at-spi2-core-2.5.3 |
187 |
- dev-util/glib-utils |
188 |
- >=dev-util/gperf-3.0.1 |
189 |
- >=sys-devel/bison-2.4.3 |
190 |
- || ( >=sys-devel/gcc-7.3 >=sys-devel/clang-5 ) |
191 |
- sys-devel/gettext |
192 |
- virtual/pkgconfig |
193 |
- |
194 |
- >=dev-lang/perl-5.10 |
195 |
- virtual/perl-Data-Dumper |
196 |
- virtual/perl-Carp |
197 |
- virtual/perl-JSON-PP |
198 |
- |
199 |
- gtk-doc? ( >=dev-util/gtk-doc-1.10 ) |
200 |
- geolocation? ( dev-util/gdbus-codegen ) |
201 |
-" |
202 |
-# test? ( |
203 |
-# dev-python/pygobject:3[python_targets_python2_7] |
204 |
-# x11-themes/hicolor-icon-theme |
205 |
-# jit? ( sys-apps/paxctl ) ) |
206 |
-RDEPEND="${RDEPEND} |
207 |
- geolocation? ( >=app-misc/geoclue-2.1.5:2.0 ) |
208 |
-" |
209 |
- |
210 |
-S="${WORKDIR}/${MY_P}" |
211 |
- |
212 |
-CHECKREQS_DISK_BUILD="18G" # and even this might not be enough, bug #417307 |
213 |
- |
214 |
-pkg_pretend() { |
215 |
- if [[ ${MERGE_TYPE} != "binary" ]] ; then |
216 |
- if is-flagq "-g*" && ! is-flagq "-g*0" ; then |
217 |
- einfo "Checking for sufficient disk space to build ${PN} with debugging CFLAGS" |
218 |
- check-reqs_pkg_pretend |
219 |
- fi |
220 |
- |
221 |
- if ! test-flag-CXX -std=c++17 ; then |
222 |
- die "You need at least GCC 7.3.x or Clang >= 5 for C++17-specific compiler flags" |
223 |
- fi |
224 |
- fi |
225 |
- |
226 |
- if ! use opengl && ! use gles2-only; then |
227 |
- ewarn |
228 |
- ewarn "You are disabling OpenGL usage (USE=opengl or USE=gles-only) completely." |
229 |
- ewarn "This is an unsupported configuration meant for very specific embedded" |
230 |
- ewarn "use cases, where there truly is no GL possible (and even that use case" |
231 |
- ewarn "is very unlikely to come by). If you have GL (even software-only), you" |
232 |
- ewarn "really really should be enabling OpenGL!" |
233 |
- ewarn |
234 |
- fi |
235 |
-} |
236 |
- |
237 |
-pkg_setup() { |
238 |
- if [[ ${MERGE_TYPE} != "binary" ]] && is-flagq "-g*" && ! is-flagq "-g*0" ; then |
239 |
- check-reqs_pkg_setup |
240 |
- fi |
241 |
- |
242 |
- python-any-r1_pkg_setup |
243 |
-} |
244 |
- |
245 |
-src_prepare() { |
246 |
- eapply "${FILESDIR}/${PN}-2.24.4-eglmesaext-include.patch" # bug 699054 # https://bugs.webkit.org/show_bug.cgi?id=204108 |
247 |
- eapply "${FILESDIR}"/2.26.2-fix-arm-non-unified-build.patch # bug 704194 |
248 |
- eapply "${FILESDIR}"/${PV}-fix-gtk-doc.patch # bug 704550 - retest without it once we can depend on >=gtk-doc-1.32 |
249 |
- eapply "${FILESDIR}"/${PV}-fix-noGL-wayland-build.patch |
250 |
- cmake-utils_src_prepare |
251 |
- gnome2_src_prepare |
252 |
-} |
253 |
- |
254 |
-src_configure() { |
255 |
- # Respect CC, otherwise fails on prefix #395875 |
256 |
- tc-export CC |
257 |
- |
258 |
- # It does not compile on alpha without this in LDFLAGS |
259 |
- # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=648761 |
260 |
- use alpha && append-ldflags "-Wl,--no-relax" |
261 |
- |
262 |
- # ld segfaults on ia64 with LDFLAGS --as-needed, bug #555504 |
263 |
- use ia64 && append-ldflags "-Wl,--no-as-needed" |
264 |
- |
265 |
- # Sigbuses on SPARC with mcpu and co., bug #??? |
266 |
- use sparc && filter-flags "-mvis" |
267 |
- |
268 |
- # https://bugs.webkit.org/show_bug.cgi?id=42070 , #301634 |
269 |
- use ppc64 && append-flags "-mminimal-toc" |
270 |
- |
271 |
- # Try to use less memory, bug #469942 (see Fedora .spec for reference) |
272 |
- # --no-keep-memory doesn't work on ia64, bug #502492 |
273 |
- if ! use ia64; then |
274 |
- append-ldflags "-Wl,--no-keep-memory" |
275 |
- fi |
276 |
- |
277 |
- # We try to use gold when possible for this package |
278 |
-# if ! tc-ld-is-gold ; then |
279 |
-# append-ldflags "-Wl,--reduce-memory-overheads" |
280 |
-# fi |
281 |
- |
282 |
- # Ruby situation is a bit complicated. See bug 513888 |
283 |
- local rubyimpl |
284 |
- local ruby_interpreter="" |
285 |
- for rubyimpl in ${USE_RUBY}; do |
286 |
- if has_version --host-root "virtual/rubygems[ruby_targets_${rubyimpl}]"; then |
287 |
- ruby_interpreter="-DRUBY_EXECUTABLE=$(type -P ${rubyimpl})" |
288 |
- fi |
289 |
- done |
290 |
- # This will rarely occur. Only a couple of corner cases could lead us to |
291 |
- # that failure. See bug 513888 |
292 |
- [[ -z $ruby_interpreter ]] && die "No suitable ruby interpreter found" |
293 |
- |
294 |
- # TODO: Check Web Audio support |
295 |
- # should somehow let user select between them? |
296 |
- # |
297 |
- # opengl needs to be explicetly handled, bug #576634 |
298 |
- |
299 |
- local use_wpe_renderer=OFF |
300 |
- local opengl_enabled |
301 |
- if use opengl || use gles2-only; then |
302 |
- opengl_enabled=ON |
303 |
- use wayland && use_wpe_renderer=ON |
304 |
- else |
305 |
- opengl_enabled=OFF |
306 |
- fi |
307 |
- |
308 |
- local mycmakeargs=( |
309 |
- -DENABLE_UNIFIED_BUILDS=$(usex jumbo-build) |
310 |
- -DENABLE_QUARTZ_TARGET=$(usex aqua) |
311 |
- -DENABLE_API_TESTS=$(usex test) |
312 |
- -DENABLE_GTKDOC=$(usex gtk-doc) |
313 |
- -DENABLE_GEOLOCATION=$(usex geolocation) # Runtime optional (talks over dbus service) |
314 |
- $(cmake-utils_use_find_package gles2-only OpenGLES2) |
315 |
- -DENABLE_GLES2=$(usex gles2-only) |
316 |
- -DENABLE_VIDEO=$(usex gstreamer) |
317 |
- -DENABLE_WEB_AUDIO=$(usex gstreamer) |
318 |
- -DENABLE_INTROSPECTION=$(usex introspection) |
319 |
- -DUSE_LIBNOTIFY=$(usex libnotify) |
320 |
- -DUSE_LIBSECRET=$(usex gnome-keyring) |
321 |
- -DUSE_OPENJPEG=$(usex jpeg2k) |
322 |
- -DUSE_WOFF2=ON |
323 |
- -DENABLE_SPELLCHECK=$(usex spell) |
324 |
- -DENABLE_WAYLAND_TARGET=$(usex wayland) |
325 |
- -DUSE_WPE_RENDERER=${use_wpe_renderer} # WPE renderer is used to implement accelerated compositing under wayland |
326 |
- $(cmake-utils_use_find_package egl EGL) |
327 |
- $(cmake-utils_use_find_package opengl OpenGL) |
328 |
- -DENABLE_X11_TARGET=$(usex X) |
329 |
- -DENABLE_OPENGL=${opengl_enabled} |
330 |
- -DENABLE_WEBGL=${opengl_enabled} |
331 |
- -DENABLE_BUBBLEWRAP_SANDBOX=$(usex seccomp) |
332 |
- -DBWRAP_EXECUTABLE="${EPREFIX}"/usr/bin/bwrap # If bubblewrap[suid] then portage makes it go-r and cmake find_program fails with that |
333 |
- -DCMAKE_BUILD_TYPE=Release |
334 |
- -DPORT=GTK |
335 |
- ${ruby_interpreter} |
336 |
- ) |
337 |
- |
338 |
- # Allow it to use GOLD when possible as it has all the magic to |
339 |
- # detect when to use it and using gold for this concrete package has |
340 |
- # multiple advantages and is also the upstream default, bug #585788 |
341 |
-# if tc-ld-is-gold ; then |
342 |
-# mycmakeargs+=( -DUSE_LD_GOLD=ON ) |
343 |
-# else |
344 |
-# mycmakeargs+=( -DUSE_LD_GOLD=OFF ) |
345 |
-# fi |
346 |
- |
347 |
- cmake-utils_src_configure |
348 |
-} |
349 |
- |
350 |
-src_compile() { |
351 |
- cmake-utils_src_compile |
352 |
-} |
353 |
- |
354 |
-src_test() { |
355 |
- # Prevents test failures on PaX systems |
356 |
- pax-mark m $(list-paxables Programs/*[Tt]ests/*) # Programs/unittests/.libs/test* |
357 |
- |
358 |
- cmake-utils_src_test |
359 |
-} |
360 |
- |
361 |
-src_install() { |
362 |
- cmake-utils_src_install |
363 |
- |
364 |
- # Prevents crashes on PaX systems, bug #522808 |
365 |
- pax-mark m "${ED}usr/libexec/webkit2gtk-4.0/jsc" "${ED}usr/libexec/webkit2gtk-4.0/WebKitWebProcess" |
366 |
- pax-mark m "${ED}usr/libexec/webkit2gtk-4.0/WebKitPluginProcess" |
367 |
-} |
368 |
|
369 |
diff --git a/net-libs/webkit-gtk/webkit-gtk-2.26.3.ebuild b/net-libs/webkit-gtk/webkit-gtk-2.26.3.ebuild |
370 |
deleted file mode 100644 |
371 |
index 799da223a86..00000000000 |
372 |
--- a/net-libs/webkit-gtk/webkit-gtk-2.26.3.ebuild |
373 |
+++ /dev/null |
374 |
@@ -1,287 +0,0 @@ |
375 |
-# Copyright 1999-2020 Gentoo Authors |
376 |
-# Distributed under the terms of the GNU General Public License v2 |
377 |
- |
378 |
-EAPI=6 |
379 |
-CMAKE_MAKEFILE_GENERATOR="ninja" |
380 |
-PYTHON_COMPAT=( python{3_6,3_7} ) |
381 |
-USE_RUBY="ruby24 ruby25 ruby26 ruby27" |
382 |
-CMAKE_MIN_VERSION=3.10 |
383 |
- |
384 |
-inherit check-reqs cmake-utils flag-o-matic gnome2 pax-utils python-any-r1 ruby-single toolchain-funcs virtualx |
385 |
- |
386 |
-MY_P="webkitgtk-${PV}" |
387 |
-DESCRIPTION="Open source web browser engine" |
388 |
-HOMEPAGE="https://www.webkitgtk.org" |
389 |
-SRC_URI="https://www.webkitgtk.org/releases/${MY_P}.tar.xz" |
390 |
- |
391 |
-LICENSE="LGPL-2+ BSD" |
392 |
-SLOT="4/37" # soname version of libwebkit2gtk-4.0 |
393 |
-KEYWORDS="amd64 ~ia64 ~ppc64 ~sparc x86" |
394 |
- |
395 |
-IUSE="aqua coverage +egl +geolocation gles2-only gnome-keyring +gstreamer gtk-doc +introspection +jpeg2k +jumbo-build libnotify +opengl seccomp spell wayland +X" |
396 |
- |
397 |
-# gstreamer with opengl/gles2 needs egl |
398 |
-REQUIRED_USE=" |
399 |
- gles2-only? ( egl !opengl ) |
400 |
- gstreamer? ( opengl? ( egl ) ) |
401 |
- wayland? ( egl ) |
402 |
- || ( aqua wayland X ) |
403 |
-" |
404 |
- |
405 |
-# Tests fail to link for inexplicable reasons |
406 |
-# https://bugs.webkit.org/show_bug.cgi?id=148210 |
407 |
-RESTRICT="test" |
408 |
- |
409 |
-# Aqua support in gtk3 is untested |
410 |
-# Dependencies found at Source/cmake/OptionsGTK.cmake |
411 |
-# Various compile-time optionals for gtk+-3.22.0 - ensure it |
412 |
-# Missing WebRTC support, but ENABLE_MEDIA_STREAM/ENABLE_WEB_RTC is experimental upstream (PRIVATE OFF) and shouldn't be used yet in 2.26 |
413 |
-# >=gst-plugins-opus-1.14.4-r1 for opusparse (required by MSE) |
414 |
-wpe_depend=" |
415 |
- >=gui-libs/libwpe-1.3.0:1.0 |
416 |
- >=gui-libs/wpebackend-fdo-1.3.1:1.0 |
417 |
-" |
418 |
-RDEPEND=" |
419 |
- >=x11-libs/cairo-1.16.0:=[X?] |
420 |
- >=media-libs/fontconfig-2.13.0:1.0 |
421 |
- >=media-libs/freetype-2.9.0:2 |
422 |
- >=dev-libs/libgcrypt-1.7.0:0= |
423 |
- >=x11-libs/gtk+-3.22.0:3[aqua?,introspection?,wayland?,X?] |
424 |
- >=media-libs/harfbuzz-1.4.2:=[icu(+)] |
425 |
- >=dev-libs/icu-3.8.1-r1:= |
426 |
- virtual/jpeg:0= |
427 |
- >=net-libs/libsoup-2.54:2.4[introspection?] |
428 |
- >=dev-libs/libxml2-2.8.0:2 |
429 |
- >=media-libs/libpng-1.4:0= |
430 |
- dev-db/sqlite:3= |
431 |
- sys-libs/zlib:0 |
432 |
- >=dev-libs/atk-2.16.0 |
433 |
- media-libs/libwebp:= |
434 |
- |
435 |
- >=dev-libs/glib-2.44.0:2 |
436 |
- >=dev-libs/libxslt-1.1.7 |
437 |
- media-libs/woff2 |
438 |
- gnome-keyring? ( app-crypt/libsecret ) |
439 |
- introspection? ( >=dev-libs/gobject-introspection-1.32.0:= ) |
440 |
- dev-libs/libtasn1:= |
441 |
- spell? ( >=app-text/enchant-0.22:= ) |
442 |
- gstreamer? ( |
443 |
- >=media-libs/gstreamer-1.14:1.0 |
444 |
- >=media-libs/gst-plugins-base-1.14:1.0[egl?,opengl?] |
445 |
- gles2-only? ( media-libs/gst-plugins-base:1.0[gles2] ) |
446 |
- >=media-plugins/gst-plugins-opus-1.14.4-r1:1.0 |
447 |
- >=media-libs/gst-plugins-bad-1.14:1.0 ) |
448 |
- |
449 |
- X? ( |
450 |
- x11-libs/libX11 |
451 |
- x11-libs/libXcomposite |
452 |
- x11-libs/libXdamage |
453 |
- x11-libs/libXrender |
454 |
- x11-libs/libXt ) |
455 |
- |
456 |
- libnotify? ( x11-libs/libnotify ) |
457 |
- dev-libs/hyphen |
458 |
- jpeg2k? ( >=media-libs/openjpeg-2.2.0:2= ) |
459 |
- |
460 |
- egl? ( media-libs/mesa[egl] ) |
461 |
- gles2-only? ( media-libs/mesa[gles2] ) |
462 |
- opengl? ( virtual/opengl ) |
463 |
- wayland? ( |
464 |
- opengl? ( ${wpe_depend} ) |
465 |
- gles2-only? ( ${wpe_depend} ) |
466 |
- ) |
467 |
- |
468 |
- seccomp? ( |
469 |
- >=sys-apps/bubblewrap-0.3.1 |
470 |
- sys-libs/libseccomp |
471 |
- sys-apps/xdg-dbus-proxy |
472 |
- ) |
473 |
-" |
474 |
-unset wpe_depend |
475 |
-# paxctl needed for bug #407085 |
476 |
-# Need real bison, not yacc |
477 |
-DEPEND="${RDEPEND} |
478 |
- ${PYTHON_DEPS} |
479 |
- ${RUBY_DEPS} |
480 |
- >=app-accessibility/at-spi2-core-2.5.3 |
481 |
- dev-util/glib-utils |
482 |
- >=dev-util/gperf-3.0.1 |
483 |
- >=sys-devel/bison-2.4.3 |
484 |
- || ( >=sys-devel/gcc-7.3 >=sys-devel/clang-5 ) |
485 |
- sys-devel/gettext |
486 |
- virtual/pkgconfig |
487 |
- |
488 |
- >=dev-lang/perl-5.10 |
489 |
- virtual/perl-Data-Dumper |
490 |
- virtual/perl-Carp |
491 |
- virtual/perl-JSON-PP |
492 |
- |
493 |
- gtk-doc? ( >=dev-util/gtk-doc-1.10 ) |
494 |
- geolocation? ( dev-util/gdbus-codegen ) |
495 |
-" |
496 |
-# test? ( |
497 |
-# dev-python/pygobject:3[python_targets_python2_7] |
498 |
-# x11-themes/hicolor-icon-theme |
499 |
-# jit? ( sys-apps/paxctl ) ) |
500 |
-RDEPEND="${RDEPEND} |
501 |
- geolocation? ( >=app-misc/geoclue-2.1.5:2.0 ) |
502 |
-" |
503 |
- |
504 |
-S="${WORKDIR}/${MY_P}" |
505 |
- |
506 |
-CHECKREQS_DISK_BUILD="18G" # and even this might not be enough, bug #417307 |
507 |
- |
508 |
-pkg_pretend() { |
509 |
- if [[ ${MERGE_TYPE} != "binary" ]] ; then |
510 |
- if is-flagq "-g*" && ! is-flagq "-g*0" ; then |
511 |
- einfo "Checking for sufficient disk space to build ${PN} with debugging CFLAGS" |
512 |
- check-reqs_pkg_pretend |
513 |
- fi |
514 |
- |
515 |
- if ! test-flag-CXX -std=c++17 ; then |
516 |
- die "You need at least GCC 7.3.x or Clang >= 5 for C++17-specific compiler flags" |
517 |
- fi |
518 |
- fi |
519 |
- |
520 |
- if ! use opengl && ! use gles2-only; then |
521 |
- ewarn |
522 |
- ewarn "You are disabling OpenGL usage (USE=opengl or USE=gles-only) completely." |
523 |
- ewarn "This is an unsupported configuration meant for very specific embedded" |
524 |
- ewarn "use cases, where there truly is no GL possible (and even that use case" |
525 |
- ewarn "is very unlikely to come by). If you have GL (even software-only), you" |
526 |
- ewarn "really really should be enabling OpenGL!" |
527 |
- ewarn |
528 |
- fi |
529 |
-} |
530 |
- |
531 |
-pkg_setup() { |
532 |
- if [[ ${MERGE_TYPE} != "binary" ]] && is-flagq "-g*" && ! is-flagq "-g*0" ; then |
533 |
- check-reqs_pkg_setup |
534 |
- fi |
535 |
- |
536 |
- python-any-r1_pkg_setup |
537 |
-} |
538 |
- |
539 |
-src_prepare() { |
540 |
- eapply "${FILESDIR}/${PN}-2.24.4-eglmesaext-include.patch" # bug 699054 # https://bugs.webkit.org/show_bug.cgi?id=204108 |
541 |
- eapply "${FILESDIR}"/2.26.2-fix-arm-non-unified-build.patch # bug 704194 |
542 |
- eapply "${FILESDIR}"/${PV}-fix-gtk-doc.patch # bug 704550 - retest without it once we can depend on >=gtk-doc-1.32 |
543 |
- eapply "${FILESDIR}"/${PV}-fix-noGL-wayland-build.patch |
544 |
- cmake-utils_src_prepare |
545 |
- gnome2_src_prepare |
546 |
-} |
547 |
- |
548 |
-src_configure() { |
549 |
- # Respect CC, otherwise fails on prefix #395875 |
550 |
- tc-export CC |
551 |
- |
552 |
- # It does not compile on alpha without this in LDFLAGS |
553 |
- # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=648761 |
554 |
- use alpha && append-ldflags "-Wl,--no-relax" |
555 |
- |
556 |
- # ld segfaults on ia64 with LDFLAGS --as-needed, bug #555504 |
557 |
- use ia64 && append-ldflags "-Wl,--no-as-needed" |
558 |
- |
559 |
- # Sigbuses on SPARC with mcpu and co., bug #??? |
560 |
- use sparc && filter-flags "-mvis" |
561 |
- |
562 |
- # https://bugs.webkit.org/show_bug.cgi?id=42070 , #301634 |
563 |
- use ppc64 && append-flags "-mminimal-toc" |
564 |
- |
565 |
- # Try to use less memory, bug #469942 (see Fedora .spec for reference) |
566 |
- # --no-keep-memory doesn't work on ia64, bug #502492 |
567 |
- if ! use ia64; then |
568 |
- append-ldflags "-Wl,--no-keep-memory" |
569 |
- fi |
570 |
- |
571 |
- # We try to use gold when possible for this package |
572 |
-# if ! tc-ld-is-gold ; then |
573 |
-# append-ldflags "-Wl,--reduce-memory-overheads" |
574 |
-# fi |
575 |
- |
576 |
- # Ruby situation is a bit complicated. See bug 513888 |
577 |
- local rubyimpl |
578 |
- local ruby_interpreter="" |
579 |
- for rubyimpl in ${USE_RUBY}; do |
580 |
- if has_version --host-root "virtual/rubygems[ruby_targets_${rubyimpl}]"; then |
581 |
- ruby_interpreter="-DRUBY_EXECUTABLE=$(type -P ${rubyimpl})" |
582 |
- fi |
583 |
- done |
584 |
- # This will rarely occur. Only a couple of corner cases could lead us to |
585 |
- # that failure. See bug 513888 |
586 |
- [[ -z $ruby_interpreter ]] && die "No suitable ruby interpreter found" |
587 |
- |
588 |
- # TODO: Check Web Audio support |
589 |
- # should somehow let user select between them? |
590 |
- # |
591 |
- # opengl needs to be explicetly handled, bug #576634 |
592 |
- |
593 |
- local use_wpe_renderer=OFF |
594 |
- local opengl_enabled |
595 |
- if use opengl || use gles2-only; then |
596 |
- opengl_enabled=ON |
597 |
- use wayland && use_wpe_renderer=ON |
598 |
- else |
599 |
- opengl_enabled=OFF |
600 |
- fi |
601 |
- |
602 |
- local mycmakeargs=( |
603 |
- -DENABLE_UNIFIED_BUILDS=$(usex jumbo-build) |
604 |
- -DENABLE_QUARTZ_TARGET=$(usex aqua) |
605 |
- -DENABLE_API_TESTS=$(usex test) |
606 |
- -DENABLE_GTKDOC=$(usex gtk-doc) |
607 |
- -DENABLE_GEOLOCATION=$(usex geolocation) # Runtime optional (talks over dbus service) |
608 |
- $(cmake-utils_use_find_package gles2-only OpenGLES2) |
609 |
- -DENABLE_GLES2=$(usex gles2-only) |
610 |
- -DENABLE_VIDEO=$(usex gstreamer) |
611 |
- -DENABLE_WEB_AUDIO=$(usex gstreamer) |
612 |
- -DENABLE_INTROSPECTION=$(usex introspection) |
613 |
- -DUSE_LIBNOTIFY=$(usex libnotify) |
614 |
- -DUSE_LIBSECRET=$(usex gnome-keyring) |
615 |
- -DUSE_OPENJPEG=$(usex jpeg2k) |
616 |
- -DUSE_WOFF2=ON |
617 |
- -DENABLE_SPELLCHECK=$(usex spell) |
618 |
- -DENABLE_WAYLAND_TARGET=$(usex wayland) |
619 |
- -DUSE_WPE_RENDERER=${use_wpe_renderer} # WPE renderer is used to implement accelerated compositing under wayland |
620 |
- $(cmake-utils_use_find_package egl EGL) |
621 |
- $(cmake-utils_use_find_package opengl OpenGL) |
622 |
- -DENABLE_X11_TARGET=$(usex X) |
623 |
- -DENABLE_OPENGL=${opengl_enabled} |
624 |
- -DENABLE_WEBGL=${opengl_enabled} |
625 |
- -DENABLE_BUBBLEWRAP_SANDBOX=$(usex seccomp) |
626 |
- -DBWRAP_EXECUTABLE="${EPREFIX}"/usr/bin/bwrap # If bubblewrap[suid] then portage makes it go-r and cmake find_program fails with that |
627 |
- -DCMAKE_BUILD_TYPE=Release |
628 |
- -DPORT=GTK |
629 |
- ${ruby_interpreter} |
630 |
- ) |
631 |
- |
632 |
- # Allow it to use GOLD when possible as it has all the magic to |
633 |
- # detect when to use it and using gold for this concrete package has |
634 |
- # multiple advantages and is also the upstream default, bug #585788 |
635 |
-# if tc-ld-is-gold ; then |
636 |
-# mycmakeargs+=( -DUSE_LD_GOLD=ON ) |
637 |
-# else |
638 |
-# mycmakeargs+=( -DUSE_LD_GOLD=OFF ) |
639 |
-# fi |
640 |
- |
641 |
- cmake-utils_src_configure |
642 |
-} |
643 |
- |
644 |
-src_compile() { |
645 |
- cmake-utils_src_compile |
646 |
-} |
647 |
- |
648 |
-src_test() { |
649 |
- # Prevents test failures on PaX systems |
650 |
- pax-mark m $(list-paxables Programs/*[Tt]ests/*) # Programs/unittests/.libs/test* |
651 |
- |
652 |
- cmake-utils_src_test |
653 |
-} |
654 |
- |
655 |
-src_install() { |
656 |
- cmake-utils_src_install |
657 |
- |
658 |
- # Prevents crashes on PaX systems, bug #522808 |
659 |
- pax-mark m "${ED}usr/libexec/webkit2gtk-4.0/jsc" "${ED}usr/libexec/webkit2gtk-4.0/WebKitWebProcess" |
660 |
- pax-mark m "${ED}usr/libexec/webkit2gtk-4.0/WebKitPluginProcess" |
661 |
-} |