From 07d59e00ab42cd3a1b2eae290b23d6d77784a761 Mon Sep 17 00:00:00 2001 From: Jonathan King Date: Sun, 5 Mar 2023 18:34:11 +0000 Subject: [PATCH] Introduce 'pkg-config' cabal flag --- digest.cabal | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/digest.cabal b/digest.cabal index b958879..d9a2498 100644 --- a/digest.cabal +++ b/digest.cabal @@ -25,6 +25,11 @@ extra-source-files: testing/trivial.hs CHANGELOG.md +flag pkg-config + default: True + manual: True + description: Use @pkg-config(1)@ to locate @zlib@ library. + source-repository head type: git location: https://github.com/TeofilC/digest @@ -39,7 +44,7 @@ library , bytestring >= 0.9 && < 0.12 includes: zlib.h ghc-options: -Wall - if !os(windows) + if flag(pkg-config) && !os(windows) pkgconfig-depends: zlib else build-depends: zlib