@@ -11,6 +11,11 @@ maintainer: nick@typeable.io
1111category: Web
1212build-type: Simple
1313
14+flag openapi
15+ description: Enable openapi instances
16+ default: False
17+ manual: True
18+
1419common warnings
1520 ghc-options: -Wall
1621
@@ -18,7 +23,6 @@ library
1823 import: warnings
1924 exposed-modules: Web.Tracking.Servant
2025 other-modules: Web.Tracking.Servant.Types
21− -- other-extensions:
2226 build-depends: base >=4.14.0.0 && < 5,
2327 bytestring >= 0.11,
2428 containers >= 0.6,
@@ -28,5 +32,9 @@ library
2832 servant-client-core >= 0.19,
2933 servant-server >= 0.19,
3034 wai >= 3.2
35+ if flag(openapi)
36+ other-modules: Web.Tracking.Servant.OpenAPI
37+ build-depends: servant-openapi3
38+ cpp-options: -DOPENAPI
3139 hs-source-dirs: src
3240 default-language: GHC2021