Name:		encoding
Version:	0.9
Author:		Henning Günther
Maintainer:	daniel@wagner-home.com, Andrey Prokopenko
License:	BSD3
License-File:   LICENSE
Synopsis:	A library for various character encodings
Description:
  Haskell has excellect handling of unicode, the Char type covers all unicode chars. Unfortunately, there's no possibility to read or write something to the outer world in an encoding other than ascii due to the lack of support for encodings. This library should help with that.
Category:	Codec
Homepage:	https://github.com/dmwit/encoding
Bug-Reports:    https://github.com/dmwit/encoding/issues
Cabal-Version:	2.0
Build-Type:	Simple
Extra-Source-Files:
  CHANGELOG
  README.md
  system_encoding.h
  system_encoding.c

Flag systemEncoding
  description: Provide the getSystemEncoding action to query the locale.

Flag generate-encodings
  description: Generate encodings.
  manual: True
  default: False

Source-Repository head
  Type:         git
  Location:     http://github.com/dmwit/encoding

Library
  Build-Depends: array >=0.4 && <0.6,
                 base >=4 && <5,
                 binary >=0.7 && <0.10,
                 bytestring >=0.9 && <0.13,
                 containers >=0.4 && <0.8,
                 extensible-exceptions >=0.1 && <0.2,
                 ghc-prim >=0.3 && <0.12,
                 mtl >=2.0 && <2.4,
                 regex-compat >=0.71 && <0.96

  Default-Language: Haskell2010

  Exposed-Modules:
    Data.Encoding
    Data.Encoding.ByteSource
    Data.Encoding.ByteSink
    Data.Encoding.Exception
    Control.Throws
    Data.Encoding.ASCII
    Data.Encoding.UTF8
    Data.Encoding.UTF16
    Data.Encoding.UTF32
    Data.Encoding.KOI8R
    Data.Encoding.KOI8U
    Data.Encoding.ISO88591
    Data.Encoding.ISO88592
    Data.Encoding.ISO88593
    Data.Encoding.ISO88594
    Data.Encoding.ISO88595
    Data.Encoding.ISO88596
    Data.Encoding.ISO88597
    Data.Encoding.ISO88598
    Data.Encoding.ISO88599
    Data.Encoding.ISO885910
    Data.Encoding.ISO885911
    Data.Encoding.ISO885913
    Data.Encoding.ISO885914
    Data.Encoding.ISO885915
    Data.Encoding.ISO885916
    Data.Encoding.CP1250
    Data.Encoding.CP1251
    Data.Encoding.CP1252
    Data.Encoding.CP1253
    Data.Encoding.CP1254
    Data.Encoding.CP1255
    Data.Encoding.CP1256
    Data.Encoding.CP1257
    Data.Encoding.CP1258
    Data.Encoding.GB18030
    Data.Encoding.BootString
    Data.Encoding.MacOSRoman
    Data.Encoding.JISX0201
    Data.Encoding.JISX0208
    Data.Encoding.JISX0212
    Data.Encoding.ISO2022
    Data.Encoding.ISO2022JP
    Data.Encoding.ShiftJIS
    Data.Encoding.CP437
    Data.Encoding.CP737
    Data.Encoding.CP775
    Data.Encoding.CP850
    Data.Encoding.CP852
    Data.Encoding.CP855
    Data.Encoding.CP857
    Data.Encoding.CP860
    Data.Encoding.CP861
    Data.Encoding.CP862
    Data.Encoding.CP863
    Data.Encoding.CP864
    Data.Encoding.CP865
    Data.Encoding.CP866
    Data.Encoding.CP869
    Data.Encoding.CP874
    Data.Encoding.CP932
    System.IO.Encoding
    Data.Static
  Other-Modules:
    Data.Encoding.Base
    Data.Array.Static
    Data.Map.Static
    Data.CharMap
  if impl(ghc >= 7.10)
    GHC-Options: -fno-warn-tabs
  if flag(systemEncoding)
    Includes:
      system_encoding.h
    Install-Includes:
      system_encoding.h
    C-Sources:
      system_encoding.c
    CPP-Options: -DSYSTEM_ENCODING

executable encoding-exe
  main-is: Main.hs
  hs-source-dirs: app
  if flag(generate-encodings)
    build-depends:     base
                     , optparse-applicative
                     , directory
                     , filepath
                     , containers
                     , HaXml >=1.22 && <1.27
                     , Cabal >= 2.0 && < 3.14
                     , encoding
  else
    buildable: False
  other-modules:
    Data.Encoding.Preprocessor.Mapping
    Data.Encoding.Preprocessor.XMLMapping
    Data.Encoding.Preprocessor.XMLMappingBuilder
    Data.CharMap.Builder
    Data.Map.Static.Builder
    Data.Array.Static.Builder
    Utils
  ghc-options: -threaded -rtsopts -with-rtsopts=-N
  Default-Language:  Haskell2010

test-suite encoding-test
  type:                exitcode-stdio-1.0
  hs-source-dirs:      tests
  main-is:             Main.hs
  other-modules:       Test.Tester
                     , Test.Tests
  build-depends:       base
                     , bytestring
                     , encoding
                     , HUnit
                     , QuickCheck
  ghc-options:         -threaded -rtsopts -with-rtsopts=-N
  Default-Language:  Haskell2010