diff options
Diffstat (limited to 'pkgs/development/libraries/qt-5/5.5/qtwebkit')
4 files changed, 142 insertions, 0 deletions
diff --git a/pkgs/development/libraries/qt-5/5.5/qtwebkit/0001-dlopen-webkit-nsplugin.patch b/pkgs/development/libraries/qt-5/5.5/qtwebkit/0001-dlopen-webkit-nsplugin.patch new file mode 100644 index 00000000000..0eeacce1bc0 --- /dev/null +++ b/pkgs/development/libraries/qt-5/5.5/qtwebkit/0001-dlopen-webkit-nsplugin.patch @@ -0,0 +1,53 @@ +From 862ce7d357a3ec32683ac6ec7c0ebdc9346b44ba Mon Sep 17 00:00:00 2001 +From: Thomas Tuegel <ttuegel@gmail.com> +Date: Sun, 23 Aug 2015 09:18:54 -0500 +Subject: [PATCH 1/3] dlopen webkit nsplugin + +--- + Source/WebCore/plugins/qt/PluginPackageQt.cpp | 2 +- + Source/WebCore/plugins/qt/PluginViewQt.cpp | 2 +- + Source/WebKit2/WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp | 2 +- + 3 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/Source/WebCore/plugins/qt/PluginPackageQt.cpp b/Source/WebCore/plugins/qt/PluginPackageQt.cpp +index a923d49..2731d05 100644 +--- a/Source/WebCore/plugins/qt/PluginPackageQt.cpp ++++ b/Source/WebCore/plugins/qt/PluginPackageQt.cpp +@@ -136,7 +136,7 @@ static void initializeGtk(QLibrary* module = 0) + } + } + +- QLibrary library(QLatin1String("libgtk-x11-2.0"), 0); ++ QLibrary library(QLatin1String("@gtk@/lib/libgtk-x11-2.0"), 0); + if (library.load()) { + typedef void *(*gtk_init_check_ptr)(int*, char***); + gtk_init_check_ptr gtkInitCheck = (gtk_init_check_ptr)library.resolve("gtk_init_check"); +diff --git a/Source/WebCore/plugins/qt/PluginViewQt.cpp b/Source/WebCore/plugins/qt/PluginViewQt.cpp +index de06a2f..363bde5 100644 +--- a/Source/WebCore/plugins/qt/PluginViewQt.cpp ++++ b/Source/WebCore/plugins/qt/PluginViewQt.cpp +@@ -697,7 +697,7 @@ static Display *getPluginDisplay() + // support gdk based plugins (like flash) that use a different X connection. + // The code below has the same effect as this one: + // Display *gdkDisplay = gdk_x11_display_get_xdisplay(gdk_display_get_default()); +- QLibrary library(QLatin1String("libgdk-x11-2.0"), 0); ++ QLibrary library(QLatin1String("@gdk_pixbuf@/lib/libgdk-x11-2.0"), 0); + if (!library.load()) + return 0; + +diff --git a/Source/WebKit2/WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp b/Source/WebKit2/WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp +index d734ff6..62a2197 100644 +--- a/Source/WebKit2/WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp ++++ b/Source/WebKit2/WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp +@@ -64,7 +64,7 @@ static Display* getPluginDisplay() + // The code below has the same effect as this one: + // Display *gdkDisplay = gdk_x11_display_get_xdisplay(gdk_display_get_default()); + +- QLibrary library(QLatin1String("libgdk-x11-2.0"), 0); ++ QLibrary library(QLatin1String("@gdk_pixbuf@/libgdk-x11-2.0"), 0); + if (!library.load()) + return 0; + +-- +2.5.0 + diff --git a/pkgs/development/libraries/qt-5/5.5/qtwebkit/0002-dlopen-webkit-gtk.patch b/pkgs/development/libraries/qt-5/5.5/qtwebkit/0002-dlopen-webkit-gtk.patch new file mode 100644 index 00000000000..bb5d1f74364 --- /dev/null +++ b/pkgs/development/libraries/qt-5/5.5/qtwebkit/0002-dlopen-webkit-gtk.patch @@ -0,0 +1,25 @@ +From 6a407d30357c2551abceac75c82f4a1688e47437 Mon Sep 17 00:00:00 2001 +From: Thomas Tuegel <ttuegel@gmail.com> +Date: Sun, 23 Aug 2015 09:19:16 -0500 +Subject: [PATCH 2/3] dlopen webkit gtk + +--- + Source/WebKit2/PluginProcess/qt/PluginProcessMainQt.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Source/WebKit2/PluginProcess/qt/PluginProcessMainQt.cpp b/Source/WebKit2/PluginProcess/qt/PluginProcessMainQt.cpp +index 8de6521..0b25748 100644 +--- a/Source/WebKit2/PluginProcess/qt/PluginProcessMainQt.cpp ++++ b/Source/WebKit2/PluginProcess/qt/PluginProcessMainQt.cpp +@@ -53,7 +53,7 @@ static void messageHandler(QtMsgType type, const QMessageLogContext&, const QStr + + static bool initializeGtk() + { +- QLibrary gtkLibrary(QLatin1String("libgtk-x11-2.0"), 0); ++ QLibrary gtkLibrary(QLatin1String("@gtk@/lib/libgtk-x11-2.0"), 0); + if (!gtkLibrary.load()) + return false; + typedef void* (*gtk_init_ptr)(void*, void*); +-- +2.5.0 + diff --git a/pkgs/development/libraries/qt-5/5.5/qtwebkit/0003-dlopen-webkit-udev.patch b/pkgs/development/libraries/qt-5/5.5/qtwebkit/0003-dlopen-webkit-udev.patch new file mode 100644 index 00000000000..f3b9d407bd7 --- /dev/null +++ b/pkgs/development/libraries/qt-5/5.5/qtwebkit/0003-dlopen-webkit-udev.patch @@ -0,0 +1,31 @@ +From 864020dd47c3b6d532d9f26b82185904cf9324f2 Mon Sep 17 00:00:00 2001 +From: Thomas Tuegel <ttuegel@gmail.com> +Date: Sun, 23 Aug 2015 09:19:29 -0500 +Subject: [PATCH 3/3] dlopen webkit udev + +--- + Source/WebCore/platform/qt/GamepadsQt.cpp | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/Source/WebCore/platform/qt/GamepadsQt.cpp b/Source/WebCore/platform/qt/GamepadsQt.cpp +index 60ff317..da8ac69 100644 +--- a/Source/WebCore/platform/qt/GamepadsQt.cpp ++++ b/Source/WebCore/platform/qt/GamepadsQt.cpp +@@ -111,12 +111,12 @@ private: + bool load() + { + m_libUdev.setLoadHints(QLibrary::ResolveAllSymbolsHint); +- m_libUdev.setFileNameAndVersion(QStringLiteral("udev"), 1); ++ m_libUdev.setFileNameAndVersion(QStringLiteral("@udev@/lib/libudev"), 1); + m_loaded = m_libUdev.load(); + if (resolveMethods()) + return true; + +- m_libUdev.setFileNameAndVersion(QStringLiteral("udev"), 0); ++ m_libUdev.setFileNameAndVersion(QStringLiteral("@udev@/lib/libudev"), 0); + m_loaded = m_libUdev.load(); + return resolveMethods(); + } +-- +2.5.0 + diff --git a/pkgs/development/libraries/qt-5/5.5/qtwebkit/default.nix b/pkgs/development/libraries/qt-5/5.5/qtwebkit/default.nix new file mode 100644 index 00000000000..596c02d39af --- /dev/null +++ b/pkgs/development/libraries/qt-5/5.5/qtwebkit/default.nix @@ -0,0 +1,33 @@ +{ qtSubmodule, stdenv, qtdeclarative, qtlocation, qtmultimedia, qtsensors +, fontconfig, gdk_pixbuf, gtk, libwebp, libxml2, libxslt +, sqlite, udev +, bison2, flex, gdb, gperf, perl, pkgconfig, python, ruby +, substituteAll +, flashplayerFix ? false +}: + +with stdenv.lib; + +qtSubmodule { + name = "qtwebkit"; + qtInputs = [ qtdeclarative qtlocation qtmultimedia qtsensors ]; + buildInputs = [ fontconfig libwebp libxml2 libxslt sqlite ]; + nativeBuildInputs = [ + bison2 flex gdb gperf perl pkgconfig python ruby + ]; + patches = + let dlopen-webkit-nsplugin = substituteAll { + src = ./0001-dlopen-webkit-nsplugin.patch; + inherit gtk gdk_pixbuf; + }; + dlopen-webkit-gtk = substituteAll { + src = ./0002-dlopen-webkit-gtk.patch; + inherit gtk; + }; + dlopen-webkit-udev = substituteAll { + src = ./0003-dlopen-webkit-udev.patch; + inherit udev; + }; + in optionals flashplayerFix [ dlopen-webkit-nsplugin dlopen-webkit-gtk ] + ++ [ dlopen-webkit-udev ]; +} |