forked from well-typed/plutonomy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
plutonomy.cabal
220 lines (182 loc) · 5.39 KB
/
plutonomy.cabal
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
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
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
207
208
209
210
211
212
213
214
215
216
217
218
219
220
cabal-version: 2.4
name: plutonomy
version: 0.20220721
synopsis: An optimizer for untyped plutus core
category: Plutus
description: An optimizer for untyped plutus core.
license: BSD-3-Clause
license-file: LICENSE
author: Oleg Grenrus <[email protected]>
maintainer: Oleg Grenrus <[email protected]>
copyright: (c) 2022 Well-Typed LLP
build-type: Simple
tested-with: GHC ==8.10.7
extra-source-files:
fixtures-1/*.txt
fixtures-2/*.txt
README.md
source-repository head
type: git
location: https://github.com/well-typed/plutonomy.git
common comm
default-language: Haskell2010
ghc-options:
-Wall -Wno-unticked-promoted-constructors
-fwarn-incomplete-uni-patterns -Wunused-packages
default-extensions:
BangPatterns
DataKinds
EmptyCase
FlexibleContexts
FlexibleInstances
FunctionalDependencies
GADTs
KindSignatures
PatternSynonyms
QuantifiedConstraints
RankNTypes
RecordWildCards
RoleAnnotations
ScopedTypeVariables
StandaloneDeriving
StandaloneKindSignatures
TypeApplications
TypeFamilies
TypeOperators
ViewPatterns
flag CHaP
description:
Use Cardano Haskell package repository
manual: True
default: False
flag plutus-1efbb276e
description:
Assume plutus version 1efbb276ef1a10ca6961d0fd32e6141e9798bd11
manual: True
default: False
flag plutus-4710dff2e
description:
Assume plutus version 4710dff2e30ce131191a6a1ccbe43595b2e3af24
manual: True
default: False
flag plutus-f680ac697
description:
Assume plutus version f680ac6979e069fcc013e4389ee607ff5fa6672f (cardano-node 1.35.1)
manual: True
default: False
flag plutus-ledger
description:
Provide @Plutonomy.TypedScripts@ & @plutus-ledger@ functionality.
manual: True
default: False
library
import: comm
hs-source-dirs: src src-subst
exposed-modules:
Plutonomy
Plutonomy.Builtins
Plutonomy.Constant
Plutonomy.Conversion
Plutonomy.Hereditary
Plutonomy.Hereditary.Rewrite
Plutonomy.Hereditary.Transform
Plutonomy.Known
Plutonomy.Linear
Plutonomy.MissingH
Plutonomy.Name
Plutonomy.Optimize
Plutonomy.Pretty
Plutonomy.Raw
Plutonomy.Raw.Lets
Plutonomy.Raw.Rewrite
Plutonomy.Raw.Transform
Plutonomy.Scripts
Plutonomy.Test
Plutonomy.UPLC
exposed-modules:
Subst
Subst.Var
other-modules:
Plutonomy.Orphans
Plutonomy.PlutusExtras
-- GHC-boot libraries
build-depends:
, base ^>=4.14 || ^>=4.16.3.0
, bytestring ^>=0.10.12.0 || ^>=0.11.3.0
, containers ^>=0.6.2.1
, filepath ^>=1.4.2.1
, text ^>=1.2.3.0
, transformers ^>=0.5.6.2
build-depends:
, fin ^>=0.1.1 || ^>=0.2.1
, lens ^>=4.19.2 || ^>=5.2
, prettyprinter ^>=1.7.0
, some ^>=1.0.2
, strict ^>=0.4.0.1
, tasty ^>=1.4.1
, tasty-golden ^>=2.3.4
, tasty-hunit ^>=0.10.0.3
-- plutus dependencies: no version bounds
build-depends:
, plutus-core >= 1.17.0.0
, plutus-tx
if !flag(CHaP)
-- more recent plutus-ledger-api doesn't have Script newtypes
build-depends: plutus-ledger-api
if flag(plutus-ledger)
if flag(CHaP)
build-depends: unbuildable-plutus-ledger-not-on-CHaP
build-depends: plutus-ledger
exposed-modules: Plutonomy.TypedScripts
if flag(plutus-1efbb276e)
build-depends: dependent-sum-template
x-docspec-options: -XOverloadedStrings -XDataKinds -XTypeApplications
-- only one flag can be one at once.
if True
if flag(CHaP)
if flag(plutus-1efbb276e) || flag(plutus-4710dff2e) || flag(plutus-f680ac697)
build-depends: unbuildable-multiple-plutus-version-flags-on
if flag(plutus-1efbb276e)
if (flag(plutus-4710dff2e) || flag(plutus-f680ac697)) || flag(CHaP)
build-depends: unbuildable-multiple-plutus-version-flags-on
if flag(plutus-4710dff2e)
if (flag(plutus-1efbb276e) || flag(plutus-f680ac697)) || flag(CHaP)
build-depends: unbuildable-multiple-plutus-version-flags-on
if flag(plutus-f680ac697)
if (flag(plutus-1efbb276e) || flag(plutus-4710dff2e)) || flag(CHaP)
build-depends: unbuildable-multiple-plutus-version-flags-on
-- one flag should be enabled
if !(flag(CHaP) || flag(plutus-1efbb276e) || flag(plutus-4710dff2e) || flag(plutus-f680ac697))
build-depends: unbuildable-no-plutus-version-flag
-- CPP of flags
if True
if flag(CHaP)
cpp-options: -DPLUTUS_VER=4 -DPLUTUS_CHAP
if flag(plutus-1efbb276e)
cpp-options: -DPLUTUS_VER=1
if flag(plutus-4710dff2e)
cpp-options: -DPLUTUS_VER=2
if flag(plutus-f680ac697)
cpp-options: -DPLUTUS_VER=3
test-suite plutonomy-tests
import: comm
type: exitcode-stdio-1.0
main-is: plutonomy-tests.hs
hs-source-dirs: tests
other-modules: MultiSig
build-depends:
, base
, plutonomy
, plutus-ledger-api
, plutus-tx
, plutus-tx-plugin
, tasty
if True
if flag(CHaP)
cpp-options: -DPLUTUS_VER=4 -DPLUTUS_CHAP
if flag(plutus-1efbb276e)
cpp-options: -DPLUTUS_VER=1
if flag(plutus-4710dff2e)
cpp-options: -DPLUTUS_VER=2
if flag(plutus-f680ac697)
cpp-options: -DPLUTUS_VER=3