Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 20.09 1.2 kB view raw
1{ stdenv, fetchurl, python, qmake, 2 qtwebengine, qtxmlpatterns, 3 qttools, unzip }: 4 5stdenv.mkDerivation rec { 6 version = "3.2"; 7 pname = "python-qt"; 8 9 src = fetchurl { 10 url="mirror://sourceforge/pythonqt/PythonQt${version}.zip"; 11 sha256="13hzprk58m3yj39sj0xn6acg8796lll1256mpd81kw0z3yykyl8c"; 12 }; 13 14 hardeningDisable = [ "all" ]; 15 16 nativeBuildInputs = [ qmake qtwebengine qtxmlpatterns qttools ]; 17 18 buildInputs = [ python unzip ]; 19 20 qmakeFlags = [ "PythonQt.pro" 21 "INCLUDEPATH+=${python}/include/python3.6" 22 "PYTHON_PATH=${python}/bin" 23 "PYTHON_LIB=${python}/lib"]; 24 25 unpackCmd = "unzip $src"; 26 27 installPhase = '' 28 mkdir -p $out/include/PythonQt 29 cp -r ./lib $out 30 cp -r ./src/* $out/include/PythonQt 31 cp -r ./build $out/include/PythonQt 32 cp -r ./extensions $out/include/PythonQt 33 ''; 34 35 meta = with stdenv.lib; { 36 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."; 37 homepage = "http://pythonqt.sourceforge.net/"; 38 license = licenses.lgpl21; 39 platforms = platforms.all; 40 maintainers = with maintainers; [ hlolli ]; 41 }; 42}