packages feed

postgresql-simple-bind-0.4.0: postgresql-simple-bind.cabal

name:                postgresql-simple-bind
version:             0.4.0
synopsis:            FFI-like bindings for PostgreSQL stored functions
description:         For tutorial see here: https:\/\/github.com\/zohl\/postgresql-simple-bind\/blob\/master\/README.md
license:             BSD3
license-file:        LICENSE
author:              Al Zohali
maintainer:          Al Zohali <zohl@fmap.me>

category:            Database
build-type:          Simple
cabal-version:       >=1.10

extra-source-files:
  CHANGELOG.md

flag dev
  description: Turn on development settings.
  manual:      True
  default:     False

flag build-examples
  description: Whether to build (and test) examples.
  manual:      False
  default:     False

source-repository head
  type:     git
  location: https://github.com/zohl/postgresql-simple-bind.git

library
  build-depends: base >= 4.7 && < 5.0
               , attoparsec >= 0.13.0 && < 0.14
               , bytestring >= 0.10.8 && < 0.11
               , data-default
               , exceptions
               , heredoc >= 0.2.0 && < 0.3
               , postgresql-simple >= 0.5.2 && < 0.6
               , template-haskell >= 2.11.0 && < 2.12
               , text >= 1.2.2 && < 1.3
               , time >= 1.6.0 && < 1.7

  hs-source-dirs: src
  exposed-modules:
     Database.PostgreSQL.Simple.Bind
     Database.PostgreSQL.Simple.Bind.Common
     Database.PostgreSQL.Simple.Bind.Representation
     Database.PostgreSQL.Simple.Bind.Types
     Database.PostgreSQL.Simple.Bind.Utils

  other-modules:
     Database.PostgreSQL.Simple.Bind.Implementation

  default-language:    Haskell2010

  if flag(dev)
    ghc-options:      -Wall -Werror
  else
    ghc-options:      -O2 -Wall

test-suite tests
  type:           exitcode-stdio-1.0

  hs-source-dirs: tests
  main-is:        Main.hs

  ghc-options: -Wall

  build-depends: base >= 4.7 && < 5.0
               , bytestring >= 0.10.8 && < 0.11
               , hspec
               , postgresql-simple >= 0.5.2 && < 0.6
               , postgresql-simple-bind
               , text >= 1.2.2 && < 1.3

  default-language:    Haskell2010

  if flag(dev)
    ghc-options: -Werror
  else
    ghc-options: -O2


test-suite examples
  type:           exitcode-stdio-1.0

  hs-source-dirs:   examples
  main-is:          Main.hs
  default-language: Haskell2010

  ghc-options: -Wall -Wno-redundant-constraints

  if flag(build-examples)
    build-depends: base >= 4.7 && < 5.0
                 , attoparsec >= 0.13.0 && < 0.14
                 , bytestring >= 0.10.8 && < 0.11
                 , case-conversion
                 , data-default
                 , hspec
                 , postgresql-simple >= 0.5.2 && < 0.6
                 , postgresql-simple-bind
                 , text >= 1.2.2 && < 1.3

    if flag(dev)
      ghc-options: -Werror
    else
      ghc-options: -O2

  else
    buildable: False