nixpkgs/pkgs/development/libraries/nco/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

38 lines
1.1 KiB
Nix
Raw Normal View History

2022-12-03 18:02:29 +00:00
{ lib, stdenv, fetchFromGitHub, netcdf, netcdfcxx4, gsl, udunits, antlr2, which, curl, flex, coreutils, libtool }:
2016-02-22 13:53:34 +00:00
stdenv.mkDerivation rec {
pname = "nco";
2023-03-18 03:09:24 +00:00
version = "5.1.5";
2016-02-22 13:53:34 +00:00
2021-11-01 15:06:00 +00:00
src = fetchFromGitHub {
owner = "nco";
repo = "nco";
2021-11-13 18:28:56 +00:00
rev = version;
2023-03-18 03:09:24 +00:00
sha256 = "sha256-L1aAACWDVrPdl8IHSpch3l8EhdjAxOcUAZchKMYKWqY=";
2016-02-22 13:53:34 +00:00
};
nativeBuildInputs = [ flex which antlr2 ];
buildInputs = [ netcdf netcdfcxx4 gsl udunits curl coreutils ];
postPatch = ''
substituteInPlace src/nco/nco_fl_utl.c \
--replace "/bin/cp" "${coreutils}/bin/cp"
substituteInPlace src/nco/nco_fl_utl.c \
--replace "/bin/mv" "${coreutils}/bin/mv"
'';
2020-09-26 05:14:35 +00:00
2022-12-03 18:02:29 +00:00
makeFlags = lib.optionals stdenv.isDarwin [ "LIBTOOL=${libtool}/bin/libtool" ];
enableParallelBuilding = true;
meta = with lib; {
description = "NetCDF Operator toolkit";
longDescription = "The NCO (netCDF Operator) toolkit manipulates and analyzes data stored in netCDF-accessible formats, including DAP, HDF4, and HDF5";
homepage = "https://nco.sourceforge.net/";
license = licenses.bsd3;
maintainers = with maintainers; [ bzizou ];
2022-12-03 18:02:29 +00:00
platforms = platforms.unix;
2016-02-22 13:53:34 +00:00
};
}