blob: 5393363505a36062d9a18ce7c7cc0d1fb7d2f126 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
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
98
99
100
|
cabal-version: 2.2
name: ghc-prim
version: 0.10.0
-- NOTE: Don't forget to update ./changelog.md
license: BSD-3-Clause
license-file: LICENSE
category: GHC
maintainer: libraries@haskell.org
bug-reports: https://gitlab.haskell.org/ghc/ghc/issues/new
synopsis: GHC primitives
build-type: Custom
description:
This package contains the primitive types and operations supplied by GHC.
It is an internal package, only for the use of GHC developers.
GHC users should not use it! If you do use it then expect
breaking changes at any time without warning. You should prefer
to import @GHC.Exts@ from the @base@ package instead.
extra-source-files: changelog.md
source-repository head
type: git
location: https://gitlab.haskell.org/ghc/ghc.git
subdir: libraries/ghc-prim
custom-setup
setup-depends: base >= 4 && < 5, process, filepath, directory, Cabal >= 1.23 && < 3.9
Library
default-language: Haskell2010
other-extensions:
BangPatterns
CPP
DeriveGeneric
MagicHash
MultiParamTypeClasses
NoImplicitPrelude
StandaloneDeriving
Trustworthy
TypeFamilies
UnboxedTuples
UnliftedFFITypes
build-depends: rts == 1.0.*
exposed-modules:
GHC.CString
GHC.Classes
GHC.Debug
GHC.Magic
GHC.Magic.Dict
GHC.Prim.Ext
GHC.Prim.Panic
GHC.Prim.Exception
GHC.Prim.PtrEq
GHC.PrimopWrappers
GHC.Tuple
GHC.Tuple.Prim
GHC.Types
virtual-modules:
GHC.Prim
-- OS Specific
if os(windows)
-- Windows requires some extra libraries for linking because the RTS
-- is no longer re-exporting them (see #11223)
-- ucrt: standard C library. The RTS will automatically include this,
-- but is added for completeness.
-- 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.
-- user32: provides access to apis to modify user components (UI etc)
-- on Windows. Required because of mingw32.
extra-libraries: user32, mingw32, ucrt
if os(linux)
-- we need libm, but for musl and other's we might need libc, as libm
-- is just an empty shell.
extra-libraries: c, m
if !os(ghcjs)
c-sources:
cbits/atomic.c
cbits/bswap.c
cbits/bitrev.c
cbits/clz.c
cbits/ctz.c
cbits/debug.c
cbits/longlong.c
cbits/mulIntMayOflo.c
cbits/pdep.c
cbits/pext.c
cbits/popcnt.c
cbits/word2float.c
-- We need to set the unit ID to ghc-prim (without a version number)
-- as it's magic.
ghc-options: -this-unit-id ghc-prim
|