GHC Installation Location

Simon Marlow
Thu, 25 Oct 2001 11:01:42 +0100

> Is there an easy way to get 'ghc' or one of the other=20
> binaries to tell me=20
> where the GHC installation directory is? I want to put the includes=20
> directory in a gcc -I flag in my makefile.

On a Unix platform, the 'ghc' wrapper script contains the installation
directory, which is passed as an option to the ghc-5.02 binary proper.
On Windows platforms, there isn't a wrapper - ghc figures out the
install location from the location of its binary.

I've wondered at various times in the past whether there ought to be a
link from /usr/local/includes/ghc to /usr/local/lib/ghc-5.02/includes.
But the usual way around this problem is to use 'ghc' as your C compiler
- then the -I flag gets injected automatically.