name:                cmark
version:             0.4.1
synopsis:            Fast, accurate CommonMark (Markdown) parser and renderer
description:
  This package provides Haskell bindings for
  <https://github.com/jgm/cmark libcmark>, the reference
  parser for <http://commonmark.org CommonMark>, a fully
  specified variant of Markdown. It includes sources for
  libcmark (0.21.0) and does not require prior installation of the
  C library.

homepage:            https://github.com/jgm/commonmark-hs
license:             BSD3
license-file:        LICENSE
author:              John MacFarlane
maintainer:          jgm@berkeley.edu
copyright:           (C) 2015 John MacFarlane
category:            Text
tested-with:         GHC == 7.4.2, GHC == 7.6.3, GHC == 7.8.2
build-type:          Simple
extra-source-files:  README.md
                     changelog
                     cbits/bench.h
                     cbits/chunk.h
                     cbits/cmark_export.h
                     cbits/debug.h
                     cbits/inlines.h
                     cbits/cmark.h
                     cbits/houdini.h
                     cbits/references.h
                     cbits/utf8.h
                     cbits/parser.h
                     cbits/cmark_version.h
                     cbits/html_unescape.h
                     cbits/iterator.h
                     cbits/node.h
                     cbits/buffer.h
                     cbits/render.h
                     cbits/cmark_ctype.h
                     cbits/config.h
                     cbits/scanners.h
                     cbits/case_fold_switch.inc
                     cbits/entities.inc
                     bench/sample.md
                     bench/full-sample.md
cabal-version:       >=1.14

Source-repository head
  type:              git
  location:          git://github.com/jgm/cmark-hs.git

library
  exposed-modules:     CMark
  build-depends:       base >=4.5 && < 4.9,
                       text >= 1.0 && < 1.3,
                       bytestring
  if impl(ghc < 7.6)
    build-depends:     ghc-prim >= 0.2
  default-language:    Haskell2010
  ghc-options:         -Wall -fno-warn-unused-do-bind
  cc-options:          -Wall -std=c99
  Include-dirs:        cbits
  Includes:            cmark.h
  c-sources:           cbits/houdini_html_u.c
                       cbits/references.c
                       cbits/utf8.c
                       cbits/inlines.c
                       cbits/blocks.c
                       cbits/cmark.c
                       cbits/iterator.c
                       cbits/node.c
                       cbits/buffer.c
                       cbits/cmark_ctype.c
                       cbits/houdini_html_e.c
                       cbits/houdini_href_e.c
                       cbits/scanners.c
                       cbits/html.c
                       cbits/man.c
                       cbits/commonmark.c
                       cbits/latex.c
                       cbits/xml.c
                       cbits/render.c

benchmark bench-cmark
  type:             exitcode-stdio-1.0
  hs-source-dirs:   bench
  main-is:          bench-cmark.hs
  build-depends:    base, text, cmark, criterion,
                    sundown >= 0.6 && < 0.7,
                    cheapskate >= 0.1 && < 0.2,
                    markdown >= 0.1 && < 0.2,
                    discount >= 0.1 && < 0.2,
                    blaze-html >= 0.7 && < 0.9
  ghc-options:      -O2
  default-language: Haskell2010

Test-Suite test-cmark
  type:           exitcode-stdio-1.0
  main-is:        test-cmark.hs
  hs-source-dirs: test
  build-depends:  base, cmark, text, HUnit >= 1.2 && < 1.4
  ghc-options:    -Wall -fno-warn-unused-do-bind -threaded
  default-language: Haskell98
