b78c2b89e9bc45fcc1da807919cb4161189d8e9e
[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: @ProjectVersion@
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 Library
44     Default-Language: Haskell2010
45     Exposed: False
46
47     Build-Depends: base       >= 4   && < 5,
48                    directory  >= 1   && < 1.3,
49                    process    >= 1   && < 1.5,
50                    bytestring >= 0.9 && < 0.11,
51                    binary     >= 0.7 && < 0.8,
52                    time                 < 1.6,
53                    containers >= 0.5 && < 0.6,
54                    array      >= 0.1 && < 0.6,
55                    filepath   >= 1   && < 1.5,
56                    template-haskell,
57                    hpc,
58                    transformers,
59                    ghc-boot,
60                    hoopl
61
62     if os(windows)
63         Build-Depends: Win32
64     else
65         Build-Depends: unix
66
67     GHC-Options: -Wall -fno-warn-name-shadowing
68
69     if flag(ghci)
70         CPP-Options: -DGHCI
71         Include-Dirs: ../rts/dist/build @FFIIncludeDir@
72
73     Other-Extensions:
74         BangPatterns
75         CPP
76         DataKinds
77         DeriveDataTypeable
78         DeriveFoldable
79         DeriveFunctor
80         DeriveTraversable
81         DisambiguateRecordFields
82         ExplicitForAll
83         FlexibleContexts
84         FlexibleInstances
85         GADTs
86         GeneralizedNewtypeDeriving
87         MagicHash
88         MultiParamTypeClasses
89         NamedFieldPuns
90         NondecreasingIndentation
91         RankNTypes
92         RecordWildCards
93         ScopedTypeVariables
94         StandaloneDeriving
95         Trustworthy
96         TupleSections
97         TypeFamilies
98         TypeSynonymInstances
99         UnboxedTuples
100         UndecidableInstances
101
102     Include-Dirs: . parser utils
103
104     if impl( ghc >= 7.9 )
105         -- We need to set the unit id to ghc (without a version number)
106         -- as it's magic.  But we can't set it for old versions of GHC (e.g.
107         -- when bootstrapping) because those versions of GHC don't understand
108         -- that GHC is wired-in.
109         GHC-Options: -this-package-key ghc
110
111     if flag(stage1)
112         Include-Dirs: stage1
113     else
114         if flag(stage2)
115             Include-Dirs: stage2
116         else
117             if flag(stage3)
118                 Include-Dirs: stage2
119
120     Install-Includes: HsVersions.h, ghc_boot_platform.h
121
122     c-sources:
123         parser/cutils.c
124         ghci/keepCAFsForGHCi.c
125         cbits/genSym.c
126
127     hs-source-dirs:
128         backpack
129         basicTypes
130         cmm
131         codeGen
132         coreSyn
133         deSugar
134         ghci
135         hsSyn
136         iface
137         llvmGen
138         main
139         nativeGen
140         parser
141         prelude
142         profiling
143         rename
144         simplCore
145         simplStg
146         specialise
147         stgSyn
148         stranal
149         typecheck
150         types
151         utils
152         vectorise
153
154     Exposed-Modules:
155         Avail
156         BasicTypes
157         ConLike
158         DataCon
159         PatSyn
160         Demand
161         Debug
162         Exception
163         FieldLabel
164         GhcMonad
165         Hooks
166         Id
167         IdInfo
168         Lexeme
169         Literal
170         Llvm
171         Llvm.AbsSyn
172         Llvm.MetaData
173         Llvm.PpLlvm
174         Llvm.Types
175         LlvmCodeGen
176         LlvmCodeGen.Base
177         LlvmCodeGen.CodeGen
178         LlvmCodeGen.Data
179         LlvmCodeGen.Ppr
180         LlvmCodeGen.Regs
181         LlvmMangler
182         MkId
183         Module
184         Name
185         NameEnv
186         NameSet
187         OccName
188         RdrName
189         SrcLoc
190         UniqSupply
191         Unique
192         Var
193         VarEnv
194         VarSet
195         UnVarGraph
196         BlockId
197         CLabel
198         Cmm
199         CmmBuildInfoTables
200         CmmPipeline
201         CmmCallConv
202         CmmCommonBlockElim
203         CmmImplementSwitchPlans
204         CmmContFlowOpt
205         CmmExpr
206         CmmInfo
207         CmmLex
208         CmmLint
209         CmmLive
210         CmmMachOp
211         CmmSwitch
212         CmmNode
213         CmmOpt
214         CmmParse
215         CmmProcPoint
216         CmmSink
217         CmmType
218         CmmUtils
219         CmmLayoutStack
220         MkGraph
221         PprBase
222         PprC
223         PprCmm
224         PprCmmDecl
225         PprCmmExpr
226         Bitmap
227         CodeGen.Platform
228         CodeGen.Platform.ARM
229         CodeGen.Platform.ARM64
230         CodeGen.Platform.NoRegs
231         CodeGen.Platform.PPC
232         CodeGen.Platform.PPC_Darwin
233         CodeGen.Platform.SPARC
234         CodeGen.Platform.X86
235         CodeGen.Platform.X86_64
236         CgUtils
237         StgCmm
238         StgCmmBind
239         StgCmmClosure
240         StgCmmCon
241         StgCmmEnv
242         StgCmmExpr
243         StgCmmForeign
244         StgCmmHeap
245         StgCmmHpc
246         StgCmmArgRep
247         StgCmmLayout
248         StgCmmMonad
249         StgCmmPrim
250         StgCmmProf
251         StgCmmTicky
252         StgCmmUtils
253         StgCmmExtCode
254         SMRep
255         CoreArity
256         CoreFVs
257         CoreLint
258         CorePrep
259         CoreSubst
260         CoreSyn
261         TrieMap
262         CoreTidy
263         CoreUnfold
264         CoreUtils
265         CoreSeq
266         CoreStats
267         MkCore
268         PprCore
269         Check
270         Coverage
271         Desugar
272         DsArrows
273         DsBinds
274         DsCCall
275         DsExpr
276         DsForeign
277         DsGRHSs
278         DsListComp
279         DsMonad
280         DsUtils
281         Match
282         MatchCon
283         MatchLit
284         HsBinds
285         HsDecls
286         HsDoc
287         HsExpr
288         HsImpExp
289         HsLit
290         PlaceHolder
291         HsPat
292         HsSyn
293         HsTypes
294         HsUtils
295         BinIface
296         BuildTyCl
297         IfaceEnv
298         IfaceSyn
299         IfaceType
300         LoadIface
301         MkIface
302         TcIface
303         FlagChecker
304         Annotations
305         BreakArray
306         CmdLineParser
307         CodeOutput
308         Config
309         Constants
310         DriverMkDepend
311         DriverPhases
312         PipelineMonad
313         DriverPipeline
314         DynFlags
315         ErrUtils
316         Finder
317         GHC
318         GhcMake
319         GhcPlugins
320         DynamicLoading
321         HeaderInfo
322         HscMain
323         HscStats
324         HscTypes
325         InteractiveEval
326         InteractiveEvalTypes
327         PackageConfig
328         Packages
329         PlatformConstants
330         Plugins
331         TcPluginM
332         PprTyThing
333         StaticFlags
334         StaticPtrTable
335         SysTools
336         Elf
337         TidyPgm
338         Ctype
339         HaddockUtils
340         Lexer
341         OptCoercion
342         Parser
343         RdrHsSyn
344         ApiAnnotation
345         ForeignCall
346         PrelInfo
347         PrelNames
348         PrelRules
349         PrimOp
350         TysPrim
351         TysWiredIn
352         CostCentre
353         ProfInit
354         SCCfinal
355         RnBinds
356         RnEnv
357         RnExpr
358         RnHsDoc
359         RnNames
360         RnPat
361         RnSource
362         RnSplice
363         RnTypes
364         CoreMonad
365         CSE
366         FloatIn
367         FloatOut
368         LiberateCase
369         OccurAnal
370         SAT
371         SetLevels
372         SimplCore
373         SimplEnv
374         SimplMonad
375         SimplUtils
376         Simplify
377         SimplStg
378         StgStats
379         UnariseStg
380         Rules
381         SpecConstr
382         Specialise
383         CoreToStg
384         StgLint
385         StgSyn
386         CallArity
387         DmdAnal
388         WorkWrap
389         WwLib
390         FamInst
391         Inst
392         TcAnnotations
393         TcArrows
394         TcBinds
395         TcClassDcl
396         TcDefaults
397         TcDeriv
398         TcEnv
399         TcExpr
400         TcForeign
401         TcGenDeriv
402         TcGenGenerics
403         TcHsSyn
404         TcHsType
405         TcInstDcls
406         TcMType
407         TcValidity
408         TcMatches
409         TcPat
410         TcPatSyn
411         TcRnDriver
412         TcRnMonad
413         TcRnTypes
414         TcRules
415         TcSimplify
416         TcErrors
417         TcTyClsDecls
418         TcTyDecls
419         TcTypeable
420         TcType
421         TcEvidence
422         TcUnify
423         TcInteract
424         TcCanonical
425         TcFlatten
426         TcSMonad
427         TcTypeNats
428         TcSplice
429         Class
430         Coercion
431         DsMeta
432         THNames
433         FamInstEnv
434         FunDeps
435         InstEnv
436         TyCon
437         CoAxiom
438         Kind
439         Type
440         TypeRep
441         Unify
442         Bag
443         Binary
444         BooleanFormula
445         BufWrite
446         Digraph
447         Encoding
448         FastFunctions
449         FastMutInt
450         FastString
451         FastStringEnv
452         Fingerprint
453         FiniteMap
454         GraphBase
455         GraphColor
456         GraphOps
457         GraphPpr
458         IOEnv
459         ListSetOps
460         Maybes
461         MonadUtils
462         OrdList
463         Outputable
464         Pair
465         Panic
466         Pretty
467         Serialized
468         State
469         Stream
470         StringBuffer
471         UniqDFM
472         UniqDSet
473         UniqFM
474         UniqSet
475         Util
476         Vectorise.Builtins.Base
477         Vectorise.Builtins.Initialise
478         Vectorise.Builtins
479         Vectorise.Monad.Base
480         Vectorise.Monad.Naming
481         Vectorise.Monad.Local
482         Vectorise.Monad.Global
483         Vectorise.Monad.InstEnv
484         Vectorise.Monad
485         Vectorise.Utils.Base
486         Vectorise.Utils.Closure
487         Vectorise.Utils.Hoisting
488         Vectorise.Utils.PADict
489         Vectorise.Utils.Poly
490         Vectorise.Utils
491         Vectorise.Generic.Description
492         Vectorise.Generic.PAMethods
493         Vectorise.Generic.PADict
494         Vectorise.Generic.PData
495         Vectorise.Type.Env
496         Vectorise.Type.Type
497         Vectorise.Type.TyConDecl
498         Vectorise.Type.Classify
499         Vectorise.Convert
500         Vectorise.Vect
501         Vectorise.Var
502         Vectorise.Env
503         Vectorise.Exp
504         Vectorise
505         Hoopl.Dataflow
506         Hoopl
507 --        CgInfoTbls used in ghci/DebuggerUtils
508 --        CgHeapery  mkVirtHeapOffsets used in ghci
509
510     Exposed-Modules:
511             AsmCodeGen
512             TargetReg
513             NCGMonad
514             Instruction
515             Format
516             Reg
517             RegClass
518             PIC
519             Platform
520             CPrim
521             X86.Regs
522             X86.RegInfo
523             X86.Instr
524             X86.Cond
525             X86.Ppr
526             X86.CodeGen
527             PPC.Regs
528             PPC.RegInfo
529             PPC.Instr
530             PPC.Cond
531             PPC.Ppr
532             PPC.CodeGen
533             SPARC.Base
534             SPARC.Regs
535             SPARC.Imm
536             SPARC.AddrMode
537             SPARC.Cond
538             SPARC.Instr
539             SPARC.Stack
540             SPARC.ShortcutJump
541             SPARC.Ppr
542             SPARC.CodeGen
543             SPARC.CodeGen.Amode
544             SPARC.CodeGen.Base
545             SPARC.CodeGen.CondCode
546             SPARC.CodeGen.Gen32
547             SPARC.CodeGen.Gen64
548             SPARC.CodeGen.Sanity
549             SPARC.CodeGen.Expand
550             RegAlloc.Liveness
551             RegAlloc.Graph.Main
552             RegAlloc.Graph.Stats
553             RegAlloc.Graph.ArchBase
554             RegAlloc.Graph.ArchX86
555             RegAlloc.Graph.Coalesce
556             RegAlloc.Graph.Spill
557             RegAlloc.Graph.SpillClean
558             RegAlloc.Graph.SpillCost
559             RegAlloc.Graph.TrivColorable
560             RegAlloc.Linear.Main
561             RegAlloc.Linear.JoinToTargets
562             RegAlloc.Linear.State
563             RegAlloc.Linear.Stats
564             RegAlloc.Linear.FreeRegs
565             RegAlloc.Linear.StackMap
566             RegAlloc.Linear.Base
567             RegAlloc.Linear.X86.FreeRegs
568             RegAlloc.Linear.X86_64.FreeRegs
569             RegAlloc.Linear.PPC.FreeRegs
570             RegAlloc.Linear.SPARC.FreeRegs
571             Dwarf
572             Dwarf.Types
573             Dwarf.Constants
574
575     if flag(ghci)
576         Exposed-Modules:
577             Convert
578             ByteCodeAsm
579             ByteCodeGen
580             ByteCodeInstr
581             ByteCodeItbls
582             ByteCodeLink
583             Debugger
584             LibFFI
585             Linker
586             ObjLink
587             RtClosureInspect
588             DebuggerUtils