ghc.cabal.in 13.5 KB
Newer Older
Ian Lynagh's avatar
Ian Lynagh committed
1 2 3
-- WARNING: ghc.cabal is automatically generated from ghc.cabal.in by
-- ./configure.  Make sure you are editing ghc.cabal.in, not ghc.cabal.

4
Name: ghc
5
Version: @ProjectVersionMunged@
6
License: BSD3
7
License-File: LICENSE
8
Author: The GHC Team
9 10
Maintainer: glasgow-haskell-users@haskell.org
Homepage: http://www.haskell.org/ghc/
11
Synopsis: The GHC API
12
Description:
13 14 15 16 17 18 19
    GHC's functionality can be useful for more things than just
    compiling Haskell programs. Important use cases are programs
    that analyse (and perhaps transform) Haskell code. Others
    include loading Haskell code dynamically in a GHCi-like manner.
    For this reason, a lot of GHC's functionality is made available
    through this package.
Category: Development
20
Build-Type: Simple
21
Cabal-Version: >=1.10
22 23 24

Flag ghci
    Description: Build GHCi support.
25 26
    Default: False
    Manual: True
27 28 29

Flag stage1
    Description: Is this stage 1?
Ian Lynagh's avatar
Ian Lynagh committed
30
    Default: False
31
    Manual: True
Ian Lynagh's avatar
Ian Lynagh committed
32 33 34 35

Flag stage2
    Description: Is this stage 2?
    Default: False
36
    Manual: True
Ian Lynagh's avatar
Ian Lynagh committed
37 38 39 40

Flag stage3
    Description: Is this stage 3?
    Default: False
41
    Manual: True
42

Rufflewind's avatar
Rufflewind committed
43 44 45 46 47
Flag terminfo
    Description: Build GHC with terminfo support on non-Windows platforms.
    Default: True
    Manual: True

48
Library
49
    Default-Language: Haskell2010
50 51
    Exposed: False

52
    Build-Depends: base       >= 4.9 && < 5,
53
                   deepseq    >= 1.4 && < 1.5,
Ben Gamari's avatar
Ben Gamari committed
54
                   directory  >= 1   && < 1.4,
Ben Gamari's avatar
Ben Gamari committed
55
                   process    >= 1   && < 1.7,
Ian Lynagh's avatar
Ian Lynagh committed
56
                   bytestring >= 0.9 && < 0.11,
57
                   binary     == 0.8.*,
Ben Gamari's avatar
Ben Gamari committed
58
                   time       >= 1.4 && < 1.9,
Joachim Breitner's avatar
Joachim Breitner committed
59
                   containers >= 0.5 && < 0.6,
60
                   array      >= 0.1 && < 0.6,
61
                   filepath   >= 1   && < 1.5,
Ryan Scott's avatar
Ryan Scott committed
62
                   template-haskell == 2.13.*,
63 64 65
                   hpc        == 0.6.*,
                   transformers == 0.5.*,
                   ghc-boot   == @ProjectVersionMunged@,
66
                   ghc-boot-th == @ProjectVersionMunged@,
67
                   ghci == @ProjectVersionMunged@
Ian Lynagh's avatar
Ian Lynagh committed
68

69
    if os(windows)
70
        Build-Depends: Win32  >= 2.3 && < 2.7
71
    else
Rufflewind's avatar
Rufflewind committed
72 73
        if flag(terminfo)
            Build-Depends: terminfo == 0.4.*
74
        Build-Depends: unix   == 2.7.*
75

76 77 78
    GHC-Options: -Wall
                 -Wno-name-shadowing
                 -Wnoncanonical-monad-instances
79
                 -Wnoncanonical-monadfail-instances
80
                 -Wnoncanonical-monoid-instances
81 82 83

    if flag(ghci)
        CPP-Options: -DGHCI
84
        Include-Dirs: ../rts/dist/build @FFIIncludeDir@
85

