How to use a DLL in a Haskell project?

You’ll need to use extra-lib-dirs and extra-libraries in the executable section of your .cabal file like so: name: MyApp version: 0.1.0.0 synopsis: homepage: author: simon.bourne category: build-type: Simple cabal-version: >=1.10 library exposed-modules: HelloWorld build-depends: base >= 4.7 && < 5 hs-source-dirs: src default-language: Haskell2010 executable MyApp main-is: Main.hs extra-lib-dirs: lib extra-libraries: helloWorld build-depends: base >= …

Read more

Profiling builds with Stack

Profiling builds with Stack 1.0.0 and newer To build with profiling enabled: stack build –profile You may need to run stack clean first, but this should be fixed in Stack 1.5.0. To profile: stack exec –profile — <your program> +RTS <profiling options> where for <profiling options> you might want -p for time profiling or -h …

Read more