diff options
author | Alyssa Ross <hi@alyssa.is> | 2024-05-03 15:14:25 +0200 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2024-05-07 11:19:19 +0200 |
commit | d92b2b6a1bbd322dd65a8b6f51019610d350046e (patch) | |
tree | 7f7c21927b9cc05676501f297c51eb76b49e326c /nixpkgs/pkgs/development/libraries/python-qt | |
parent | 93c9e56b40530cc627d921cfc255c05b495d4017 (diff) | |
parent | 49050352f602fe87d16ff7b2b6a05b79eb20dc6f (diff) | |
download | nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.gz nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.bz2 nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.lz nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.xz nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.tar.zst nixlib-d92b2b6a1bbd322dd65a8b6f51019610d350046e.zip |
Merge remote-tracking branch 'nixpkgs/nixos-unstable-small'
Conflicts: nixpkgs/nixos/modules/services/mail/mailman.nix nixpkgs/nixos/modules/services/mail/public-inbox.nix nixpkgs/pkgs/build-support/go/module.nix
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/python-qt')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/python-qt/default.nix | 56 |
1 files changed, 34 insertions, 22 deletions
diff --git a/nixpkgs/pkgs/development/libraries/python-qt/default.nix b/nixpkgs/pkgs/development/libraries/python-qt/default.nix index d238b8137d33..2b7ac684974e 100644 --- a/nixpkgs/pkgs/development/libraries/python-qt/default.nix +++ b/nixpkgs/pkgs/development/libraries/python-qt/default.nix @@ -1,39 +1,42 @@ -{ lib, stdenv, fetchFromGitHub, fetchpatch, python, qmake, - qtwebengine, qtxmlpatterns, - qttools, unzip }: +{ + lib, + stdenv, + fetchFromGitHub, + fetchpatch, + python3, + qmake, + qtwebengine, + qtxmlpatterns, + qttools, +}: -stdenv.mkDerivation rec { +stdenv.mkDerivation (finalAttrs: { pname = "python-qt"; - version = "3.4.2"; + version = "3.5.2"; src = fetchFromGitHub { owner = "MeVisLab"; repo = "pythonqt"; - rev = "v${version}"; - hash = "sha256-xJYOD07ACOKtY3psmfHNSCjm6t0fr8JU9CrL0w5P5G0="; + rev = "v${finalAttrs.version}"; + hash = "sha256-Mpi1pAPS/UuzaBK7I1kI0HlS3dphcKiVXIPuJwdEDXM="; }; - # https://github.com/CsoundQt/CsoundQt/blob/develop/BUILDING.md#pythonqt - postPatch = '' - substituteInPlace build/python.prf \ - --replace "PYTHON_VERSION=2.7" "PYTHON_VERSION=${python.pythonVersion}" - ''; - - hardeningDisable = [ "all" ]; - - nativeBuildInputs = [ qmake qtwebengine qtxmlpatterns qttools unzip ]; + nativeBuildInputs = [ + qmake + qttools + qtxmlpatterns + qtwebengine + ]; - buildInputs = [ python ]; + buildInputs = [ python3 ]; qmakeFlags = [ - "PythonQt.pro" - "PYTHON_DIR=${python}" + "PYTHON_DIR=${python3}" + "PYTHON_VERSION=3.${python3.sourceVersion.minor}" ]; dontWrapQtApps = true; - unpackCmd = "unzip $src"; - installPhase = '' mkdir -p $out/include/PythonQt cp -r ./lib $out @@ -42,6 +45,15 @@ stdenv.mkDerivation rec { cp -r ./extensions $out/include/PythonQt ''; + preFixup = lib.optionalString stdenv.isDarwin '' + install_name_tool -id \ + $out/lib/libPythonQt-Qt5-Python3.${python3.sourceVersion.minor}.dylib \ + $out/lib/libPythonQt-Qt5-Python3.${python3.sourceVersion.minor}.dylib + install_name_tool -id \ + $out/lib/libPythonQt_QtAll-Qt5-Python3.${python3.sourceVersion.minor}.dylib \ + $out/lib/libPythonQt_QtAll-Qt5-Python3.${python3.sourceVersion.minor}.dylib + ''; + meta = with lib; { description = "PythonQt is a dynamic Python binding for the Qt framework. It offers an easy way to embed the Python scripting language into your C++ Qt applications"; homepage = "https://pythonqt.sourceforge.net/"; @@ -49,4 +61,4 @@ stdenv.mkDerivation rec { platforms = platforms.all; maintainers = with maintainers; [ hlolli ]; }; -} +}) |