at master 1.3 kB view raw
1{ 2 python, 3 lib, 4 stdenv, 5 pyside2, 6 cmake, 7 qt5, 8 libxcrypt, 9 llvmPackages, 10}: 11 12stdenv.mkDerivation { 13 pname = "shiboken2"; 14 15 inherit (pyside2) version src patches; 16 17 postPatch = '' 18 cd sources/shiboken2 19 ''; 20 21 CLANG_INSTALL_DIR = llvmPackages.libclang.out; 22 23 nativeBuildInputs = [ 24 cmake 25 (python.withPackages ( 26 ps: with ps; [ 27 distutils 28 setuptools 29 ] 30 )) 31 qt5.qmake 32 ]; 33 34 buildInputs = [ 35 llvmPackages.libclang 36 python.pkgs.setuptools 37 qt5.qtbase 38 qt5.qtxmlpatterns 39 ] 40 ++ (lib.optionals (python.pythonOlder "3.9") [ 41 # see similar issue: 202262 42 # libxcrypt is required for crypt.h for building older python modules 43 libxcrypt 44 ]); 45 46 cmakeFlags = [ "-DBUILD_TESTS=OFF" ]; 47 48 dontWrapQtApps = true; 49 50 postInstall = '' 51 cd ../../.. 52 ${python.pythonOnBuildForHost.interpreter} setup.py egg_info --build-type=shiboken2 53 cp -r shiboken2.egg-info $out/${python.sitePackages}/ 54 rm $out/bin/shiboken_tool.py 55 ''; 56 57 meta = with lib; { 58 description = "Generator for the PySide2 Qt bindings"; 59 mainProgram = "shiboken2"; 60 license = with licenses; [ 61 gpl2 62 lgpl21 63 ]; 64 homepage = "https://wiki.qt.io/Qt_for_Python"; 65 maintainers = with maintainers; [ ]; 66 broken = python.pythonAtLeast "3.13"; 67 }; 68}