86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113
    Other-Extensions:
        BangPatterns
        CPP
        DataKinds
        DeriveDataTypeable
        DeriveFoldable
        DeriveFunctor
        DeriveTraversable
        DisambiguateRecordFields
        ExplicitForAll
        FlexibleContexts
        FlexibleInstances
        GADTs
        GeneralizedNewtypeDeriving
        MagicHash
        MultiParamTypeClasses
        NamedFieldPuns
        NondecreasingIndentation
        RankNTypes
        RecordWildCards
        ScopedTypeVariables
        StandaloneDeriving
        Trustworthy
        TupleSections
        TypeFamilies
        TypeSynonymInstances
        UnboxedTuples
        UndecidableInstances
114 115 116

    Include-Dirs: . parser utils

117
    -- We need to set the unit id to ghc (without a version number)
118 119
    -- as it's magic.
    GHC-Options: -this-unit-id ghc
120

121 122 123
    if flag(stage1)
        Include-Dirs: stage1
    else
Ian Lynagh's avatar
Ian Lynagh committed
124 125 126 127 128 129
        if flag(stage2)
            Include-Dirs: stage2
        else
            if flag(stage3)
                Include-Dirs: stage2

130 131 132 133
    Install-Includes: HsVersions.h, ghc_boot_platform.h

    c-sources:
        parser/cutils.c
134
        ghci/keepCAFsForGHCi.c
135
        cbits/genSym.c
136 137

    hs-source-dirs:
Edward Z. Yang's avatar
Edward Z. Yang committed
138
        backpack
139 140 141 142 143 144 145 146
        basicTypes
        cmm
        codeGen
        coreSyn
        deSugar
        ghci
        hsSyn
        iface
147
        llvmGen
148
        main
149
        nativeGen
150 151 152 153 154 155 156 157 158 159 160 161 162 163
        parser
        prelude
        profiling
        rename
        simplCore
        simplStg
        specialise
        stgSyn
        stranal
        typecheck
        types
        utils
        vectorise

164 165 166 167 168 169 170
    -- we use an explicit Prelude
    Default-Extensions:
        NoImplicitPrelude

    Other-Modules:
        GhcPrelude

171
    Exposed-Modules:
Moritz Angermann's avatar
Moritz Angermann committed
172
        Ar
Douglas Wilson's avatar
Douglas Wilson committed
173
        FileCleanup
Edward Z. Yang's avatar
Edward Z. Yang committed
174 175 176 177
        DriverBkp
        BkpSyn
        NameShape
        RnModIface
178
        Avail
179
        AsmUtils
180
        BasicTypes
Gergő Érdi's avatar
Gergő Érdi committed
181
        ConLike
182
        DataCon
Gergő Érdi's avatar
Gergő Érdi committed
183
        PatSyn
184
        Demand
185
        Debug
186
        Exception
Adam Gundry's avatar
Adam Gundry committed
187
        FieldLabel
188
        GhcMonad
189
        Hooks
190 191
        Id
        IdInfo
192
        Lexeme
193
        Literal
194 195
        Llvm
        Llvm.AbsSyn
196
        Llvm.MetaData
197 198 199 200 201 202 203 204
        Llvm.PpLlvm
        Llvm.Types
        LlvmCodeGen
        LlvmCodeGen.Base
        LlvmCodeGen.CodeGen
        LlvmCodeGen.Data
        LlvmCodeGen.Ppr
        LlvmCodeGen.Regs
205
        LlvmMangler
206 207 208 209 210 211 212
        MkId
        Module
        Name
        NameEnv
        NameSet
        OccName
        RdrName
213
        NameCache
214 215 216 217 218 219
        SrcLoc
        UniqSupply
        Unique
        Var
        VarEnv
        VarSet
Joachim Breitner's avatar
Joachim Breitner committed
220
        UnVarGraph
221 222 223
        BlockId
        CLabel
        Cmm
224
        CmmBuildInfoTables
Edward Z. Yang's avatar
Edward Z. Yang committed
225
        CmmPipeline
226
        CmmCallConv
227
        CmmCommonBlockElim
228
        CmmImplementSwitchPlans
229 230 231 232 233 234
        CmmContFlowOpt
        CmmExpr
        CmmInfo
        CmmLex
        CmmLint
        CmmLive
235
        CmmMachOp
236
        CmmMonad
237
        CmmSwitch
238
        CmmNode
239 240 241
        CmmOpt
        CmmParse
        CmmProcPoint
