Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / pynest2d / default.nix
blob694459bf0050d00dad324e5b42e47d04c0217ab2
1 { lib, buildPythonPackage, fetchFromGitHub, python, cmake
2 , libnest2d, sip_4, clipper }:
4 buildPythonPackage rec {
5   version = "4.12.0";
6   pname = "pynest2d";
7   format = "other";
9   src = fetchFromGitHub {
10     owner = "Ultimaker";
11     repo = "pynest2d";
12     rev = version;
13     hash = "sha256-QQdTDhO4i9NVhegGTmdEQSNv3gooaZzTX/Rv86h3GEo=";
14   };
16   propagatedBuildInputs = [ libnest2d sip_4 clipper ];
17   nativeBuildInputs = [ cmake ];
19   CLIPPER_PATH = "${clipper.out}";
21   postPatch = ''
22      sed -i 's#''${Python3_SITEARCH}#${placeholder "out"}/${python.sitePackages}#' cmake/SIPMacros.cmake
23    '';
25   meta = with lib; {
26     description = "Python bindings for libnest2d";
27     homepage = "https://github.com/Ultimaker/pynest2d";
28     license = licenses.lgpl3;
29     platforms = platforms.linux;
30   };