garnet/haskell/garnet.cabal
George Thomas 0a1911862f Expose explicit C interface
We drop the tools specifically designed for Haskell and Rust together, in favour of general tools for using each with C.

Namely, we use Mozilla's `cbindgen` for generating header files from the Rust source, and Well-Typed's new `hs-bindgen` tool for generating Haskell from those header files.

The Rust code here is essentially the result of expanding the old macro, then inlining and renaming internals.

The most important thing here is that we're now relying solely on robust well-maintained tools.
2026-02-19 16:29:41 +00:00

53 lines
1.1 KiB
Plaintext

cabal-version: 3.0
name: garnet
version: 0.1.0.0
license: BSD-3-Clause
author: Patrick Aldis
maintainer:
george.thomas@obsidian.systems
patrick.aldis@obsidian.systems
library garnet-generated
hs-source-dirs: generated
exposed-modules:
GarnetRs
GarnetRs.Safe
GarnetRs.Unsafe
GarnetRs.FunPtr
default-language: Haskell2010
extra-bundled-libraries: garnet_rs
build-depends:
base,
hs-bindgen-runtime,
primitive,
executable garnet
main-is: Main.hs
hs-source-dirs: exe
default-language: GHC2024
default-extensions:
BlockArguments
DeriveAnyClass
DuplicateRecordFields
ImpredicativeTypes
LexicalNegation
MultiWayIf
NamedFieldPuns
NegativeLiterals
NoFieldSelectors
NoMonomorphismRestriction
OverloadedRecordDot
OverloadedStrings
RecordWildCards
ViewPatterns
ghc-options:
-Wall
-fdefer-type-errors
-threaded
-rtsopts
-with-rtsopts=-N
build-depends:
base >= 4.14,
garnet-generated,
hs-bindgen-runtime,