Mac OS X HEADS UP: HaskellSupport.framework is dead

Wolfgang Thaller wolfgang.thaller at gmx.net
Mon Mar 7 23:46:10 EST 2005


GHC's configure.ac now no longer looks for HaskellSupport.framework.
In addition to looking for normal libgmp and libdl, it now looks for a 
GMP.framework, which is libgmp packaged as a framework.

The HaskellSupport.framework used to be a combination of libgmp and 
dlcompat. Starting with Mac OS X 10.3, Apple provides dlcompat's 
functionality in libSystem, so we now only need gmp.

* Why not link statically to libgmp?
Legal reasons. The LGPL requires that the end-user of a program that 
uses the library can modify the library and use the program with a 
changed version of the library (Section 6). Dynamic linking is the 
easiest way to fulfill this requirement.

* Why not just use a normal libgmp.dylib?
If you're using GHC via a unix-style package manager like darwinports 
or fink, then that's indeed what you should do. But when you're not 
using one, or when you want to distribute binaries to people who might 
not, it's much better to have gmp in a place that is actually visible 
from the Finder (/Library/Frameworks) rather than in some scary 
directory that "normal" Mac users don't understand.
Also, you can put a framework into ~/Library/Frameworks to get a 
single-user installation without additional hassle, whereas you'd need 
to mess around with DYLD_LIBRARY_PATH in order to install a .dylib in 
your home directory.

* Why now?
I've been planning to do this for a long time, but I never got around 
to it.

* Where to get it
a) Wait for my next binary snapshot
or
b) Download the official gmp sources from www.swox.com/gmp/. Un pack 
it. Put the shell script I'm attaching to this e-mail 
(build-framework.sh) into the directory and run it.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: build-framework.sh
Type: application/octet-stream
Size: 1053 bytes
Desc: not available
Url : http://www.haskell.org//pipermail/cvs-ghc/attachments/20050307/e1c1d125/build-framework.obj
-------------- next part --------------


Comments and complaints are welcome.

Cheers,

Wolfgang


More information about the Cvs-ghc mailing list