Add (a) CoreM monad, (b) new Annotations feature
[ghc-hetmet.git] / compiler / ghc.cabal.in
1 Name: ghc
2 Version: @ProjectVersion@
3 License: BSD3
4 License-File: ../LICENSE
5 Author: The GHC Team
6 Maintainer: glasgow-haskell-users@haskell.org
7 Homepage: http://www.haskell.org/ghc/
8 Synopsis: The GHC API
9 Description:
10     GHC's functionality can be useful for more things than just
11     compiling Haskell programs. Important use cases are programs
12     that analyse (and perhaps transform) Haskell code. Others
13     include loading Haskell code dynamically in a GHCi-like manner.
14     For this reason, a lot of GHC's functionality is made available
15     through this package.
16 Category: Development
17 Build-Type: Simple
18 Cabal-Version: >= 1.2
19
20 Flag base4
21     Description: Choose the even newer, even smaller, split-up base package.
22
23 Flag base3
24     Description: Choose the new smaller, split-up base package.
25
26 Flag dynlibs
27     Description: Dynamic library support
28     Default: False
29     Manual: True
30
31 Flag editline
32     Description: Use editline
33     Default: False
34     Manual: True
35
36 Flag ghci
37     Description: Build GHCi support.
38     Default: False
39     Manual: True
40
41 Flag ncg
42     Description: Build the NCG.
43     Default: False
44     Manual: True
45
46 Flag stage1
47     Description: Is this stage 1?
48
49 Library
50     Exposed: False
51
52     if flag(base4)
53         Build-Depends: base       >= 4   && < 5
54     if flag(base3)
55         Build-Depends: base       >= 3   && < 4
56     if !flag(base3) && !flag(base4)
57         Build-Depends: base       < 3
58
59     if flag(base3) || flag(base4)
60         Build-Depends: directory  >= 1   && < 1.1,
61                        process    >= 1   && < 1.1,
62                        bytestring >= 0.9 && < 0.10,
63                        old-time   >= 1   && < 1.1,
64                        containers >= 0.1 && < 0.3,
65                        array      >= 0.1 && < 0.3
66
67     Build-Depends: filepath >= 1 && < 1.2
68     Build-Depends: haskell98, Cabal, hpc
69     if os(windows)
70         Build-Depends: Win32
71     else
72         Build-Depends: unix
73
74     if flag(editline)
75         Build-Depends: editline
76         CPP-Options: -DUSE_EDITLINE
77
78     GHC-Options: -Wall -fno-warn-name-shadowing -fno-warn-orphans
79
80     if flag(ghci)
81         Build-Depends: template-haskell
82         CPP-Options: -DGHCI
83         Include-Dirs: ../libffi/build/include
84
85     if !flag(ncg)
86         CPP-Options: -DOMIT_NATIVE_CODEGEN
87
88     -- GHC 6.4.2 needs to be able to find WCsubst.c, which needs to be
89     -- able to find WCsubst.h
90     Include-Dirs: ../libraries/base/cbits, ../libraries/base/include
91
92     Extensions: CPP, MagicHash, UnboxedTuples, PatternGuards,
93                 ForeignFunctionInterface, EmptyDataDecls,
94                 TypeSynonymInstances, MultiParamTypeClasses,
95                 FlexibleInstances, Rank2Types, ScopedTypeVariables,
96                 DeriveDataTypeable
97
98     Include-Dirs: . parser utils
99
100     if flag(stage1)
101         Include-Dirs: stage1
102         if impl(ghc < 6.9)
103             Build-Depends: extensible-exceptions
104             Extensions: PatternSignatures
105     else
106         Include-Dirs: stage2plus
107     Install-Includes: HsVersions.h, ghc_boot_platform.h
108
109     c-sources:
110         parser/cutils.c
111         utils/md5.c
112         -- For GHC < 6.5:
113         cbits/unicode.c
114
115     if flag(dynlibs)
116         c-sources:
117             ghci/keepCAFsForGHCi.c
118
119     hs-source-dirs:
120         basicTypes
121         cmm
122         codeGen
123         coreSyn
124         cprAnalysis
125         deSugar
126         ghci
127         hsSyn
128         iface
129         main
130         parser
131         prelude
132         profiling
133         rename
134         simplCore
135         simplStg
136         specialise
137         stgSyn
138         stranal
139         typecheck
140         types
141         utils
142         vectorise
143
144     Exposed-Modules:
145         BasicTypes
146         DataCon
147         Demand
148         Exception
149         Id
150         IdInfo
151         Literal
152         MkId
153         Module
154         Name
155         NameEnv
156         NameSet
157         NewDemand
158         OccName
159         RdrName
160         SrcLoc
161         UniqSupply
162         Unique
163         Var
164         VarEnv
165         VarSet
166         BlockId
167         CLabel
168         Cmm
169         CmmBrokenBlock
170         CmmCPS
171         CmmCPSGen
172         CmmCPSZ
173         CmmCallConv
174         CmmCommonBlockElimZ
175         CmmContFlowOpt
176         CmmCvt
177         CmmExpr
178         CmmInfo
179         CmmLex
180         CmmLint
181         CmmLive
182         CmmLiveZ
183         CmmOpt
184         CmmParse
185         CmmProcPoint
186         CmmProcPointZ
187         CmmSpillReload
188         CmmTx
189         CmmUtils
190         CmmZipUtil
191         DFMonad
192         Dataflow
193         MachOp
194         MkZipCfg
195         MkZipCfgCmm
196         OptimizationFuel
197         PprC
198         PprCmm
199         PprCmmZ
200         StackColor
201         StackPlacements
202         ZipCfg
203         ZipCfgCmmRep
204         ZipCfgExtras
205         ZipDataflow
206         Bitmap
207         CgBindery
208         CgCallConv
209         CgCase
210         CgClosure
211         CgCon
212         CgExpr
213         CgForeignCall
214         CgHeapery
215         CgHpc
216         CgInfoTbls
217         CgLetNoEscape
218         CgMonad
219         CgParallel
220         CgPrimOp
221         CgProf
222         CgStackery
223         CgTailCall
224         CgTicky
225         CgUtils
226         ClosureInfo
227         CodeGen
228         SMRep
229         CoreFVs
230         CoreLint
231         CorePrep
232         CoreSubst
233         CoreSyn
234         CoreTidy
235         CoreUnfold
236         CoreUtils
237         ExternalCore
238         MkCore
239         MkExternalCore
240         PprCore
241         PprExternalCore
242         CprAnalyse
243         Check
244         Coverage
245         Desugar
246         DsArrows
247         DsBinds
248         DsCCall
249         DsExpr
250         DsForeign
251         DsGRHSs
252         DsListComp
253         DsMonad
254         DsUtils
255         Match
256         MatchCon
257         MatchLit
258         HsBinds
259         HsDecls
260         HsDoc
261         HsExpr
262         HsImpExp
263         HsLit
264         HsPat
265         HsSyn
266         HsTypes
267         HsUtils
268         BinIface
269         BuildTyCl
270         IfaceEnv
271         IfaceSyn
272         IfaceType
273         LoadIface
274         MkIface
275         TcIface
276         Annotations
277         BreakArray
278         CmdLineParser
279         CodeOutput
280         Config
281         Constants
282         DriverMkDepend
283         DriverPhases
284         DriverPipeline
285         DynFlags
286         ErrUtils
287         Finder
288         GHC
289         HeaderInfo
290         HscMain
291         HscStats
292         HscTypes
293         InteractiveEval
294         PackageConfig
295         Packages
296         ParsePkgConf
297         PprTyThing
298         StaticFlags
299         StaticFlagParser
300         SysTools
301         TidyPgm
302         Ctype
303         HaddockLex
304         HaddockParse
305         HaddockUtils
306         LexCore
307         Lexer
308         Parser
309         ParserCore
310         ParserCoreUtils
311         RdrHsSyn
312         ForeignCall
313         PrelInfo
314         PrelNames
315         PrelRules
316         PrimOp
317         TysPrim
318         TysWiredIn
319         CostCentre
320         SCCfinal
321         RnBinds
322         RnEnv
323         RnExpr
324         RnHsDoc
325         RnHsSyn
326         RnNames
327         RnPat
328         RnSource
329         RnTypes
330         CoreMonad
331         CSE
332         FloatIn
333         FloatOut
334         LiberateCase
335         OccurAnal
336         SAT
337         SetLevels
338         SimplCore
339         SimplEnv
340         SimplMonad
341         SimplUtils
342         Simplify
343         SRT
344         SimplStg
345         StgStats
346         Rules
347         SpecConstr
348         Specialise
349         CoreToStg
350         StgLint
351         StgSyn
352         DmdAnal
353         SaAbsInt
354         SaLib
355         StrictAnal
356         WorkWrap
357         WwLib
358         FamInst
359         Inst
360         TcAnnotations
361         TcArrows
362         TcBinds
363         TcClassDcl
364         TcDefaults
365         TcDeriv
366         TcEnv
367         TcExpr
368         TcForeign
369         TcGenDeriv
370         TcHsSyn
371         TcHsType
372         TcInstDcls
373         TcMType
374         TcMatches
375         TcPat
376         TcRnDriver
377         TcRnMonad
378         TcRnTypes
379         TcRules
380         TcSimplify
381         TcTyClsDecls
382         TcTyDecls
383         TcTyFuns
384         TcType
385         TcUnify
386         Class
387         Coercion
388         FamInstEnv
389         FunDeps
390         Generics
391         InstEnv
392         TyCon
393         Type
394         TypeRep
395         Unify
396         Bag
397         Binary
398         BufWrite
399         Digraph
400         Encoding
401         FastBool
402         FastFunctions
403         FastMutInt
404         FastString
405         FastTypes
406         Fingerprint
407         FiniteMap
408         GraphBase
409         GraphColor
410         GraphOps
411         GraphPpr
412         IOEnv
413         Interval
414         LazyUniqFM
415         ListSetOps
416         Maybes
417         MonadUtils
418         OrdList
419         Outputable
420         Panic
421         Pretty
422         Serialized
423         State
424         StringBuffer
425         Unicode
426         UniqFM
427         UniqSet
428         Util
429         VectBuiltIn
430         VectCore
431         VectMonad
432         VectType
433         VectUtils
434         Vectorise
435
436     if flag(ncg)
437         hs-source-dirs:
438             nativeGen
439
440         Exposed-Modules:
441             AsmCodeGen
442             MachCodeGen
443             MachInstrs
444             MachRegs
445             NCGMonad
446             PositionIndependentCode
447             PprMach
448             RegAllocColor
449             RegAllocInfo
450             RegAllocLinear
451             RegAllocStats
452             RegArchBase
453             RegArchX86
454             RegCoalesce
455             RegLiveness
456             RegSpill
457             RegSpillClean
458             RegSpillCost
459
460     if flag(ghci)
461         Exposed-Modules:
462             DsMeta
463             TcSplice
464             Convert
465             ByteCodeAsm
466             ByteCodeFFI
467             ByteCodeGen
468             ByteCodeInstr
469             ByteCodeItbls
470             ByteCodeLink
471             Debugger
472             GhciMonad
473             GhciTags
474             InteractiveUI
475             LibFFI
476             Linker
477             ObjLink
478             RtClosureInspect
479