242
        CmmSink
243
        CmmType
244
        CmmUtils
Simon Marlow's avatar
Simon Marlow committed
245
        CmmLayoutStack
246
        EnumSet
247
        MkGraph
248
        PprBase
249 250
        PprC
        PprCmm
251 252
        PprCmmDecl
        PprCmmExpr
253
        Bitmap
254
        CodeGen.Platform
255
        CodeGen.Platform.ARM
256
        CodeGen.Platform.ARM64
257 258 259 260 261 262
        CodeGen.Platform.NoRegs
        CodeGen.Platform.PPC
        CodeGen.Platform.PPC_Darwin
        CodeGen.Platform.SPARC
        CodeGen.Platform.X86
        CodeGen.Platform.X86_64
263
        CgUtils
264 265 266 267 268 269 270 271 272
        StgCmm
        StgCmmBind
        StgCmmClosure
        StgCmmCon
        StgCmmEnv
        StgCmmExpr
        StgCmmForeign
        StgCmmHeap
        StgCmmHpc
nfrisby's avatar
nfrisby committed
273
        StgCmmArgRep
274 275 276 277 278 279
        StgCmmLayout
        StgCmmMonad
        StgCmmPrim
        StgCmmProf
        StgCmmTicky
        StgCmmUtils
280
        StgCmmExtCode
281
        SMRep
282
        CoreArity
283 284 285 286
        CoreFVs
        CoreLint
        CorePrep
        CoreSubst
287
        CoreOpt
288
        CoreSyn
Simon Peyton Jones's avatar
Simon Peyton Jones committed
289
        TrieMap
290 291 292
        CoreTidy
        CoreUnfold
        CoreUtils
293
        CoreSeq
294
        CoreStats
295
        MkCore
296
        PprCore
297 298
        PmExpr
        TmOracle
299 300 301 302 303 304 305 306 307 308 309
        Check
        Coverage
        Desugar
        DsArrows
        DsBinds
        DsCCall
        DsExpr
        DsForeign
        DsGRHSs
        DsListComp
        DsMonad
310
        DsUsage
311 312 313 314 315 316 317 318 319 320
        DsUtils
        Match
        MatchCon
        MatchLit
        HsBinds
        HsDecls
        HsDoc
        HsExpr
        HsImpExp
        HsLit
321
        PlaceHolder
322
        HsExtension
323 324 325 326
        HsPat
        HsSyn
        HsTypes
        HsUtils
327
        HsDumpAst
328
        BinIface
329
        BinFingerprint
330 331 332 333
        BuildTyCl
        IfaceEnv
        IfaceSyn
        IfaceType
Ben Gamari's avatar
Ben Gamari committed
334
        ToIface
335 336 337
        LoadIface
        MkIface
        TcIface
338
        FlagChecker
339
        Annotations
340 341 342 343 344 345
        CmdLineParser
        CodeOutput
        Config
        Constants
        DriverMkDepend
        DriverPhases
346
        PipelineMonad
347 348 349 350 351
        DriverPipeline
        DynFlags
        ErrUtils
        Finder
        GHC
352
        GhcMake
353 354
        GhcPlugins
        DynamicLoading
355 356 357 358 359
        HeaderInfo
        HscMain
        HscStats
        HscTypes
        InteractiveEval
360
        InteractiveEvalTypes
361 362
        PackageConfig
        Packages
363
        PlatformConstants
Adam Gundry's avatar
Adam Gundry committed
364 365
        Plugins
        TcPluginM
366
        PprTyThing
Facundo Domínguez's avatar
Facundo Domínguez committed
367
        StaticPtrTable
368
        SysTools
369
        SysTools.BaseDir
370
        SysTools.Terminal
Tamar Christina's avatar
Tamar Christina committed
371 372 373 374
        SysTools.ExtraObj
        SysTools.Info
        SysTools.Process
        SysTools.Tasks
375
        Elf
376 377 378 379
        TidyPgm
        Ctype
        HaddockUtils
        Lexer
380
        OptCoercion
381 382
        Parser
        RdrHsSyn
Alan Zimmerman's avatar
Alan Zimmerman committed
383
        ApiAnnotation
