diff options
Diffstat (limited to 'pkgs/development/libraries/qt-5/5.6/qtwebkit/default.nix')
-rw-r--r-- | pkgs/development/libraries/qt-5/5.6/qtwebkit/default.nix | 41 |
1 files changed, 21 insertions, 20 deletions
diff --git a/pkgs/development/libraries/qt-5/5.6/qtwebkit/default.nix b/pkgs/development/libraries/qt-5/5.6/qtwebkit/default.nix index 23a45dd44ed2..664281aac311 100644 --- a/pkgs/development/libraries/qt-5/5.6/qtwebkit/default.nix +++ b/pkgs/development/libraries/qt-5/5.6/qtwebkit/default.nix @@ -1,39 +1,40 @@ -{ qtSubmodule, stdenv, qtdeclarative, qtlocation, qtsensors +{ qtSubmodule, stdenv, copyPathsToStore, lib +, qtdeclarative, qtlocation, qtsensors , fontconfig, gdk_pixbuf, gtk2, libwebp, libxml2, libxslt , sqlite, systemd, glib, gst_all_1 , bison2, flex, gdb, gperf, perl, pkgconfig, python2, ruby +, darwin , substituteAll , flashplayerFix ? false }: -with stdenv.lib; +let inherit (lib) optional optionals getLib; in qtSubmodule { name = "qtwebkit"; qtInputs = [ qtdeclarative qtlocation qtsensors ]; - buildInputs = [ fontconfig libwebp libxml2 libxslt sqlite glib gst_all_1.gstreamer gst_all_1.gst-plugins-base ]; + buildInputs = [ fontconfig libwebp libxml2 libxslt sqlite glib gst_all_1.gstreamer gst_all_1.gst-plugins-base ] + ++ optionals (stdenv.isDarwin) (with darwin.apple_sdk.frameworks; [ OpenGL ]); nativeBuildInputs = [ bison2 flex gdb gperf perl pkgconfig python2 ruby ]; - patches = - let dlopen-webkit-nsplugin = substituteAll { - src = ./0001-dlopen-webkit-nsplugin.patch; - gtk = gtk2.out; - gdk_pixbuf = gdk_pixbuf.out; - }; - dlopen-webkit-gtk = substituteAll { - src = ./0002-dlopen-webkit-gtk.patch; - gtk = gtk2.out; - }; - dlopen-webkit-udev = substituteAll { - src = ./0003-dlopen-webkit-udev.patch; - libudev = systemd.lib; - }; - in optionals flashplayerFix [ dlopen-webkit-nsplugin dlopen-webkit-gtk ] - ++ [ dlopen-webkit-udev ]; + + __impureHostDeps = optionals (stdenv.isDarwin) [ + "/usr/lib/libicucore.dylib" + ]; + + patches = copyPathsToStore (lib.readPathsFromFile ./. ./series); + + NIX_CFLAGS_COMPILE = + optionals flashplayerFix + [ + ''-DNIXPKGS_LIBGTK2="${getLib gtk2}/lib/libgtk-x11-2.0"'' + ''-DNIXPKGS_LIBGDK2="${getLib gdk_pixbuf}/lib/libgdk-x11-2.0"'' + ] + ++ optional (!stdenv.isDarwin) ''-DNIXPKGS_LIBUDEV="${getLib systemd}/lib/libudev"''; # Hack to avoid TMPDIR in RPATHs. preFixup = ''rm -rf "$(pwd)" && mkdir "$(pwd)" ''; - meta.maintainers = with stdenv.lib.maintainers; [ abbradar ]; + meta.maintainers = with stdenv.lib.maintainers; [ abbradar periklis ]; } |