aboutsummaryrefslogtreecommitdiff
path: root/infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2
diff options
context:
space:
mode:
authorMx Kookie <kookie@spacekookie.de>2020-10-31 19:35:09 +0100
committerMx Kookie <kookie@spacekookie.de>2020-10-31 19:35:09 +0100
commitc4625b175f8200f643fd6e11010932ea44c78433 (patch)
treebce3f89888c8ac3991fa5569a878a9eab6801ccc /infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2
parent49f735974dd103039ddc4cb576bb76555164a9e7 (diff)
parentd661aa56a8843e991261510c1bb28fdc2f6975ae (diff)
Add 'infra/libkookie/' from commit 'd661aa56a8843e991261510c1bb28fdc2f6975ae'
git-subtree-dir: infra/libkookie git-subtree-mainline: 49f735974dd103039ddc4cb576bb76555164a9e7 git-subtree-split: d661aa56a8843e991261510c1bb28fdc2f6975ae
Diffstat (limited to 'infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2')
-rw-r--r--infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2/default.nix39
-rw-r--r--infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2/dont_ignore_optional_modules.patch11
2 files changed, 50 insertions, 0 deletions
diff --git a/infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2/default.nix b/infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2/default.nix
new file mode 100644
index 000000000000..ed0ab2d533aa
--- /dev/null
+++ b/infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2/default.nix
@@ -0,0 +1,39 @@
+{ buildPythonPackage, python, fetchurl, stdenv,
+ cmake, ninja, qt5, shiboken2 }:
+
+stdenv.mkDerivation rec {
+ pname = "pyside2";
+ version = "5.15.1";
+
+ src = fetchurl {
+ url = "https://download.qt.io/official_releases/QtForPython/pyside2/PySide2-${version}-src/pyside-setup-opensource-src-${version}.tar.xz";
+ sha256 = "1yn3f414ql8rrvwxlfpp2sckpmb89zj5iszgy1690mrjh7cc2xgi";
+ };
+
+ patches = [
+ ./dont_ignore_optional_modules.patch
+ ];
+
+ postPatch = ''
+ cd sources/pyside2
+ '';
+
+ cmakeFlags = [
+ "-DBUILD_TESTS=OFF"
+ "-DPYTHON_EXECUTABLE=${python.interpreter}"
+ ];
+
+ nativeBuildInputs = [ cmake ninja qt5.qmake python ];
+ buildInputs = with qt5; [
+ qtbase qtxmlpatterns qtmultimedia qttools qtx11extras qtlocation qtscript
+ qtwebsockets qtwebengine qtwebchannel qtcharts qtsensors qtsvg
+ ];
+ propagatedBuildInputs = [ shiboken2 ];
+
+ meta = with stdenv.lib; {
+ description = "LGPL-licensed Python bindings for Qt";
+ license = licenses.lgpl21;
+ homepage = "https://wiki.qt.io/Qt_for_Python";
+ maintainers = with maintainers; [ gebner ];
+ };
+}
diff --git a/infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2/dont_ignore_optional_modules.patch b/infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2/dont_ignore_optional_modules.patch
new file mode 100644
index 000000000000..c9f17bea71b4
--- /dev/null
+++ b/infra/libkookie/nixpkgs/pkgs/development/python-modules/pyside2/dont_ignore_optional_modules.patch
@@ -0,0 +1,11 @@
+--- pyside-setup-opensource-src-5.14.2/sources/cmake_helpers/helpers.cmake~ 2020-07-17 10:29:30.555285529 +0200
++++ pyside-setup-opensource-src-5.14.2/sources/cmake_helpers/helpers.cmake 2020-07-17 10:29:49.817003683 +0200
+@@ -139,7 +139,7 @@
+ # If the module was found, and also the module path is the same as the
+ # Qt5Core base path, we will generate the list with the modules to be installed
+ set(looked_in_message ". Looked in: ${${_name_dir}}")
+- if("${${_name_found}}" AND (("${found_basepath}" GREATER "0") OR ("${found_basepath}" EQUAL "0")))
++ if("${${_name_found}}")
+ message(STATUS "${module_state} module ${name} found (${ARGN})${looked_in_message}")
+ # record the shortnames for the tests
+ list(APPEND all_module_shortnames ${shortname})