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