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