base.cabal 9.99 KB
Newer Older
1
cabal-version:  2.2
2
name:           base
3
version:        4.13.0.0
4
-- NOTE: Don't forget to update ./changelog.md
5

Oleg Grenrus's avatar
Oleg Grenrus committed
6
license:        BSD-3-Clause
7 8
license-file:   LICENSE
maintainer:     libraries@haskell.org
9
bug-reports:    https://gitlab.haskell.org/ghc/ghc/issues/new
10
synopsis:       Basic libraries
11
category:       Prelude
12
build-type:     Configure
ross's avatar
ross committed
13
description:
14
    This package contains the Standard Haskell "Prelude" and its support libraries,
15 16
    and a large collection of useful libraries ranging from data
    structures to parsing combinators and debugging utilities.
17

18
extra-tmp-files:
19
    autom4te.cache
20
    base.buildinfo
21 22 23 24 25
    config.log
    config.status
    include/EventConfig.h
    include/HsBaseConfig.h

Ross Paterson's avatar
Ross Paterson committed
26
extra-source-files:
27 28
    aclocal.m4
    base.buildinfo.in
29
    changelog.md
30 31 32 33 34 35 36 37 38
    config.guess
    config.sub
    configure
    configure.ac
    include/CTypes.h
    include/EventConfig.h.in
    include/HsBaseConfig.h.in
    include/ieee-flpt.h
    include/md5.h
39
    include/fs.h
40
    install-sh
41

42
source-repository head
43
    type:     git
44 45
    location: http://git.haskell.org/ghc.git
    subdir:   libraries/base
46

47 48
Flag integer-simple
    Description: Use integer-simple
49 50 51 52 53 54 55 56
    Manual: True
    Default: False

Flag integer-gmp
    Description: Use integer-gmp
    Manual: True
    Default: False

57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97
Library
    default-language: Haskell2010
    other-extensions:
        BangPatterns
        CApiFFI
        CPP
        ConstraintKinds
        DataKinds
        DeriveDataTypeable
        DeriveGeneric
        ExistentialQuantification
        ExplicitForAll
        FlexibleContexts
        FlexibleInstances
        FunctionalDependencies
        GADTs
        GeneralizedNewtypeDeriving
        KindSignatures
        MagicHash
        MultiParamTypeClasses
        NegativeLiterals
        NoImplicitPrelude
        NondecreasingIndentation
        OverloadedStrings
        ParallelArrays
        PolyKinds
        RankNTypes
        RecordWildCards
        RoleAnnotations
        Safe
        ScopedTypeVariables
        StandaloneDeriving
        Trustworthy
        TypeFamilies
        TypeOperators
        TypeSynonymInstances
        UnboxedTuples
        UndecidableInstances
        UnliftedFFITypes
        Unsafe

98
    build-depends: rts == 1.0, ghc-prim ^>= 0.5.1.0
99 100 101 102 103

    -- sanity-check to ensure exactly one flag is set
    if !((flag(integer-gmp) && !flag(integer-simple)) || (!flag(integer-gmp) && flag(integer-simple)))
        build-depends: invalid-cabal-flag-settings<0

104
    if flag(integer-simple)
105
        build-depends: integer-simple ^>= 0.1.1
106 107

    if flag(integer-gmp)
108
        build-depends: integer-gmp ^>= 1.0.1
109

110
    exposed-modules:
111 112 113 114 115 116 117 118 119
        Control.Applicative
        Control.Arrow
        Control.Category
        Control.Concurrent
        Control.Concurrent.Chan
        Control.Concurrent.MVar
        Control.Concurrent.QSem
        Control.Concurrent.QSemN
        Control.Exception
Ross Paterson's avatar
Ross Paterson committed
120
        Control.Exception.Base
121
        Control.Monad
122
        Control.Monad.Fail
123 124
        Control.Monad.Fix
        Control.Monad.Instances
125
        Control.Monad.IO.Class
126 127 128 129 130 131 132
        Control.Monad.ST
        Control.Monad.ST.Lazy
        Control.Monad.ST.Lazy.Safe
        Control.Monad.ST.Lazy.Unsafe
        Control.Monad.ST.Safe
        Control.Monad.ST.Strict
        Control.Monad.ST.Unsafe
133
        Control.Monad.Zip
134
        Data.Bifoldable
135
        Data.Bifunctor
136
        Data.Bitraversable
137 138 139
        Data.Bits
        Data.Bool
        Data.Char
Austin Seipp's avatar
Austin Seipp committed
140
        Data.Coerce
141 142 143 144 145 146
        Data.Complex
        Data.Data
        Data.Dynamic
        Data.Either
        Data.Eq
        Data.Fixed
147
        Data.Foldable
148 149
        Data.Function
        Data.Functor
