nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{ lib
2, buildPythonPackage
3, cython
4, fetchPypi
5, numpy
6, pytestCheckHook
7, pythonOlder
8}:
9
10buildPythonPackage rec {
11 pname = "cftime";
12 version = "1.6.0";
13 format = "setuptools";
14
15 disabled = pythonOlder "3.7";
16
17 src = fetchPypi {
18 inherit pname version;
19 sha256 = "sha256-ExA+ZlC+6mVSMWvVgl1qo7fpj1uBFQJt9IJnmN/590E=";
20 };
21
22 nativeBuildInputs = [
23 cython
24 numpy
25 ];
26
27 propagatedBuildInputs = [
28 numpy
29 ];
30
31 checkInputs = [
32 pytestCheckHook
33 ];
34
35 postPatch = ''
36 sed -i "/--cov/d" setup.cfg
37 '';
38
39 pythonImportsCheck = [
40 "cftime"
41 ];
42
43 meta = with lib; {
44 description = "Time-handling functionality from netcdf4-python";
45 homepage = "https://github.com/Unidata/cftime";
46 license = licenses.mit;
47 maintainers = with maintainers; [ ];
48 };
49}