summaryrefslogtreecommitdiff
path: root/gf.cabal
diff options
context:
space:
mode:
Diffstat (limited to 'gf.cabal')
-rw-r--r--gf.cabal25
1 files changed, 25 insertions, 0 deletions
diff --git a/gf.cabal b/gf.cabal
index a19772a57..05a1c4f91 100644
--- a/gf.cabal
+++ b/gf.cabal
@@ -73,6 +73,11 @@ flag pre-pmcfg
Default: False
Manual: True
+flag pmcfg-test-hooks
+ Description: Expose test-only PMCFG differential hooks
+ Default: False
+ Manual: True
+
library
default-language: Haskell2010
build-depends:
@@ -301,6 +306,14 @@ library
other-modules:
GF.Compile.GeneratePmcfgPre
+ if flag(pmcfg-test-hooks)
+ cpp-options: -DPMCFG_TEST_HOOKS
+ exposed-modules:
+ GF.Compile.PMCFGTestHooks
+ other-modules:
+ GF.Compile.PMCFGTestTypes
+ GF.Compile.GeneratePmcfgPre
+
if flag(server)
build-depends:
cgi >= 3001.3.0.2 && < 3001.6,
@@ -432,3 +445,15 @@ test-suite gf-tests
process >= 1.4.3 && < 1.7
build-tool-depends: gf:gf
default-language: Haskell2010
+
+test-suite pmcfg-tests
+ type: exitcode-stdio-1.0
+ main-is: run.hs
+ hs-source-dirs: testsuite/pmcfg
+ build-depends:
+ base >= 4.9.1 && < 4.22,
+ gf
+ default-language: Haskell2010
+
+ if !flag(pmcfg-test-hooks)
+ buildable: False