Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{lib, fetchFromGitHub, pythonOlder, buildPythonPackage, gfortran, mock, xarray, wrapt, numpy, netcdf4, setuptools}: 2 3buildPythonPackage rec { 4 pname = "wrf-python"; 5 version = "1.3.2"; 6 7 src = fetchFromGitHub { 8 owner = "NCAR"; 9 repo = "wrf-python"; 10 rev = version; 11 sha256 = "1rklkki54z5392cpwwy78bnmsy2ghc187l3j7nv0rzn6jk5bvyi7"; 12 }; 13 14 propagatedBuildInputs = [ 15 wrapt 16 numpy 17 setuptools 18 xarray 19 ]; 20 21 nativeBuildInputs = [ 22 gfortran 23 ]; 24 25 checkInputs = [ 26 netcdf4 27 ] ++ lib.optional (pythonOlder "3.3") mock; 28 29 doCheck = true; 30 checkPhase = '' 31 runHook preCheck 32 cd ./test/ci_tests 33 python utests.py 34 runHook postCheck 35 ''; 36 37 meta = { 38 description = "WRF postprocessing library for Python"; 39 homepage = "http://wrf-python.rtfd.org"; 40 license = lib.licenses.asl20; 41 maintainers = with lib.maintainers; [ mhaselsteiner ]; 42 }; 43}