From 60fc04c34b2087c67c1c826fbe354c69d9f8dd69 Mon Sep 17 00:00:00 2001 From: John Ericson Date: Mon, 20 Aug 2018 17:26:42 -0400 Subject: [PATCH] haskell lib: Add appendConfigureFlags For consistency and completeness; other helpers have these "plural" variants too. --- pkgs/development/haskell-modules/lib.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkgs/development/haskell-modules/lib.nix b/pkgs/development/haskell-modules/lib.nix index 8790b56e5019..54616abc4ba8 100644 --- a/pkgs/development/haskell-modules/lib.nix +++ b/pkgs/development/haskell-modules/lib.nix @@ -129,10 +129,12 @@ rec { > haskell.lib.appendConfigureFlag haskellPackages.servant "--profiling-detail=all-functions" */ - appendConfigureFlag = drv: x: overrideCabal drv (drv: { configureFlags = (drv.configureFlags or []) ++ [x]; }); + appendConfigureFlag = drv: x: appendConfigureFlags drv [x]; + appendConfigureFlags = drv: xs: overrideCabal drv (drv: { configureFlags = (drv.configureFlags or []) ++ xs; }); appendBuildFlag = drv: x: overrideCabal drv (drv: { buildFlags = (drv.buildFlags or []) ++ [x]; }); appendBuildFlags = drv: xs: overrideCabal drv (drv: { buildFlags = (drv.buildFlags or []) ++ xs; }); + /* removeConfigureFlag drv x is a Haskell package like drv, but with all cabal configure arguments that are equal to x removed.