`buildDotnetModule`: add support for installing pre-release tools (#374663)
[NixPkgs.git] / pkgs / development / python-modules / pykdtree / default.nix
bloba1958b26bb2f50d0a26adde906b62f7cf0ac202c
2   lib,
3   buildPythonPackage,
4   fetchPypi,
6   # build-system
7   cython,
8   numpy,
9   setuptools,
11   # native dependencies
12   openmp,
14   # tests
15   pytestCheckHook,
18 buildPythonPackage rec {
19   pname = "pykdtree";
20   version = "1.4.1";
21   pyproject = true;
23   src = fetchPypi {
24     inherit pname version;
25     hash = "sha256-EISP9qxzMraOZb+MLolme2tisHWq0nI0d0Smm/HIrX4=";
26   };
28   nativeBuildInputs = [
29     cython
30     numpy
31     setuptools
32   ];
34   buildInputs = [ openmp ];
36   propagatedBuildInputs = [ numpy ];
38   preCheck = ''
39     # make sure we don't import pykdtree from the source tree
40     mv pykdtree/test_tree.py .
41     rm -rf pykdtree
42   '';
44   nativeCheckInputs = [ pytestCheckHook ];
46   meta = with lib; {
47     description = "kd-tree implementation for fast nearest neighbour search in Python";
48     homepage = "https://github.com/storpipfugl/pykdtree";
49     license = licenses.lgpl3;
50     maintainers = with maintainers; [ psyanticy ];
51   };