summaryrefslogtreecommitdiff
path: root/bytes.cabal
blob: debb7eae03ddcf889e9b056189f37fbf3aa9914a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
name:          bytes
category:      Data, Serialization
version:       0.15.2
license:       BSD3
cabal-version: >= 1.8
license-file:  LICENSE
author:        Edward A. Kmett
maintainer:    Edward A. Kmett <ekmett@gmail.com>
stability:     experimental
homepage:      https://github.com/ekmett/bytes
bug-reports:   https://github.com/ekmett/bytes/issues
copyright:     Copyright (C) 2013-2015 Edward A. Kmett
build-type:    Custom
tested-with:   GHC == 7.4.2, GHC == 7.6.3, GHC == 7.8.4, GHC == 7.10.2
synopsis:      Sharing code for serialization between binary and cereal
description:   Sharing code for serialization between binary and cereal

extra-source-files:
  .travis.yml
  .ghci
  .gitignore
  .vim.custom
  travis/cabal-apt-install
  travis/config
  AUTHORS.markdown
  README.markdown
  CHANGELOG.markdown

source-repository head
  type: git
  location: git://github.com/ekmett/bytes.git

-- You can disable the doctests test suite with -f-test-doctests
flag test-doctests
  description: Enable (or disable via f-test-doctests) the doctest suite when
               using the enable-tests option for cabal.
  default: True
  manual: True

library
  build-depends:
    base                      >= 4.5      && < 5,
    binary                    >= 0.5.1    && < 0.9,
    bytestring                >= 0.9      && < 0.11,
    cereal                    >= 0.3.5    && < 0.6,
    containers                >= 0.3      && < 1,
    hashable                  >= 1.0.1.1  && < 1.4,
    mtl                       >= 2.0      && < 2.3,
    text                      >= 0.2      && < 1.3,
    time                      >= 1.2      && < 1.7,
    transformers              >= 0.2      && < 0.6,
    transformers-compat       >= 0.3      && < 1,
    unordered-containers      >= 0.2      && < 0.3,
    scientific                >= 0.0      && < 1,
    void                      >= 0.6      && < 1

  if impl(ghc >= 7.4 && < 7.6)
    build-depends: ghc-prim

  -- hack around the buggy unused matches check for class associated types in ghc 8 rc1
  if impl(ghc >= 8)
    ghc-options: -fno-warn-unused-matches


  exposed-modules:
    Data.Bytes.Get
    Data.Bytes.Put
    Data.Bytes.Serial
    Data.Bytes.Signed
    Data.Bytes.VarInt

  ghc-options: -Wall -fwarn-tabs -O2
  c-sources: cbits/i2d.c
  hs-source-dirs: src

test-suite doctests
  type:           exitcode-stdio-1.0
  main-is:        doctests.hs
  ghc-options:    -Wall -threaded
  hs-source-dirs: tests

  if !flag(test-doctests) || impl(ghc >= 8)
    buildable: False
  else
    build-depends:
      base,
      bytes,
      directory      >= 1.0,
      doctest        >= 0.9.1,
      filepath       >= 1.2