Agda FFI bindings to Haskell bee2-hs library.
While compiling and building executables we need to tell agda
where to find bee2-hs
.
There are two ways to do it.
- Tell
agda
to not callghc
with--ghc-dont-call-ghc
flag and then build haskell files withghc
,cabal
orstack
. At this point the project lacks cabal and stack.yaml files, so this approach is not easy. - Provide
ghc-flag
s toagda
which would specify where to findbee2-hs
.
Let's run the latter approach. First, you need to manually follow build instructions for bee2-hs
with cabal
sandboxes.
cd bee2-agda
# specify compile-dir in order to reuse already compiled agda-files
# specify `-package-db` flag for ghc, use package-db from your sandbox, it's name will differ depending on your machine architecture, OS and `ghc` version
> agda -c app/bee2.agda --compile-dir=../.agda-ghc --ghc-flag=-package-db=../.cabal-sandbox/x86_64-windows-ghc-8.2.2-packages.conf.d
# bee2 executable should be built, let's try it
> ../.agda-ghc/bee2