[Haskell-cafe] Re: Distributing a GHC-compiled binary for Macs (x86)

apfelmus at quantentunnel.de apfelmus at quantentunnel.de
Fri Mar 9 03:55:28 EST 2007


Arjun Guha wrote:
> I compiled a binary using GHC 6.6 on my Mac (specifically, using ghc
> --make).  This binary seems to depend on the GNU MP framework--I
> imagine GHC uses it to implement its numeric tower.
>
> However, Macs that don't have GHC installed don't seem to have GMP, so
> I'll guess that it was installed along with the GHC binary.  Is there
> any way to get around this GMP dependency?

Indeed, GMP is used to implement 'Integer's and there's no way around.
That being said, there is ongoing discussion on how to replace it with a
different arbitrary precision arithmetic library, mostly for licensing
reasons. GMP is LGPL.

> I expect the binary to be
> used on Macs that don't have GHC installed.  It would be acceptable if
> I instructed Mac-users to download a binary installer for GMP, but I
> haven't been able to find one.

Some years ago, I think I remember that there was a "Haskell Support"
framework for GHC compiled executables or something like that in a
binary installer prepared by Wolfgang Thaller. I'm unsure whether such a
thing exists today, but it certainly suggests itself as a solution: I'd
get/compile a framework with libgmp inside and convince GHC via
-framework to use that as gmp.

Regards,
apfelmus



More information about the Haskell-Cafe mailing list