384
        ForeignCall
385
        KnownUniques
386 387 388 389 390 391 392
        PrelInfo
        PrelNames
        PrelRules
        PrimOp
        TysPrim
        TysWiredIn
        CostCentre
393
        ProfInit
394 395 396 397 398 399 400
        RnBinds
        RnEnv
        RnExpr
        RnHsDoc
        RnNames
        RnPat
        RnSource
401
        RnSplice
402
        RnTypes
403 404 405
        RnFixity
        RnUtils
        RnUnbound
406
        CoreMonad
407 408 409 410 411 412 413 414 415 416 417 418 419 420
        CSE
        FloatIn
        FloatOut
        LiberateCase
        OccurAnal
        SAT
        SetLevels
        SimplCore
        SimplEnv
        SimplMonad
        SimplUtils
        Simplify
        SimplStg
        StgStats
421
        StgCse
422
        UnariseStg
423
        RepType
424 425 426 427 428 429
        Rules
        SpecConstr
        Specialise
        CoreToStg
        StgLint
        StgSyn
430
        CallArity
431
        DmdAnal
432
        Exitify
433 434 435 436
        WorkWrap
        WwLib
        FamInst
        Inst
437
        TcAnnotations
438 439
        TcArrows
        TcBinds
440
        TcSigs
441 442 443
        TcClassDcl
        TcDefaults
        TcDeriv
Ryan Scott's avatar
Ryan Scott committed
444 445
        TcDerivInfer
        TcDerivUtils
446 447 448 449
        TcEnv
        TcExpr
        TcForeign
        TcGenDeriv
Ryan Scott's avatar
Ryan Scott committed
450
        TcGenFunctor
451
        TcGenGenerics
452 453 454 455
        TcHsSyn
        TcHsType
        TcInstDcls
        TcMType
456
        TcValidity
457 458
        TcMatches
        TcPat
Gergő Érdi's avatar
Gergő Érdi committed
459
        TcPatSyn
460
        TcRnDriver
Edward Z. Yang's avatar
Edward Z. Yang committed
461
        TcBackpack
462
        TcRnExports
463 464 465 466
        TcRnMonad
        TcRnTypes
        TcRules
        TcSimplify
467
        TcErrors
468 469
        TcTyClsDecls
        TcTyDecls
470
        TcTypeable
471
        TcType
472
        TcEvidence
473
        TcUnify
474 475
        TcInteract
        TcCanonical
476
        TcFlatten
477
        TcSMonad
478
        TcTypeNats
479
        TcSplice
480 481
        Class
        Coercion
482 483
        DsMeta
        THNames
484 485 486 487
        FamInstEnv
        FunDeps
        InstEnv
        TyCon
488
        CoAxiom
489
        Kind
490
        Type
491
        TyCoRep
492 493 494
        Unify
        Bag
        Binary
495
        BooleanFormula
496 497 498 499 500 501
        BufWrite
        Digraph
        Encoding
        FastFunctions
        FastMutInt
        FastString
Adam Gundry's avatar
Adam Gundry committed
502
        FastStringEnv
503 504
        Fingerprint
        FiniteMap
505
        FV
506 507 508 509 510
        GraphBase
        GraphColor
        GraphOps
        GraphPpr
        IOEnv
511
        Json
512
        ListSetOps
513
        ListT
514 515 516 517
        Maybes
        MonadUtils
        OrdList
        Outputable
518
        Pair
519
        Panic
Rufflewind's avatar
Rufflewind committed
520
        PprColour
521 522
        Pretty
        State
523
        Stream
524
        StringBuffer
525
        UniqDFM
526 527
        UniqDSet
        UniqFM
Edward Z. Yang's avatar
Edward Z. Yang committed
528
        UniqMap
529 530
        UniqSet
        Util
531
        Vectorise.Builtins.Base
532 533 534 535 536 537 538 539
        Vectorise.Builtins.Initialise
        Vectorise.Builtins
        Vectorise.Monad.Base
        Vectorise.Monad.Naming
        Vectorise.Monad.Local
        Vectorise.Monad.Global
        Vectorise.Monad.InstEnv
        Vectorise.Monad
