cabal-version:  >=1.10
name:           lhs2tex
version:        1.22
license:        GPL
license-file:   LICENSE
author:         Ralf Hinze <ralf.hinze@comlab.ox.ac.uk>, Andres Loeh <lhs2tex@andres-loeh.de>
maintainer:     Andres Loeh <lhs2tex@andres-loeh.de>
stability:      stable
homepage:       https://github.com/kosmikus/lhs2tex
bug-reports:    https://github.com/kosmikus/lhs2tex/issues
synopsis:       Preprocessor for typesetting Haskell sources with LaTeX
description:
  This tool is primarily intended for people who want to write articles
  or books using LaTeX that contain some Haskell code. It works on literate
  Haskell documents where the non-Haskell parts form essentially a valid
  LaTeX document, then processes the Haskell code in the document and
  replaces it with formatted LaTeX output. It is not fully automatic in
  the sense that it will turn an arbitrary literate Haskell document into
  a LaTeX document without further work.
  .
  Nearly all aspects about the output and formatting are configurable.
  Output of code can be made using proportional fonts in such a way that
  even complex horizontal alignment is preserved. The preprocessor can also
  be invoked in another mode to just extract the Haskell code.
category:       Development, Language
build-type:     Custom
tested-with:    GHC == 7.4.2, GHC == 7.6.3, GHC == 7.8.4, GHC == 7.10.3, GHC == 8.0.2, GHC == 8.2.1, GHC == 8.4.3, GHC == 8.6.1
extra-source-files:     AUTHORS
                        CHANGELOG.md
                        INSTALL
                        TODO
                        doc/*.lhs
                        doc/*.lhs.in
                        doc/*.fmt
                        doc/Guide2.lhs
                        doc/Guide2.pdf
                        doc/Makefile
                        doc/lhs2TeXpre
                        Examples/*.lhs
                        Examples/lhs2TeXpre
                        Library/*.fmt
                        polytable/*.sty
                        polytable/*.pdf
                        src/Version.lhs.in
                        Testsuite/*.snip
                        Testsuite/*.lhs
                        Testsuite/Makefile
                        sorts.snip
                        id.snip
                        cata.snip
                        spec.snip
                        lhs2TeX.fmt.lit
                        lhs2TeX.sty.lit
                        lhs2TeX.1.in
                        Makefile
                        common.mk
                        config.mk.in
                        configure
                        mkinstalldirs
                        install-sh

custom-setup
  setup-depends:        base,
                        Cabal,
                        directory,
                        process,
                        regex-compat

source-repository head
  type:                 git
  location:             https://github.com/kosmikus/lhs2tex

executable lhs2TeX
  main-is:              Main.lhs
  hs-source-dirs:       src
  default-language:     Haskell98
  ghc-options:          -Wall
  other-extensions:     ScopedTypeVariables
                        NPlusKPatterns
                        GeneralizedNewtypeDeriving
                        TypeSynonymInstances
  build-depends:        base >= 4.2 && < 5,
                        regex-compat,
                        mtl >= 2.2.1,
                        filepath,
                        directory,
                        process
  other-modules:        Auxiliaries
                        Directives
                        Document
                        FileNameUtils
                        FiniteMap
                        HsLexer
                        License
                        MathCommon
                        Math
                        MathPoly
                        NewCode
                        Parser
                        State
                        StateT
                        TeXCommands
                        TeXParser
                        Typewriter
                        Value
                        Verbatim
                        Version