WX: linking to system libraries statically

I noticed that even simple WX demos like "Layout" are linked dynamically against 59 libraries on Linux. This would make distributing the binaries a nightmare. Is there a simple way to make a (mostly) statically linked binary?

Hi FFT, I'm just CC'ing wxhaskell-users so they see this question. Thanks! On Thu, 9 Apr 2009 04:13:18 -0700, FFT wrote
I noticed that even simple WX demos like "Layout" are linked dynamically against 59 libraries on Linux. This would make distributing the binaries a nightmare. Is there a simple way to make a (mostly) statically linked binary?
-- Eric Kow http://www.nltg.brighton.ac.uk/home/Eric.Kow PGP Key ID: 08AC04F9

2009/04/09 FFT
I noticed that even simple WX demos like "Layout" are linked dynamically against 59 libraries on Linux. This would make distributing the binaries a nightmare. Is there a simple way to make a (mostly) statically linked binary?
I have had mixed success with `-static -optl-static` (as recommended in "Practical Web Programming in Haskell" page, for example). On Macs, it's hard to get it to work (have never bothered); on Linux, I remember I had to remove it on once occasion to get things to work across Ubuntu and Gentoo (had to do with differences in libc, I believe, but I did not retain notes). Maybe passing in the specific libs to the linker with `-optl` is the best bet? -- Jason Dusek |...Practical Web Programming in Haskell...| http://www.haskell.org/haskellwiki/Practical_web_programming_in_Haskell#Comp...
participants (3)
-
Eric Kow
-
FFT
-
Jason Dusek