From bce0bd56e80922990dd2e322476db6c73f6547a0 Mon Sep 17 00:00:00 2001 From: Manuel Frischknecht Date: Fri, 1 Dec 2023 19:51:05 +0100 Subject: [PATCH] Add `patches` option to `buildExtension` of `gawkextlib` With this, it's possible to add patches to the `gawkextlib` source code in the declaration of the specific extensions that need them. --- pkgs/tools/text/gawk/gawkextlib.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/tools/text/gawk/gawkextlib.nix b/pkgs/tools/text/gawk/gawkextlib.nix index 9a25407d7116..4a796dfe8591 100644 --- a/pkgs/tools/text/gawk/gawkextlib.nix +++ b/pkgs/tools/text/gawk/gawkextlib.nix @@ -5,7 +5,7 @@ let buildExtension = lib.makeOverridable - ({ name, gawkextlib, extraBuildInputs ? [ ], doCheck ? true }: + ({ name, gawkextlib, extraBuildInputs ? [ ], doCheck ? true, patches ? [ ] }: let is_extension = gawkextlib != null; in stdenv.mkDerivation rec { pname = "gawkextlib-${name}"; @@ -17,6 +17,8 @@ let sha256 = "sha256-0p3CrQ3TBl7UcveZytK/9rkAzn69RRM2GwY2eCeqlkg="; }; + inherit patches; + postPatch = '' cd ${name} '';