Prepare source-tree for base-4.13 MFP bump
[ghc.git] / compiler / ghc.cabal.in
1 -- WARNING: ghc.cabal is automatically generated from ghc.cabal.in by
2 -- ./configure.  Make sure you are editing ghc.cabal.in, not ghc.cabal.
3
4 Name: ghc
5 Version: @ProjectVersionMunged@
6 License: BSD3
7 License-File: LICENSE
8 Author: The GHC Team
9 Maintainer: glasgow-haskell-users@haskell.org
10 Homepage: http://www.haskell.org/ghc/
11 Synopsis: The GHC API
12 Description:
13     GHC's functionality can be useful for more things than just
14     compiling Haskell programs. Important use cases are programs
15     that analyse (and perhaps transform) Haskell code. Others
16     include loading Haskell code dynamically in a GHCi-like manner.
17     For this reason, a lot of GHC's functionality is made available
18     through this package.
19 Category: Development
20 Build-Type: Simple
21 Cabal-Version: >=1.10
22
23 Flag ghci
24     Description: Build GHCi support.
25     Default: False
26     Manual: True
27
28 Flag stage1
29     Description: Is this stage 1?
30     Default: False
31     Manual: True
32
33 Flag stage2
34     Description: Is this stage 2?
35     Default: False
36     Manual: True
37
38 Flag stage3
39     Description: Is this stage 3?
40     Default: False
41     Manual: True
42
43 Flag terminfo
44     Description: Build GHC with terminfo support on non-Windows platforms.
45     Default: True
46     Manual: True
47
48 Flag integer-simple
49     Description: Use integer-simple
50     Manual: True
51     Default: False
52
53 Flag integer-gmp
54     Description: Use integer-gmp
55     Manual: True
56     Default: False
57
58 Library
59     Default-Language: Haskell2010
60     Exposed: False
61
62     Build-Depends: base       >= 4.11 && < 4.14,
63                    deepseq    >= 1.4 && < 1.5,
64                    directory  >= 1   && < 1.4,
65                    process    >= 1   && < 1.7,
66                    bytestring >= 0.9 && < 0.11,
67                    binary     == 0.8.*,
68                    time       >= 1.4 && < 1.10,
69                    containers >= 0.5 && < 0.7,
70                    array      >= 0.1 && < 0.6,
71                    filepath   >= 1   && < 1.5,
72                    template-haskell == 2.15.*,
73                    hpc        == 0.6.*,
74                    transformers == 0.5.*,
75                    ghc-boot   == @ProjectVersionMunged@,
76                    ghc-boot-th == @ProjectVersionMunged@,
77                    ghc-heap   == @ProjectVersionMunged@,
78                    ghci == @ProjectVersionMunged@
79
80     if os(windows)
81         Build-Depends: Win32  >= 2.3 && < 2.7
82     else
83         if flag(terminfo)
84             Build-Depends: terminfo == 0.4.*
85         Build-Depends: unix   >= 2.7 && < 2.9
86
87     GHC-Options: -Wall
88                  -Wno-name-shadowing
89                  -Wnoncanonical-monad-instances
90                  -Wnoncanonical-monadfail-instances
91                  -Wnoncanonical-monoid-instances
92
93     if flag(ghci)
94         CPP-Options: -DGHCI
95         Include-Dirs: ../rts/dist/build @FFIIncludeDir@
96
97     -- sanity-check to ensure not more than one integer flag is set
98     if flag(integer-gmp) && flag(integer-simple)
99         build-depends: invalid-cabal-flag-settings<0
100
101     -- gmp internals are used by the GHCi debugger if available
102     if flag(integer-gmp)
103         CPP-Options: -DINTEGER_GMP
104         build-depends: integer-gmp >= 1.0.2
105
106     -- simple internals are used by the GHCi debugger if available
107     if flag(integer-simple)
108         CPP-Options: -DINTEGER_SIMPLE
109         build-depends: integer-simple >= 0.1.1.1
110
111     Other-Extensions:
112         BangPatterns
113         CPP
114         DataKinds
115         DeriveDataTypeable
116         DeriveFoldable
117         DeriveFunctor
118         DeriveTraversable
119         DisambiguateRecordFields
120         ExplicitForAll
121         FlexibleContexts
122         FlexibleInstances
123         GADTs
124         GeneralizedNewtypeDeriving
125         MagicHash
126         MultiParamTypeClasses
127         NamedFieldPuns
128         NondecreasingIndentation
129         RankNTypes
130         RecordWildCards
131         ScopedTypeVariables
132         StandaloneDeriving
133         Trustworthy
134         TupleSections
135         TypeFamilies
136         TypeSynonymInstances
137         UnboxedTuples
138         UndecidableInstances
139
140     Include-Dirs: . parser utils
141
142     -- We need to set the unit id to ghc (without a version number)
143     -- as it's magic.
144     GHC-Options: -this-unit-id ghc
145
146     if flag(stage1)
147         Include-Dirs: stage1
148     else
149         if flag(stage2)
150             Include-Dirs: stage2
151         else
152             if flag(stage3)
153                 Include-Dirs: stage2
154
155     Install-Includes: HsVersions.h, ghc_boot_platform.h
156
157     c-sources:
158         parser/cutils.c
159         ghci/keepCAFsForGHCi.c
160         cbits/genSym.c
161
162     hs-source-dirs:
163         backpack
164         basicTypes
165         cmm
166         codeGen
167         coreSyn
168         deSugar
169         ghci
170         hsSyn
171         iface
172         llvmGen
173         main
174         nativeGen
175         parser
176         prelude
177         profiling
178         rename
179         simplCore
180         simplStg
181         specialise
182         stgSyn
183         stranal
184         typecheck
185         types
186         utils
187         hieFile
188
189     -- we use an explicit Prelude
190     Default-Extensions:
191         NoImplicitPrelude
192
193     Other-Modules:
194         GhcPrelude
195
196     Exposed-Modules:
197         HieTypes
198         HieDebug
199         HieBin
200         HieUtils
201         HieAst
202         Ar
203         FileCleanup
204         DriverBkp
205         BkpSyn
206         NameShape
207         RnModIface
208         Avail
209         AsmUtils
210         BasicTypes
211         ConLike
212         DataCon
213         PatSyn
214         Demand
215         Debug
216         Exception
217         FieldLabel
218         GhcMonad
219         Hooks
220         Id
221         IdInfo
222         Lexeme
223         Literal
224         Llvm
225         Llvm.AbsSyn
226         Llvm.MetaData
227         Llvm.PpLlvm
228         Llvm.Types
229         LlvmCodeGen
230         LlvmCodeGen.Base
231         LlvmCodeGen.CodeGen
232         LlvmCodeGen.Data
233         LlvmCodeGen.Ppr
234         LlvmCodeGen.Regs
235         LlvmMangler
236         MkId
237         Module
238         Name
239         NameEnv
240         NameSet
241         OccName
242         RdrName
243         NameCache
244         SrcLoc
245         UniqSupply
246         Unique
247         Var
248         VarEnv
249         VarSet
250         UnVarGraph
251         BlockId
252         CLabel
253         Cmm
254         CmmBuildInfoTables
255         CmmPipeline
256         CmmCallConv
257         CmmCommonBlockElim
258         CmmImplementSwitchPlans
259         CmmContFlowOpt
260         CmmExpr
261         CmmInfo
262         CmmLex
263         CmmLint
264         CmmLive
265         CmmMachOp
266         CmmMonad
267         CmmSwitch
268         CmmNode
269         CmmOpt
270         CmmParse
271         CmmProcPoint
272         CmmSink
273         CmmType
274         CmmUtils
275         CmmLayoutStack
276         EnumSet
277         MkGraph
278         PprBase
279         PprC
280         PprCmm
281         PprCmmDecl
282         PprCmmExpr
283         Bitmap
284         CodeGen.Platform
285         CodeGen.Platform.ARM
286         CodeGen.Platform.ARM64
287         CodeGen.Platform.NoRegs
288         CodeGen.Platform.PPC
289         CodeGen.Platform.SPARC
290         CodeGen.Platform.X86
291         CodeGen.Platform.X86_64
292         CgUtils
293         StgCmm
294         StgCmmBind
295         StgCmmClosure
296         StgCmmCon
297         StgCmmEnv
298         StgCmmExpr
299         StgCmmForeign
300         StgCmmHeap
301         StgCmmHpc
302         StgCmmArgRep
303         StgCmmLayout
304         StgCmmMonad
305         StgCmmPrim
306         StgCmmProf
307         StgCmmTicky
308         StgCmmUtils
309         StgCmmExtCode
310         SMRep
311         CoreArity
312         CoreFVs
313         CoreLint
314         CorePrep
315         CoreSubst
316         CoreOpt
317         CoreSyn
318         TrieMap
319         CoreTidy
320         CoreUnfold
321         CoreUtils
322         CoreMap
323         CoreSeq
324         CoreStats
325         MkCore
326         PprCore
327         PmExpr
328         TmOracle
329         Check
330         Coverage
331         Desugar
332         DsArrows
333         DsBinds
334         DsCCall
335         DsExpr
336         DsForeign
337         DsGRHSs
338         DsListComp
339         DsMonad
340         DsUsage
341         DsUtils
342         ExtractDocs
343         Match
344         MatchCon
345         MatchLit
346         HsBinds
347         HsDecls
348         HsDoc
349         HsExpr
350         HsImpExp
351         HsLit
352         PlaceHolder
353         HsExtension
354         HsInstances
355         HsPat
356         HsSyn
357         HsTypes
358         HsUtils
359         HsDumpAst
360         BinIface
361         BinFingerprint
362         BuildTyCl
363         IfaceEnv
364         IfaceSyn
365         IfaceType
366         ToIface
367         LoadIface
368         MkIface
369         TcIface
370         FlagChecker
371         Annotations
372         CmdLineParser
373         CodeOutput
374         Config
375         Constants
376         DriverMkDepend
377         DriverPhases
378         PipelineMonad
379         DriverPipeline
380         DynFlags
381         ErrUtils
382         Finder
383         GHC
384         GhcMake
385         GhcPlugins
386         DynamicLoading
387         HeaderInfo
388         HscMain
389         HscStats
390         HscTypes
391         InteractiveEval
392         InteractiveEvalTypes
393         PackageConfig
394         Packages
395         PlatformConstants
396         Plugins
397         TcPluginM
398         PprTyThing
399         StaticPtrTable
400         SysTools
401         SysTools.BaseDir
402         SysTools.Terminal
403         SysTools.ExtraObj
404         SysTools.Info
405         SysTools.Process
406         SysTools.Tasks
407         Elf
408         TidyPgm
409         Ctype
410         HaddockUtils
411         Lexer
412         OptCoercion
413         Parser
414         RdrHsSyn
415         ApiAnnotation
416         ForeignCall
417         KnownUniques
418         PrelInfo
419         PrelNames
420         PrelRules
421         PrimOp
422         TysPrim
423         TysWiredIn
424         CostCentre
425         CostCentreState
426         ProfInit
427         RnBinds
428         RnEnv
429         RnExpr
430         RnHsDoc
431         RnNames
432         RnPat
433         RnSource
434         RnSplice
435         RnTypes
436         RnFixity
437         RnUtils
438         RnUnbound
439         CoreMonad
440         CSE
441         FloatIn
442         FloatOut
443         LiberateCase
444         OccurAnal
445         SAT
446         SetLevels
447         SimplCore
448         SimplEnv
449         SimplMonad
450         SimplUtils
451         Simplify
452         SimplStg
453         StgStats
454         StgCse
455         StgLiftLams
456         StgLiftLams.Analysis
457         StgLiftLams.LiftM
458         StgLiftLams.Transformation
459         StgSubst
460         UnariseStg
461         RepType
462         Rules
463         SpecConstr
464         Specialise
465         CoreToStg
466         StgLint
467         StgSyn
468         StgFVs
469         CallArity
470         DmdAnal
471         Exitify
472         WorkWrap
473         WwLib
474         FamInst
475         ClsInst
476         Inst
477         TcAnnotations
478         TcArrows
479         TcBinds
480         TcSigs
481         TcClassDcl
482         TcDefaults
483         TcDeriv
484         TcDerivInfer
485         TcDerivUtils
486         TcEnv
487         TcExpr
488         TcForeign
489         TcGenDeriv
490         TcGenFunctor
491         TcGenGenerics
492         TcHsSyn
493         TcHsType
494         TcInstDcls
495         TcMType
496         TcValidity
497         TcMatches
498         TcPat
499         TcPatSyn
500         TcRnDriver
501         TcBackpack
502         TcRnExports
503         TcRnMonad
504         TcRnTypes
505         TcRules
506         TcSimplify
507         TcHoleErrors
508         TcErrors
509         TcTyClsDecls
510         TcTyDecls
511         TcTypeable
512         TcType
513         TcEvidence
514         TcEvTerm
515         TcUnify
516         TcInteract
517         TcCanonical
518         TcFlatten
519         TcSMonad
520         TcTypeNats
521         TcSplice
522         Class
523         Coercion
524         DsMeta
525         THNames
526         FamInstEnv
527         FunDeps
528         InstEnv
529         TyCon
530         CoAxiom
531         Kind
532         Type
533         TyCoRep
534         Unify
535         Bag
536         Binary
537         BooleanFormula
538         BufWrite
539         Digraph
540         Encoding
541         FastFunctions
542         FastMutInt
543         FastString
544         FastStringEnv
545         Fingerprint
546         FiniteMap
547         FV
548         GraphBase
549         GraphColor
550         GraphOps
551         GraphPpr
552         IOEnv
553         Json
554         ListSetOps
555         ListT
556         Maybes
557         MonadUtils
558         OrdList
559         Outputable
560         Pair
561         Panic
562         PprColour
563         Pretty
564         State
565         Stream
566         StringBuffer
567         UniqDFM
568         UniqDSet
569         UniqFM
570         UniqMap
571         UniqSet
572         Util
573         Hoopl.Block
574         Hoopl.Collections
575         Hoopl.Dataflow
576         Hoopl.Graph
577         Hoopl.Label
578 --        CgInfoTbls used in ghci/DebuggerUtils
579 --        CgHeapery  mkVirtHeapOffsets used in ghci
580
581     Exposed-Modules:
582             AsmCodeGen
583             TargetReg
584             NCGMonad
585             Instruction
586             BlockLayout
587             CFG
588             Format
589             Reg
590             RegClass
591             PIC
592             Platform
593             CPrim
594             X86.Regs
595             X86.RegInfo
596             X86.Instr
597             X86.Cond
598             X86.Ppr
599             X86.CodeGen
600             PPC.Regs
601             PPC.RegInfo
602             PPC.Instr
603             PPC.Cond
604             PPC.Ppr
605             PPC.CodeGen
606             SPARC.Base
607             SPARC.Regs
608             SPARC.Imm
609             SPARC.AddrMode
610             SPARC.Cond
611             SPARC.Instr
612             SPARC.Stack
613             SPARC.ShortcutJump
614             SPARC.Ppr
615             SPARC.CodeGen
616             SPARC.CodeGen.Amode
617             SPARC.CodeGen.Base
618             SPARC.CodeGen.CondCode
619             SPARC.CodeGen.Gen32
620             SPARC.CodeGen.Gen64
621             SPARC.CodeGen.Sanity
622             SPARC.CodeGen.Expand
623             RegAlloc.Liveness
624             RegAlloc.Graph.Main
625             RegAlloc.Graph.Stats
626             RegAlloc.Graph.ArchBase
627             RegAlloc.Graph.ArchX86
628             RegAlloc.Graph.Coalesce
629             RegAlloc.Graph.Spill
630             RegAlloc.Graph.SpillClean
631             RegAlloc.Graph.SpillCost
632             RegAlloc.Graph.TrivColorable
633             RegAlloc.Linear.Main
634             RegAlloc.Linear.JoinToTargets
635             RegAlloc.Linear.State
636             RegAlloc.Linear.Stats
637             RegAlloc.Linear.FreeRegs
638             RegAlloc.Linear.StackMap
639             RegAlloc.Linear.Base
640             RegAlloc.Linear.X86.FreeRegs
641             RegAlloc.Linear.X86_64.FreeRegs
642             RegAlloc.Linear.PPC.FreeRegs
643             RegAlloc.Linear.SPARC.FreeRegs
644             Dwarf
645             Dwarf.Types
646             Dwarf.Constants
647             Convert
648             ByteCodeTypes
649             ByteCodeAsm
650             ByteCodeGen
651             ByteCodeInstr
652             ByteCodeItbls
653             ByteCodeLink
654             Debugger
655             Linker
656             RtClosureInspect
657             GHCi