about summary refs log tree commit diff
path: root/pkgs/development/python-modules/pyqtwebengine/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/python-modules/pyqtwebengine/default.nix')
-rw-r--r--pkgs/development/python-modules/pyqtwebengine/default.nix69
1 files changed, 32 insertions, 37 deletions
diff --git a/pkgs/development/python-modules/pyqtwebengine/default.nix b/pkgs/development/python-modules/pyqtwebengine/default.nix
index b72fde6277f7b..11d0f847d8328 100644
--- a/pkgs/development/python-modules/pyqtwebengine/default.nix
+++ b/pkgs/development/python-modules/pyqtwebengine/default.nix
@@ -1,35 +1,27 @@
 {
   lib,
+  setuptools,
   stdenv,
-  pythonPackages,
   fetchPypi,
   pkg-config,
-  qmake,
-  qtbase,
-  qtsvg,
-  qtwebengine,
-  qtwebchannel,
-  qtdeclarative,
-  wrapQtAppsHook,
+  libsForQt5,
   darwin,
-  buildPackages,
+  buildPythonPackage,
+  python,
+  isPy27,
+  pyqt5,
+  sip,
+  pyqt-builder,
+  mesa,
 }:
 
 let
-  inherit (pythonPackages)
-    buildPythonPackage
-    python
-    isPy27
-    pyqt5
-    sip
-    pyqt-builder
-    ;
   inherit (darwin) autoSignDarwinBinariesHook;
 in
 buildPythonPackage (
   rec {
     pname = "pyqtwebengine";
-    version = "5.15.6";
+    version = "5.15.7";
     format = "pyproject";
 
     disabled = isPy27;
@@ -37,7 +29,7 @@ buildPythonPackage (
     src = fetchPypi {
       pname = "PyQtWebEngine";
       inherit version;
-      sha256 = "sha256-riQe8qYceCk5xYtSwq6lOtmbMPOTTINY1eCm67P9ByE=";
+      hash = "sha256-8SGsbkovlqwolhm8/Df2Tmg2LySjRlU/XWxC76Qiik0=";
     };
 
     postPatch = ''
@@ -53,32 +45,35 @@ buildPythonPackage (
     nativeBuildInputs =
       [
         pkg-config
-        qmake
+        libsForQt5.qmake
+        libsForQt5.wrapQtAppsHook
       ]
       ++ lib.optionals (stdenv.buildPlatform == stdenv.hostPlatform) [ sip ]
       ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [
         python.pythonOnBuildForHost.pkgs.sip
       ]
       ++ [
-        qtbase
-        qtsvg
-        qtwebengine
+        libsForQt5.qtbase
+        libsForQt5.qtsvg
+        libsForQt5.qtwebengine
         pyqt-builder
-        pythonPackages.setuptools
+        setuptools
       ]
-      ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [ qtdeclarative ]
-      ++ lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [ autoSignDarwinBinariesHook ];
+      ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [ libsForQt5.qtdeclarative ]
+      ++ lib.optionals (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64) [
+        autoSignDarwinBinariesHook
+      ];
 
     buildInputs =
       [
         sip
-        qtbase
-        qtsvg
-        qtwebengine
+        libsForQt5.qtbase
+        libsForQt5.qtsvg
+        libsForQt5.qtwebengine
       ]
       ++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform) [
-        qtwebchannel
-        qtdeclarative
+        libsForQt5.qtwebchannel
+        libsForQt5.qtdeclarative
       ];
 
     propagatedBuildInputs = [ pyqt5 ];
@@ -99,21 +94,21 @@ buildPythonPackage (
     enableParallelBuilding = true;
 
     passthru = {
-      inherit wrapQtAppsHook;
+      inherit (libsForQt5) wrapQtAppsHook;
     };
 
-    meta = with lib; {
+    meta = {
       description = "Python bindings for Qt5";
       homepage = "http://www.riverbankcomputing.co.uk";
-      license = licenses.gpl3;
-      hydraPlatforms = lib.lists.intersectLists qtwebengine.meta.platforms platforms.mesaPlatforms;
+      license = lib.licenses.gpl3;
+      hydraPlatforms = lib.lists.intersectLists libsForQt5.qtwebengine.meta.platforms mesa.meta.platforms;
     };
   }
   // lib.optionalAttrs (stdenv.buildPlatform != stdenv.hostPlatform) {
     # TODO: figure out why the env hooks aren't adding these inclusions automatically
     env.NIX_CFLAGS_COMPILE = lib.concatStringsSep " " [
-      "-I${lib.getDev qtbase}/include/QtPrintSupport/"
-      "-I${lib.getDev qtwebchannel}/include/QtWebChannel/"
+      "-I${lib.getDev libsForQt5.qtbase}/include/QtPrintSupport/"
+      "-I${lib.getDev libsForQt5.qtwebchannel}/include/QtWebChannel/"
     ];
   }
 )