at 22.05-pre 1.0 kB view raw
1{ lib, stdenv, fetchPypi, buildPythonPackage, packaging, toml }: 2 3buildPythonPackage rec { 4 pname = "sip"; 5 version = "6.1.1"; 6 7 src = fetchPypi { 8 pname = "sip"; 9 inherit version; 10 sha256 = "083ykzg7zbvrfrg3ram2vx93zrmhpm817kf9bkhw8r6pzkr5mljj"; 11 }; 12 13 propagatedBuildInputs = [ packaging toml ]; 14 15 # There aren't tests 16 doCheck = false; 17 18 pythonImportsCheck = [ "sipbuild" ]; 19 20 # FIXME: Why isn't this detected automatically? 21 # Needs to be specified in pyproject.toml, e.g.: 22 # [tool.sip.bindings.MODULE] 23 # tags = [PLATFORM_TAG] 24 platform_tag = 25 if stdenv.targetPlatform.isLinux then 26 "WS_X11" 27 else if stdenv.targetPlatform.isDarwin then 28 "WS_MACX" 29 else if stdenv.targetPlatform.isWindows then 30 "WS_WIN" 31 else 32 throw "unsupported platform"; 33 34 meta = with lib; { 35 description = "Creates C++ bindings for Python modules"; 36 homepage = "https://riverbankcomputing.com/"; 37 license = licenses.gpl3Only; 38 maintainers = with maintainers; [ ]; 39 }; 40}