I can compile Hakyll, but when I try to run it I get a linking error.
First I install Hakyll in a sandbox:
cabal sandbox init
cabal install Hakyll
This completes successfully.
Then I create a plain site using hakyll-init
and move the files up a directory:
.cabal-sandbox/bin/hakyll-init mysite
mv mysite/* .
rm -rf mysite
Then I try to run it with cabal exec -- runghc site.hs build
and I get:
site.hs: <command line>: can't load .so/.DLL for: /Users/john/repositories/CP/principles-of-concurrent-programming/Website/.cabal-sandbox/lib/x86_64-osx-ghc-8.2.1/libHSpandoc-citeproc-0.10.5.1-97wWmtk04v65Etcjop52Rs-ghc8.2.1.dylib (dlopen(/Users/john/repositories/CP/principles-of-concurrent-programming/Website/.cabal-sandbox/lib/x86_64-osx-ghc-8.2.1/libHSpandoc-citeproc-0.10.5.1-97wWmtk04v65Etcjop52Rs-ghc8.2.1.dylib, 5): no suitable image found. Did find:
/Users/john/repositories/CP/principles-of-concurrent-programming/Website/.cabal-sandbox/lib/x86_64-osx-ghc-8.2.1/libHSpandoc-citeproc-0.10.5.1-97wWmtk04v65Etcjop52Rs-ghc8.2.1.dylib: malformed mach-o: load commands size (32992) > 32768
/Users/john/repositories/CP/principles-of-concurrent-programming/Website/.cabal-sandbox/lib/x86_64-osx-ghc-8.2.1/libHSpandoc-citeproc-0.10.5.1-97wWmtk04v65Etcjop52Rs-ghc8.2.1.dylib: malformed mach-o: load commands size (32992) > 32768)
- The contents of
site.hs
are completely standard. I've uploaded the file to gist. - GHC 8.2.1, installed via Homebrew. I initially had this problem with 7.10.3b, and upgraded GHC to see if that would help. It didn't.
- macOS Sierra 10.12.6
Any help would be appreciated!