2b9d557490140d1821157cefbcd41ab7db455445
[ghc.git] / libraries / base / base.cabal
1 name:           base
2 version:        4.11.0.0
3 -- NOTE: Don't forget to update ./changelog.md
4 license:        BSD3
5 license-file:   LICENSE
6 maintainer:     libraries@haskell.org
7 bug-reports:    http://ghc.haskell.org/trac/ghc/newticket?component=libraries/base
8 synopsis:       Basic libraries
9 category:       Prelude
10 description:
11     This package contains the "Prelude" and its support libraries,
12     and a large collection of useful libraries ranging from data
13     structures to parsing combinators and debugging utilities.
14 cabal-version:  >=1.10
15 build-type:     Configure
16
17 extra-tmp-files:
18     autom4te.cache
19     base.buildinfo
20     config.log
21     config.status
22     include/EventConfig.h
23     include/HsBaseConfig.h
24
25 extra-source-files:
26     aclocal.m4
27     base.buildinfo.in
28     changelog.md
29     config.guess
30     config.sub
31     configure
32     configure.ac
33     include/CTypes.h
34     include/EventConfig.h.in
35     include/HsBaseConfig.h.in
36     include/ieee-flpt.h
37     include/md5.h
38     install-sh
39
40 source-repository head
41     type:     git
42     location: http://git.haskell.org/ghc.git
43     subdir:   libraries/base
44
45 Flag integer-simple
46     Description: Use integer-simple
47     Manual: True
48     Default: False
49
50 Flag integer-gmp
51     Description: Use integer-gmp
52     Manual: True
53     Default: False
54
55 Library
56     default-language: Haskell2010
57     other-extensions:
58         BangPatterns
59         CApiFFI
60         CPP
61         ConstraintKinds
62         DataKinds
63         DeriveDataTypeable
64         DeriveGeneric
65         ExistentialQuantification
66         ExplicitForAll
67         FlexibleContexts
68         FlexibleInstances
69         FunctionalDependencies
70         GADTs
71         GeneralizedNewtypeDeriving
72         KindSignatures
73         MagicHash
74         MultiParamTypeClasses
75         NegativeLiterals
76         NoImplicitPrelude
77         NondecreasingIndentation
78         OverloadedStrings
79         ParallelArrays
80         PolyKinds
81         RankNTypes
82         RecordWildCards
83         RoleAnnotations
84         Safe
85         ScopedTypeVariables
86         StandaloneDeriving
87         Trustworthy
88         TypeFamilies
89         TypeOperators
90         TypeSynonymInstances
91         UnboxedTuples
92         UndecidableInstances
93         UnliftedFFITypes
94         Unsafe
95
96     build-depends: rts == 1.0.*, ghc-prim == 0.5.*
97
98     -- sanity-check to ensure exactly one flag is set
99     if !((flag(integer-gmp) && !flag(integer-simple)) || (!flag(integer-gmp) && flag(integer-simple)))
100         build-depends: invalid-cabal-flag-settings<0
101
102     if flag(integer-simple)
103         build-depends: integer-simple >= 0.1.1 && < 0.2
104
105     if flag(integer-gmp)
106         build-depends: integer-gmp >= 1.0 && < 1.1
107         cpp-options: -DOPTIMISE_INTEGER_GCD_LCM
108
109     exposed-modules:
110         Control.Applicative
111         Control.Arrow
112         Control.Category
113         Control.Concurrent
114         Control.Concurrent.Chan
115         Control.Concurrent.MVar
116         Control.Concurrent.QSem
117         Control.Concurrent.QSemN
118         Control.Exception
119         Control.Exception.Base
120         Control.Monad
121         Control.Monad.Fail
122         Control.Monad.Fix
123         Control.Monad.Instances
124         Control.Monad.IO.Class
125         Control.Monad.ST
126         Control.Monad.ST.Lazy
127         Control.Monad.ST.Lazy.Safe
128         Control.Monad.ST.Lazy.Unsafe
129         Control.Monad.ST.Safe
130         Control.Monad.ST.Strict
131         Control.Monad.ST.Unsafe
132         Control.Monad.Zip
133         Data.Bifoldable
134         Data.Bifunctor
135         Data.Bitraversable
136         Data.Bits
137         Data.Bool
138         Data.Char
139         Data.Coerce
140         Data.Complex
141         Data.Data
142         Data.Dynamic
143         Data.Either
144         Data.Eq
145         Data.Fixed
146         Data.Foldable
147         Data.Function
148         Data.Functor
149         Data.Functor.Classes
150         Data.Functor.Compose
151         Data.Functor.Const
152         Data.Functor.Identity
153         Data.Functor.Product
154         Data.Functor.Sum
155         Data.IORef
156         Data.Int
157         Data.Ix
158         Data.Kind
159         Data.List
160         Data.List.NonEmpty
161         Data.Maybe
162         Data.Monoid
163         Data.Ord
164         Data.Proxy
165         Data.Ratio
166         Data.Semigroup
167         Data.STRef
168         Data.STRef.Lazy
169         Data.STRef.Strict
170         Data.String
171         Data.Traversable
172         Data.Tuple
173         Data.Type.Bool
174         Data.Type.Coercion
175         Data.Type.Equality
176         Data.Typeable
177         Data.Unique
178         Data.Version
179         Data.Void
180         Data.Word
181         Debug.Trace
182         Foreign
183         Foreign.C
184         Foreign.C.Error
185         Foreign.C.String
186         Foreign.C.Types
187         Foreign.Concurrent
188         Foreign.ForeignPtr
189         Foreign.ForeignPtr.Safe
190         Foreign.ForeignPtr.Unsafe
191         Foreign.Marshal
192         Foreign.Marshal.Alloc
193         Foreign.Marshal.Array
194         Foreign.Marshal.Error
195         Foreign.Marshal.Pool
196         Foreign.Marshal.Safe
197         Foreign.Marshal.Unsafe
198         Foreign.Marshal.Utils
199         Foreign.Ptr
200         Foreign.Safe
201         Foreign.StablePtr
202         Foreign.Storable
203         GHC.Arr
204         GHC.Base
205         GHC.ByteOrder
206         GHC.Char
207         GHC.Conc
208         GHC.Conc.IO
209         GHC.Conc.Signal
210         GHC.Conc.Sync
211         GHC.ConsoleHandler
212         GHC.Constants
213         GHC.Desugar
214         GHC.Enum
215         GHC.Environment
216         GHC.Err
217         GHC.Exception
218         GHC.ExecutionStack
219         GHC.ExecutionStack.Internal
220         GHC.Exts
221         GHC.Fingerprint
222         GHC.Fingerprint.Type
223         GHC.Float
224         GHC.Float.ConversionUtils
225         GHC.Float.RealFracMethods
226         GHC.Foreign
227         GHC.ForeignPtr
228         GHC.GHCi
229         GHC.Generics
230         GHC.IO
231         GHC.IO.Buffer
232         GHC.IO.BufferedIO
233         GHC.IO.Device
234         GHC.IO.Encoding
235         GHC.IO.Encoding.CodePage
236         GHC.IO.Encoding.Failure
237         GHC.IO.Encoding.Iconv
238         GHC.IO.Encoding.Latin1
239         GHC.IO.Encoding.Types
240         GHC.IO.Encoding.UTF16
241         GHC.IO.Encoding.UTF32
242         GHC.IO.Encoding.UTF8
243         GHC.IO.Exception
244         GHC.IO.FD
245         GHC.IO.Handle
246         GHC.IO.Handle.FD
247         GHC.IO.Handle.Internals
248         GHC.IO.Handle.Lock
249         GHC.IO.Handle.Text
250         GHC.IO.Handle.Types
251         GHC.IO.IOMode
252         GHC.IO.Unsafe
253         GHC.IOArray
254         GHC.IORef
255         GHC.Int
256         GHC.List
257         GHC.MVar
258         GHC.Natural
259         GHC.Num
260         GHC.OldList
261         GHC.OverloadedLabels
262         GHC.PArr
263         GHC.Pack
264         GHC.Profiling
265         GHC.Ptr
266         GHC.Read
267         GHC.Real
268         GHC.Records
269         GHC.RTS.Flags
270         GHC.ST
271         GHC.StaticPtr
272         GHC.STRef
273         GHC.Show
274         GHC.Stable
275         GHC.Stack
276         GHC.Stack.CCS
277         GHC.Stack.Types
278         GHC.Stats
279         GHC.Storable
280         GHC.TopHandler
281         GHC.TypeLits
282         GHC.TypeNats
283         GHC.Unicode
284         GHC.Weak
285         GHC.Word
286         Numeric
287         Numeric.Natural
288         Prelude
289         System.CPUTime
290         System.Console.GetOpt
291         System.Environment
292         System.Environment.Blank
293         System.Exit
294         System.IO
295         System.IO.Error
296         System.IO.Unsafe
297         System.Info
298         System.Mem
299         System.Mem.StableName
300         System.Mem.Weak
301         System.Posix.Internals
302         System.Posix.Types
303         System.Timeout
304         Text.ParserCombinators.ReadP
305         Text.ParserCombinators.ReadPrec
306         Text.Printf
307         Text.Read
308         Text.Read.Lex
309         Text.Show
310         Text.Show.Functions
311         Type.Reflection
312         Type.Reflection.Unsafe
313         Unsafe.Coerce
314
315     other-modules:
316         Control.Monad.ST.Imp
317         Control.Monad.ST.Lazy.Imp
318         Data.Functor.Utils
319         Data.OldList
320         Data.Semigroup.Internal
321         Data.Typeable.Internal
322         Foreign.ForeignPtr.Imp
323         GHC.StaticPtr.Internal
324         System.Environment.ExecutablePath
325         System.CPUTime.Utils
326
327     c-sources:
328         cbits/DarwinUtils.c
329         cbits/PrelIOUtils.c
330         cbits/SetEnv.c
331         cbits/WCsubst.c
332         cbits/Win32Utils.c
333         cbits/consUtils.c
334         cbits/iconv.c
335         cbits/inputReady.c
336         cbits/md5.c
337         cbits/primFloat.c
338         cbits/sysconf.c
339
340     include-dirs: include
341     includes:
342         HsBase.h
343     install-includes:
344         HsBase.h
345         WCsubst.h
346         consUtils.h
347
348     -- OS Specific
349     if os(windows)
350         -- Windows requires some extra libraries for linking because the RTS
351         -- is no longer re-exporting them.
352         -- msvcrt: standard C library. The RTS will automatically include this,
353         --         but is added for completeness.
354         -- mingwex: provides C99 compatibility. libm is a stub on MingW.
355         -- mingw32: Unfortunately required because of a resource leak between
356         --          mingwex and mingw32. the __math_err symbol is defined in
357         --          mingw32 which is required by mingwex.
358         extra-libraries: wsock32, user32, shell32, msvcrt, mingw32, mingwex
359         exposed-modules:
360             GHC.IO.Encoding.CodePage.API
361             GHC.IO.Encoding.CodePage.Table
362             GHC.Conc.Windows
363             GHC.Windows
364         other-modules:
365             System.CPUTime.Windows
366     else
367         exposed-modules:
368             GHC.Event
369         other-modules:
370             GHC.Event.Arr
371             GHC.Event.Array
372             GHC.Event.Clock
373             GHC.Event.Control
374             GHC.Event.EPoll
375             GHC.Event.IntTable
376             GHC.Event.Internal
377             GHC.Event.KQueue
378             GHC.Event.Manager
379             GHC.Event.PSQ
380             GHC.Event.Poll
381             GHC.Event.Thread
382             GHC.Event.TimerManager
383             GHC.Event.Unique
384
385             System.CPUTime.Posix.ClockGetTime
386             System.CPUTime.Posix.Times
387             System.CPUTime.Posix.RUsage
388             System.CPUTime.Unsupported
389
390     -- We need to set the unit id to base (without a version number)
391     -- as it's magic.
392     ghc-options: -this-unit-id base