garnet/garnet.cabal
George Thomas 352d2e6208 debug wip
2026-04-15 01:40:47 +01:00

83 lines
2.0 KiB
Plaintext

cabal-version: 3.14
name: garnet
version: 0.1.0.0
license: BSD-3-Clause
author: Patrick Aldis
maintainer:
george.thomas@obsidian.systems
patrick.aldis@obsidian.systems
-- aha, nice, this does fix recompilation checking
extra-source-files:
rust/target/debug/garnet_rs.h
-- that could be problematic given file is gitignored? unfortunately this doesn't work
-- tbf, I haven't even looked up the docs, just saw the autocompletion
-- extra-tmp-files:
-- rust/target/debug/garnet_rs.h
-- actually maybe this is pointless given we always need debug path anyway in `extra-source-files`
-- plus we have it in `Raw.hs`
flag dev
default:
False
manual:
True
common common
default-language: GHC2024
default-extensions:
BlockArguments
DeriveAnyClass
DuplicateRecordFields
ImpredicativeTypes
LexicalNegation
MultiWayIf
NamedFieldPuns
NegativeLiterals
NoFieldSelectors
NoMonomorphismRestriction
OverloadedRecordDot
OverloadedStrings
PatternSynonyms
RecordWildCards
ViewPatterns
ghc-options:
-Wall
-fdefer-type-errors
build-depends:
base,
bytestring,
extra,
mtl,
process,
text,
vector,
library
import: common
exposed-modules:
GarnetRs.Raw
GarnetRs.Wrapped
hs-source-dirs: lib
-- if flag (dev)
-- include-dirs: rust/target/debug
include-dirs: rust/target/debug
-- HLS gives up entirely when the header is malformed if we do this
-- and anyway, I don't think it gives us dependency tracking like `extra-source-files` does
-- includes: garnet_rs.h
extra-bundled-libraries: Cgarnet_rs
build-depends:
hs-bindgen,
hs-bindgen-runtime,
template-haskell,
executable garnet
import: common
main-is: Main.hs
hs-source-dirs: exe
ghc-options:
-threaded
-rtsopts
-with-rtsopts=-N
build-depends:
garnet,