From 762abd826ee335f7c7f528ef144142e2fd311b52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niklas=20Hamb=C3=BCchen?= Date: Sat, 15 Jun 2024 19:49:39 +0200 Subject: [PATCH] libtiff: Add patch to fix missing `Lerc` in libtiff-4.pc --- pkgs/development/libraries/libtiff/default.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/pkgs/development/libraries/libtiff/default.nix b/pkgs/development/libraries/libtiff/default.nix index c8871a4ba68e8..9a0ecc34d02bc 100644 --- a/pkgs/development/libraries/libtiff/default.nix +++ b/pkgs/development/libraries/libtiff/default.nix @@ -1,6 +1,7 @@ { lib , stdenv , fetchFromGitLab +, fetchpatch , nix-update-script , autoreconfHook @@ -41,6 +42,15 @@ stdenv.mkDerivation (finalAttrs: { # libc++abi 11 has an `#include `, this picks up files name # `version` in the project's include paths ./rename-version.patch + # Fix static linking of `libtiff` via `pkg-config` not working + # because `libtiff` does not declare `Lerc` dependency. + # nixpkgs has `lerc` >= 4 which provides a `.pc` file. + # TODO: Close when https://gitlab.com/libtiff/libtiff/-/merge_requests/633 is merged and available + (fetchpatch { + name = "libtiff-4.pc-Fix-Requires.private-missing-Lerc.patch"; + url = "https://gitlab.com/libtiff/libtiff/-/commit/ea882c3c240c14a897b9be38d815cc1893aafa59.patch"; + hash = "sha256-C0xA3k1sgKmGJjEnyG9UxhXqYBYShKUDQsyjhbEDJbQ="; + }) ]; postPatch = ''