summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkos Chandras <hwoarang@gentoo.org>2010-08-12 22:16:41 +0000
committerMarkos Chandras <hwoarang@gentoo.org>2010-08-12 22:16:41 +0000
commit0a81b6076cda56e88399ab4217e56ea78811d965 (patch)
treea9d72bd78a99bd7134b831f0cf4f8ac90c6ce8ce /x11-libs
parentVersion bump, closes #331771. Bug fixes and new format support. (diff)
downloadgentoo-2-0a81b6076cda56e88399ab4217e56ea78811d965.tar.gz
gentoo-2-0a81b6076cda56e88399ab4217e56ea78811d965.tar.bz2
gentoo-2-0a81b6076cda56e88399ab4217e56ea78811d965.zip
Apply patch from Christoph Erhardt <ChristophErhardt@gmx.de> to fix qt-webkit based apps. Bug #332155
(Portage version: 2.2_rc67/cvs/Linux x86_64)
Diffstat (limited to 'x11-libs')
-rw-r--r--x11-libs/qt-webkit/ChangeLog12
-rw-r--r--x11-libs/qt-webkit/files/qt-webkit-4.6.3-flash-plugin-segfault.patch43
-rw-r--r--x11-libs/qt-webkit/qt-webkit-4.6.3-r1.ebuild49
3 files changed, 103 insertions, 1 deletions
diff --git a/x11-libs/qt-webkit/ChangeLog b/x11-libs/qt-webkit/ChangeLog
index 7e70b3714b6a..45678439433f 100644
--- a/x11-libs/qt-webkit/ChangeLog
+++ b/x11-libs/qt-webkit/ChangeLog
@@ -1,6 +1,16 @@
# ChangeLog for x11-libs/qt-webkit
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/x11-libs/qt-webkit/ChangeLog,v 1.95 2010/08/11 21:35:12 josejx Exp $
+# $Header: /var/cvsroot/gentoo-x86/x11-libs/qt-webkit/ChangeLog,v 1.96 2010/08/12 22:16:40 hwoarang Exp $
+
+*qt-webkit-4.6.3-r1 (12 Aug 2010)
+
+ 12 Aug 2010; Markos Chandras <hwoarang@gentoo.org>
+ +qt-webkit-4.6.3-r1.ebuild,
+ +files/qt-webkit-4.6.3-flash-plugin-segfault.patch:
+ Apply upstream patch to fix Qt-webkit based application crashes due to
+ glib. Upstream bug https://bugs.webkit.org/show_bug.cgi?id=40567. Fixes
+ bug #332155. Thanks to Christoph Erhardt <ChristophErhardt@gmx.de> for
+ backporting and attaching the patch
11 Aug 2010; Joseph Jezak <josejx@gentoo.org> qt-webkit-4.5.3-r3.ebuild,
qt-webkit-4.6.2-r1.ebuild:
diff --git a/x11-libs/qt-webkit/files/qt-webkit-4.6.3-flash-plugin-segfault.patch b/x11-libs/qt-webkit/files/qt-webkit-4.6.3-flash-plugin-segfault.patch
new file mode 100644
index 000000000000..6fc87ca314a7
--- /dev/null
+++ b/x11-libs/qt-webkit/files/qt-webkit-4.6.3-flash-plugin-segfault.patch
@@ -0,0 +1,43 @@
+This patch fixes WebKit Bug 40567: [Qt] QtWebKit crashes while initializing
+flash plugin 10.1.53.64...
+https://bugs.webkit.org/show_bug.cgi?id=40567
+
+--- src/3rdparty/webkit/WebCore/plugins/qt/PluginPackageQt.cpp
++++ src/3rdparty/webkit/WebCore/plugins/qt/PluginPackageQt.cpp
+@@ -35,4 +35,6 @@
+
+ namespace WebCore {
++
++typedef void gtkInitFunc(int *argc, char ***argv);
+
+ bool PluginPackage::fetchInfo()
+@@ -110,4 +112,5 @@
+ NP_InitializeFuncPtr NP_Initialize;
+ NPError npErr;
++ gtkInitFunc* gtkInit;
+
+ NP_Initialize = (NP_InitializeFuncPtr)m_module->resolve("NP_Initialize");
+@@ -126,4 +129,24 @@
+ // It does so in NP_Initialize with a null instance, therefore it is done this way:
+ m_browserFuncs.getvalue = staticPluginQuirkRequiresGtkToolKit_NPN_GetValue;
++ }
++
++ // WORKAROUND: Prevent gtk based plugin crashes such as BR# 40567 by
++ // explicitly forcing the initializing of Gtk, i.e. calling gtk_init,
++ // whenver the symbol is present in the plugin library loaded above.
++ // Note that this workaround is based on code from the NSPluginClass ctor
++ // in KDE's kdebase/apps/nsplugins/viewer/nsplugin.cpp file.
++ gtkInit = (gtkInitFunc*)m_module->resolve("gtk_init");
++ if (gtkInit) {
++ // Prevent gtk_init() from replacing the X error handlers, since the Gtk
++ // handlers abort when they receive an X error, thus killing the viewer.
++#ifdef Q_WS_X11
++ int (*old_error_handler)(Display*, XErrorEvent*) = XSetErrorHandler(0);
++ int (*old_io_error_handler)(Display*) = XSetIOErrorHandler(0);
++#endif
++ gtkInit(0, 0);
++#ifdef Q_WS_X11
++ XSetErrorHandler(old_error_handler);
++ XSetIOErrorHandler(old_io_error_handler);
++#endif
+ }
diff --git a/x11-libs/qt-webkit/qt-webkit-4.6.3-r1.ebuild b/x11-libs/qt-webkit/qt-webkit-4.6.3-r1.ebuild
new file mode 100644
index 000000000000..5090fbe25732
--- /dev/null
+++ b/x11-libs/qt-webkit/qt-webkit-4.6.3-r1.ebuild
@@ -0,0 +1,49 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/x11-libs/qt-webkit/qt-webkit-4.6.3-r1.ebuild,v 1.1 2010/08/12 22:16:40 hwoarang Exp $
+
+EAPI="2"
+inherit qt4-build
+
+DESCRIPTION="The Webkit module for the Qt toolkit"
+SLOT="4"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 -sparc ~x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x64-solaris ~x86-solaris"
+IUSE="dbus kde"
+
+DEPEND="~x11-libs/qt-core-${PV}[aqua=,debug=,ssl]
+ ~x11-libs/qt-gui-${PV}[aqua=,dbus?,debug=]
+ ~x11-libs/qt-xmlpatterns-${PV}[aqua=,debug=]
+ dbus? ( ~x11-libs/qt-dbus-${PV}[aqua=,debug=] )
+ !kde? ( || ( ~x11-libs/qt-phonon-${PV}:${SLOT}[aqua=,dbus=,debug=]
+ media-sound/phonon[aqua=] ) )
+ kde? ( || ( media-sound/phonon[aqua=] ~x11-libs/qt-phonon-${PV}:${SLOT}[aqua=,dbus=,debug] ) )"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-4.6.0-solaris-strnstr.patch
+ "${FILESDIR}"/${P}-flash-plugin-segfault.patch
+)
+
+pkg_setup() {
+ QT4_TARGET_DIRECTORIES="
+ src/3rdparty/webkit/WebCore
+ tools/designer/src/plugins/qwebview"
+ QT4_EXTRACT_DIRECTORIES="
+ include/
+ src/
+ tools/"
+ QCONFIG_ADD="webkit"
+ QCONFIG_DEFINE="QT_WEBKIT"
+
+ qt4-build_pkg_setup
+}
+
+src_prepare() {
+ [[ $(tc-arch) == "ppc64" ]] && append-flags -mminimal-toc #241900
+ qt4-build_src_prepare
+}
+
+src_configure() {
+ myconf="${myconf} -webkit $(qt_use dbus qdbus)"
+ qt4-build_src_configure
+}