540 541 542 543 544 545
        Vectorise.Utils.Base
        Vectorise.Utils.Closure
        Vectorise.Utils.Hoisting
        Vectorise.Utils.PADict
        Vectorise.Utils.Poly
        Vectorise.Utils
546 547 548
        Vectorise.Generic.Description
        Vectorise.Generic.PAMethods
        Vectorise.Generic.PADict
549
        Vectorise.Generic.PData
550 551 552 553 554 555 556 557 558
        Vectorise.Type.Env
        Vectorise.Type.Type
        Vectorise.Type.TyConDecl
        Vectorise.Type.Classify
        Vectorise.Convert
        Vectorise.Vect
        Vectorise.Var
        Vectorise.Env
        Vectorise.Exp
559
        Vectorise
560 561
        Hoopl.Block
        Hoopl.Collections
Simon Marlow's avatar
Simon Marlow committed
562
        Hoopl.Dataflow
563 564 565
        Hoopl.Graph
        Hoopl.Label
        Hoopl.Unique
Simon Marlow's avatar
Simon Marlow committed
566 567 568
--        CgInfoTbls used in ghci/DebuggerUtils
--        CgHeapery  mkVirtHeapOffsets used in ghci

569
    Exposed-Modules:
570
            AsmCodeGen
571 572 573
            TargetReg
            NCGMonad
            Instruction
574
            Format
575 576 577 578
            Reg
            RegClass
            PIC
            Platform
tibbe's avatar
tibbe committed
579
            CPrim
580
            X86.Regs
581
            X86.RegInfo
582
            X86.Instr
583
            X86.Cond
584
            X86.Ppr
585
            X86.CodeGen
586
            PPC.Regs
587
            PPC.RegInfo
588
            PPC.Instr
589
            PPC.Cond
590
            PPC.Ppr
591
            PPC.CodeGen
592
            SPARC.Base
593
            SPARC.Regs
594
            SPARC.Imm
Simon Marlow's avatar
Simon Marlow committed
595
            SPARC.AddrMode
596
            SPARC.Cond
597
            SPARC.Instr
Simon Marlow's avatar
Simon Marlow committed
598
            SPARC.Stack
599
            SPARC.ShortcutJump
600
            SPARC.Ppr
601
            SPARC.CodeGen
602 603 604 605 606
            SPARC.CodeGen.Amode
            SPARC.CodeGen.Base
            SPARC.CodeGen.CondCode
            SPARC.CodeGen.Gen32
            SPARC.CodeGen.Gen64
607
            SPARC.CodeGen.Sanity
608
            SPARC.CodeGen.Expand
609
            RegAlloc.Liveness
610 611 612 613 614 615 616 617
            RegAlloc.Graph.Main
            RegAlloc.Graph.Stats
            RegAlloc.Graph.ArchBase
            RegAlloc.Graph.ArchX86
            RegAlloc.Graph.Coalesce
            RegAlloc.Graph.Spill
            RegAlloc.Graph.SpillClean
            RegAlloc.Graph.SpillCost
618
            RegAlloc.Graph.TrivColorable
619 620 621 622 623 624 625 626
            RegAlloc.Linear.Main
            RegAlloc.Linear.JoinToTargets
            RegAlloc.Linear.State
            RegAlloc.Linear.Stats
            RegAlloc.Linear.FreeRegs
            RegAlloc.Linear.StackMap
            RegAlloc.Linear.Base
            RegAlloc.Linear.X86.FreeRegs
ian@well-typed.com's avatar
ian@well-typed.com committed
627
            RegAlloc.Linear.X86_64.FreeRegs
628 629
            RegAlloc.Linear.PPC.FreeRegs
            RegAlloc.Linear.SPARC.FreeRegs
Peter Wortmann's avatar
Peter Wortmann committed
630 631 632
            Dwarf
            Dwarf.Types
            Dwarf.Constants
633
            Convert
634
            ByteCodeTypes
635 636 637 638 639 640 641 642
            ByteCodeAsm
            ByteCodeGen
            ByteCodeInstr
            ByteCodeItbls
            ByteCodeLink
            Debugger
            Linker
            RtClosureInspect
643
            DebuggerUtils
644
            GHCi