150
        Data.Functor.Classes
151
        Data.Functor.Contravariant
152
        Data.Functor.Compose
153
        Data.Functor.Const
154
        Data.Functor.Identity
155 156
        Data.Functor.Product
        Data.Functor.Sum
157 158 159
        Data.IORef
        Data.Int
        Data.Ix
160
        Data.Kind
161
        Data.List
162
        Data.List.NonEmpty
163 164 165 166 167
        Data.Maybe
        Data.Monoid
        Data.Ord
        Data.Proxy
        Data.Ratio
168
        Data.Semigroup
169 170 171
        Data.STRef
        Data.STRef.Lazy
        Data.STRef.Strict
172
        Data.String
173
        Data.Traversable
174
        Data.Tuple
175
        Data.Type.Bool
176
        Data.Type.Coercion
177 178 179 180
        Data.Type.Equality
        Data.Typeable
        Data.Unique
        Data.Version
181
        Data.Void
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206
        Data.Word
        Debug.Trace
        Foreign
        Foreign.C
        Foreign.C.Error
        Foreign.C.String
        Foreign.C.Types
        Foreign.Concurrent
        Foreign.ForeignPtr
        Foreign.ForeignPtr.Safe
        Foreign.ForeignPtr.Unsafe
        Foreign.Marshal
        Foreign.Marshal.Alloc
        Foreign.Marshal.Array
        Foreign.Marshal.Error
        Foreign.Marshal.Pool
        Foreign.Marshal.Safe
        Foreign.Marshal.Unsafe
        Foreign.Marshal.Utils
        Foreign.Ptr
        Foreign.Safe
        Foreign.StablePtr
        Foreign.Storable
        GHC.Arr
        GHC.Base
Ben Gamari's avatar
Ben Gamari committed
207
        GHC.ByteOrder
208
        GHC.Char
209
        GHC.Clock
210 211 212 213 214 215 216 217 218 219 220
        GHC.Conc
        GHC.Conc.IO
        GHC.Conc.Signal
        GHC.Conc.Sync
        GHC.ConsoleHandler
        GHC.Constants
        GHC.Desugar
        GHC.Enum
        GHC.Environment
        GHC.Err
        GHC.Exception
221
        GHC.Exception.Type
222 223
        GHC.ExecutionStack
        GHC.ExecutionStack.Internal
224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251
        GHC.Exts
        GHC.Fingerprint
        GHC.Fingerprint.Type
        GHC.Float
        GHC.Float.ConversionUtils
        GHC.Float.RealFracMethods
        GHC.Foreign
        GHC.ForeignPtr
        GHC.GHCi
        GHC.Generics
        GHC.IO
        GHC.IO.Buffer
        GHC.IO.BufferedIO
        GHC.IO.Device
        GHC.IO.Encoding
        GHC.IO.Encoding.CodePage
        GHC.IO.Encoding.Failure
        GHC.IO.Encoding.Iconv
        GHC.IO.Encoding.Latin1
        GHC.IO.Encoding.Types
        GHC.IO.Encoding.UTF16
        GHC.IO.Encoding.UTF32
        GHC.IO.Encoding.UTF8
        GHC.IO.Exception
        GHC.IO.FD
        GHC.IO.Handle
        GHC.IO.Handle.FD
        GHC.IO.Handle.Internals
252
        GHC.IO.Handle.Lock
253 254 255
        GHC.IO.Handle.Text
        GHC.IO.Handle.Types
        GHC.IO.IOMode
256
        GHC.IO.Unsafe
257 258 259 260
        GHC.IOArray
        GHC.IORef
        GHC.Int
        GHC.List
261
        GHC.Maybe
262
        GHC.MVar
263
        GHC.Natural
264
        GHC.Num
265
        GHC.OldList
Adam Gundry's avatar
Adam Gundry committed
266
        GHC.OverloadedLabels
267 268 269 270 271
        GHC.Pack
        GHC.Profiling
        GHC.Ptr
        GHC.Read
        GHC.Real
272
        GHC.Records
273
        GHC.ResponseFile
274
        GHC.RTS.Flags
275
        GHC.ST
Facundo Domínguez's avatar
Facundo Domínguez committed
276
        GHC.StaticPtr
277 278 279
        GHC.STRef
        GHC.Show
        GHC.Stable
280
        GHC.StableName
281
        GHC.Stack
282
        GHC.Stack.CCS
Ben Gamari's avatar
Ben Gamari committed
283
        GHC.Stack.Types
284 285 286 287
        GHC.Stats
        GHC.Storable
        GHC.TopHandler
        GHC.TypeLits
288
        GHC.TypeNats
289 290 291 292
        GHC.Unicode
        GHC.Weak
        GHC.Word
        Numeric
