[Haskell-cafe] How to statically link some external libraries?
sylvain at haskus.fr
Wed Jul 19 08:16:18 UTC 2017
This is what I have in my .cabal file to get a statically-linked executable:
ghc-options: -Wall -static -threaded
ld-options: -static -pthread
On 18/07/2017 20:46, Kai Zhang wrote:
> I want to produce a statically-linked executable. First I tried
> "-optl-static -optc-static -optl-pthrea", which statically links all
> external libraries. But when I ran this executable it gives me "abort
> (core dumped)" error. I suspect the statically-linked glibc library
> might be the cause. So I decide to statically link all other libraries
> and leave the glibc as a dynamic library. How to do this using Cabal?
> Should I write a custom "Setup.hs"?
> Haskell-Cafe mailing list
> To (un)subscribe, modify options or view archives go to:
> Only members subscribed via the mailman list are allowed to post.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Haskell-Cafe