Linking vs. shared libs on Unix

Thomas Pasch
Thu, 03 May 2001 00:07:26 +0200


In the windows version of ghc, 
there seems to be the possiblity to compile
the libraries as shared 'dll's. Is the 
same possible for the unix version?

The question is because I think the ghc 
executables are really blown up. A simple
'Hello, world' has 172 kBytes (358k unstripped)
and the hello example of the GTK+ bindings 
is as big as 854 kBytes (2.2 MBytes unstripped),
although it is link dynamically against:

> ldd hello => /usr/lib/ (0x40025000) => /usr/lib/ (0x40028000) => /usr/lib/ (0x40155000) => /usr/lib/ (0x4018a000) => /usr/lib/ (0x4018d000) => /lib/ (0x401b1000) => /usr/X11R6/lib/ (0x401b4000) => /usr/X11R6/lib/ (0x401bc000) => /usr/X11R6/lib/ (0x401cb000) => /lib/ (0x402ae000) => /usr/lib/ (0x402cc000) => /lib/ (0x402ed000) => /lib/ (0x40400000)
        /lib/ => /lib/ (0x40000000)   

Best regards,