293
        Numeric.Natural
294 295
        Prelude
        System.CPUTime
296
        System.Console.GetOpt
297
        System.Environment
298
        System.Environment.Blank
299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315
        System.Exit
        System.IO
        System.IO.Error
        System.IO.Unsafe
        System.Info
        System.Mem
        System.Mem.StableName
        System.Mem.Weak
        System.Posix.Internals
        System.Posix.Types
        System.Timeout
        Text.ParserCombinators.ReadP
        Text.ParserCombinators.ReadPrec
        Text.Printf
        Text.Read
        Text.Read.Lex
        Text.Show
316
        Text.Show.Functions
Ben Gamari's avatar
Ben Gamari committed
317 318
        Type.Reflection
        Type.Reflection.Unsafe
319
        Unsafe.Coerce
320

321 322 323
    other-modules:
        Control.Monad.ST.Imp
        Control.Monad.ST.Lazy.Imp
324
        Data.Functor.Utils
325
        Data.OldList
326
        Data.Semigroup.Internal
Ben Gamari's avatar
Ben Gamari committed
327
        Data.Typeable.Internal
328
        Foreign.ForeignPtr.Imp
329
        GHC.StaticPtr.Internal
330
        System.Environment.ExecutablePath
Ben Gamari's avatar
Ben Gamari committed
331
        System.CPUTime.Utils
332

333
    c-sources:
334
        cbits/DarwinUtils.c
335
        cbits/PrelIOUtils.c
336
        cbits/SetEnv.c
337 338 339
        cbits/WCsubst.c
        cbits/Win32Utils.c
        cbits/consUtils.c
kili's avatar
kili committed
340
        cbits/iconv.c
341
        cbits/inputReady.c
Simon Marlow's avatar
Simon Marlow committed
342
        cbits/md5.c
343
        cbits/primFloat.c
344
        cbits/sysconf.c
345
        cbits/fs.c
346

Moritz Angermann's avatar
Moritz Angermann committed
347 348 349
    cmm-sources:
        cbits/CastFloatWord.cmm

350
    include-dirs: include
351 352 353 354 355 356 357 358 359
    includes:
        HsBase.h
    install-includes:
        HsBase.h
        WCsubst.h
        consUtils.h

    -- OS Specific
    if os(windows)
360 361 362 363 364 365 366 367
        -- Windows requires some extra libraries for linking because the RTS
        -- is no longer re-exporting them.
        -- msvcrt: standard C library. The RTS will automatically include this,
        --         but is added for completeness.
        -- mingwex: provides C99 compatibility. libm is a stub on MingW.
        -- mingw32: Unfortunately required because of a resource leak between
        --          mingwex and mingw32. the __math_err symbol is defined in
        --          mingw32 which is required by mingwex.
368 369
        -- shlwapi: provides PathFileExistsW
        extra-libraries: wsock32, user32, shell32, msvcrt, mingw32, mingwex, shlwapi
370 371 372 373 374
        exposed-modules:
            GHC.IO.Encoding.CodePage.API
            GHC.IO.Encoding.CodePage.Table
            GHC.Conc.Windows
            GHC.Windows
Ben Gamari's avatar
Ben Gamari committed
375 376
        other-modules:
            System.CPUTime.Windows
377
    else
Simon Marlow's avatar
Simon Marlow committed
378
        exposed-modules:
Ian Lynagh's avatar
Ian Lynagh committed
379
            GHC.Event
Simon Marlow's avatar
Simon Marlow committed
380
        other-modules:
bos's avatar
bos committed
381
            GHC.Event.Arr
Ian Lynagh's avatar
Ian Lynagh committed
382 383 384
            GHC.Event.Array
            GHC.Event.Control
            GHC.Event.EPoll
bos's avatar
bos committed
385
            GHC.Event.IntTable
Ian Lynagh's avatar
Ian Lynagh committed
386 387 388 389 390 391
            GHC.Event.Internal
            GHC.Event.KQueue
            GHC.Event.Manager
            GHC.Event.PSQ
            GHC.Event.Poll
            GHC.Event.Thread
392
            GHC.Event.TimerManager
Ian Lynagh's avatar
Ian Lynagh committed
393
            GHC.Event.Unique
394

Ben Gamari's avatar
Ben Gamari committed
395 396 397 398 399
            System.CPUTime.Posix.ClockGetTime
            System.CPUTime.Posix.Times
            System.CPUTime.Posix.RUsage
            System.CPUTime.Unsupported

400
    -- We need to set the unit id to base (without a version number)
401
    -- as it's magic.
402
    ghc-options: -this-unit-id base
403 404 405

    -- Make sure we don't accidentally regress into anti-patterns
    ghc-options: -Wcompat -Wnoncanonical-monad-instances