@@ -24,6 +24,13 @@ flag with-aeson
2424 -- with instances by default
2525 default: True
2626
27+flag with-generics
28+ description: Enable GHC.Generics instances
29+ -- don't let the solver fiddle with the flag
30+ manual: True
31+ -- with instances by default
32+ default: True
33+
2734-- A common stanza to share with tests, so that ghcid (bin/test) will reload
2835-- instantly when the library sources change (without us having to restart it).
2936common library-common
@@ -81,13 +88,15 @@ library
8188 JRec.Field
8289 if flag(with-aeson)
8390 cpp-options: -DWITH_AESON
91+ if flag(with-generics)
92+ cpp-options: -DWITH_GENERICS
8493
8594test-suite jrec-test
8695 import: library-common
8796 type: exitcode-stdio-1.0
8897 hs-source-dirs: test, src
8998 main-is: Spec.hs
90− cpp-options: -DWITH_AESON
99+ cpp-options: -DWITH_AESON -DWITH_GENERICS
91100 build-depends:
92101 base,
93102 hspec,