Simplify the GHC.Prim hack in base.cabal/Setup.hs
[ghc-base.git] / base.cabal
1 name:           base
2 version:        3.0
3 license:        BSD3
4 license-file:   LICENSE
5 maintainer:     libraries@haskell.org
6 synopsis:       Basic libraries
7 description:
8     This package contains the Prelude and its support libraries,
9     and a large collection of useful libraries ranging from data
10     structures to parsing combinators and debugging utilities.
11 cabal-version:  >=1.2
12 build-type: Custom
13 extra-tmp-files:
14                 config.log config.status autom4te.cache
15                 include/HsBaseConfig.h
16
17
18 Library {
19     -- This is actually something of a hack, as if we are using
20     -- GHC and we don't have an rts package for some reason, we
21     -- actually ought to fail.
22     if impl(ghc) {
23         build-depends: rts
24         exposed-modules:
25             Data.Generics,
26             Data.Generics.Aliases,
27             Data.Generics.Basics,
28             Data.Generics.Instances,
29             Data.Generics.Schemes,
30             Data.Generics.Text,
31             Data.Generics.Twins,
32             Foreign.Concurrent,
33             GHC.Arr,
34             GHC.Base,
35             GHC.Conc,
36             GHC.ConsoleHandler,
37             GHC.Desugar,
38             GHC.Dotnet,
39             GHC.Enum,
40             GHC.Environment,
41             GHC.Err,
42             GHC.Exception,
43             GHC.Exts,
44             GHC.Float,
45             GHC.ForeignPtr,
46             GHC.Handle,
47             GHC.IO,
48             GHC.IOBase,
49             GHC.Int,
50             GHC.List,
51             GHC.Num,
52             GHC.PArr,
53             GHC.Pack,
54             GHC.PrimopWrappers,
55             GHC.Ptr,
56             GHC.Read,
57             GHC.Real,
58             GHC.ST,
59             GHC.STRef,
60             GHC.Show,
61             GHC.Stable,
62             GHC.Storable,
63             GHC.TopHandler,
64             GHC.Unicode,
65             GHC.Weak,
66             GHC.Word,
67             System.Timeout
68     }
69     exposed-modules:
70         Control.Applicative,
71         Control.Arrow,
72         Control.Category,
73         Control.Concurrent,
74         Control.Concurrent.Chan,
75         Control.Concurrent.MVar,
76         Control.Concurrent.QSem,
77         Control.Concurrent.QSemN,
78         Control.Concurrent.SampleVar,
79         Control.Exception,
80         Control.Monad,
81         Control.Monad.Fix,
82         Control.Monad.Instances,
83         Control.Monad.ST,
84         Control.Monad.ST.Lazy,
85         Control.Monad.ST.Strict,
86         Data.Bits,
87         Data.Bool,
88         Data.Char,
89         Data.Complex,
90         Data.Dynamic,
91         Data.Either,
92         Data.Eq,
93         Data.Fixed,
94         Data.Foldable
95         Data.Function,
96         Data.HashTable,
97         Data.IORef,
98         Data.Int,
99         Data.Ix,
100         Data.List,
101         Data.Maybe,
102         Data.Monoid,
103         Data.Ord,
104         Data.Ratio,
105         Data.STRef,
106         Data.STRef.Lazy,
107         Data.STRef.Strict,
108         Data.String,
109         Data.Traversable
110         Data.Tuple,
111         Data.Typeable,
112         Data.Unique,
113         Data.Version,
114         Data.Word,
115         Debug.Trace,
116         Foreign,
117         Foreign.C,
118         Foreign.C.Error,
119         Foreign.C.String,
120         Foreign.C.Types,
121         Foreign.ForeignPtr,
122         Foreign.Marshal,
123         Foreign.Marshal.Alloc,
124         Foreign.Marshal.Array,
125         Foreign.Marshal.Error,
126         Foreign.Marshal.Pool,
127         Foreign.Marshal.Utils,
128         Foreign.Ptr,
129         Foreign.StablePtr,
130         Foreign.Storable,
131         Numeric,
132         Prelude,
133         System.Console.GetOpt,
134         System.CPUTime,
135         System.Environment,
136         System.Exit,
137         System.IO,
138         System.IO.Error,
139         System.IO.Unsafe,
140         System.Info,
141         System.Mem,
142         System.Mem.StableName,
143         System.Mem.Weak,
144         System.Posix.Internals,
145         System.Posix.Types,
146         Text.ParserCombinators.ReadP,
147         Text.ParserCombinators.ReadPrec,
148         Text.Printf,
149         Text.Read,
150         Text.Read.Lex,
151         Text.Show,
152         Text.Show.Functions
153         Unsafe.Coerce
154     c-sources:
155         cbits/PrelIOUtils.c
156         cbits/WCsubst.c
157         cbits/Win32Utils.c
158         cbits/consUtils.c
159         cbits/dirUtils.c
160         cbits/inputReady.c
161         cbits/longlong.c
162         cbits/selectUtils.c
163     include-dirs: include
164     includes:    HsBase.h
165     install-includes:    HsBase.h HsBaseConfig.h WCsubst.h dirUtils.h consUtils.h Typeable.h
166     if os(windows) {
167         extra-libraries: wsock32, msvcrt, kernel32, user32, shell32
168     }
169     extensions:    CPP
170     -- XXX is there an extension for using # in varids?
171     -- We need to set the package name to base (without a version number)
172     -- as it's magic.
173     ghc-options: -fglasgow-exts -package-name base
174     nhc98-options: -H4M -K3M
175 }