about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/libraries/lerc
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/lerc')
-rw-r--r--nixpkgs/pkgs/development/libraries/lerc/default.nix40
1 files changed, 40 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/lerc/default.nix b/nixpkgs/pkgs/development/libraries/lerc/default.nix
new file mode 100644
index 000000000000..f7bba5125a72
--- /dev/null
+++ b/nixpkgs/pkgs/development/libraries/lerc/default.nix
@@ -0,0 +1,40 @@
+{ lib
+, stdenv
+, fetchFromGitHub
+, fetchpatch
+, cmake
+}:
+
+stdenv.mkDerivation rec {
+  pname = "lerc";
+  version = "4.0.0";
+
+  outputs = [ "out" "dev" ];
+
+  src = fetchFromGitHub {
+    owner = "esri";
+    repo = "lerc";
+    rev = "v${version}";
+    hash = "sha256-IHY9QtNYsxPz/ksxRMZGHleT+/bawfTYNVRSTAuYQ7Y=";
+  };
+
+  patches = [
+    # https://github.com/Esri/lerc/pull/227
+    (fetchpatch {
+      name = "use-cmake-install-full-dir.patch";
+      url = "https://github.com/Esri/lerc/commit/5462ca7f7dfb38c65e16f5abfd96873af177a0f8.patch";
+      hash = "sha256-qaNR3QwLe0AB6vu1nXOh9KhlPdWM3DmgCJj4d0VdOUk=";
+    })
+  ];
+
+  nativeBuildInputs = [
+    cmake
+  ];
+
+  meta = {
+    description = "C++ library for Limited Error Raster Compression";
+    homepage = "https://github.com/esri/lerc";
+    license = lib.licenses.asl20;
+    maintainers = with lib.maintainers; [ dotlambda ];
+  };
+}