Haddock version during build
Simon Marlow
marlowsd at gmail.com
Mon Jun 16 05:21:12 EDT 2008
Manuel M T Chakravarty wrote:
> I think Haddock needs be bundled and installed with GHC - just like
> ghc-pkg. So, darcs-all should have an option to pull the Haddock repo
> into the build tree. Then, it is built there after stage2 as described
> by Simon. There needs to be an inplace version and an install version,
> and the install targets should handle it just like ghc-pkg.
It wouldn't be a disaster if we had to ship Haddock with GHC, but it's not
ideal. I really want Haddock to be a separate entity, as far as possible -
just a client of the GHC API. This is a problem that will crop up with
other clients of the GHC API too: they all need to know the default
package.conf location. Perhaps we should have a general solution to this?
I'm open to suggestions. Here's one: when installing a GHC distribution
we create a tiny library called libghc-defaults.a that exports a single symbol
char *ghc_default_libdir="/usr/lib/ghc-6.10/or/whatever"
and we always add libghc-defaults.a when linking the GHC package.
The downside is that this means running a C compiler at install time, but
only if the GHC binary dist is supposed to be position-independent - many
are not.
Cheers,
Simon
More information about the Cvs-libraries
mailing list