nh2 / static-haskell-nix

easily build most Haskell programs into fully static Linux executables
388 stars 36 forks source link

Static libraries #28

Closed turbolent closed 5 years ago

turbolent commented 5 years ago

Is it possible to use this infrastructure to also build static libraries?

nh2 commented 5 years ago

I'm not quite clear on what exactly you mean.

Yes, static libs for system libraries are built by static-haskell-nix, so that we can link them into static executables.

Or do you mean static Haskell libs for a particular purpose?

GHC usually already builds .a files.

Do you perhaps mean some "bundled" .a files that contain all their recursive dependencies?

turbolent commented 5 years ago

Right, I was new to cabal and its options. --enable-static --disable-shared builds a static library just fine.