OK, after digging around the build system quite a bit, here is my first
proposal to get things back into a sane state.
The first confusing things are that "datadir", "libdir" and "libexecdir" don't
have the proposed GNU semantics. because they contain the package
name "ghc-XY". They are intended to be *prefixes* below which packages
install their stuff in a separate directory (typically packagename-version),
at least this is what 99% of all SW using configure etc. do. This can be
fixed by some more or less mechanical work in the build system.
The second bug is that GHC is unable to distinguish "libdir" and "libexecdir",
because it uses topDir for everything (given by either -B or determined
automagically on Windows). Using "libdir" and/or "libexecdir" in the build
system is basically lying about GHC's abilities. I think there are two
options:
a) Add another option in addition to -B. This would be a little bit
academic, as there is very few SW out there which sensibly makes use of such
a distinction.
b) Be honest and use a new Makefile variable "topdir" for the relevant
paths. This defaults to "${libdir}/ghc-$(ProjectVersion}", solving the first
issue, too. (On Windows the default would be "${prefix}", if I see it
correctly). Note that "${topdir}" is the *final* installation path.
I think I'll go for b) if nobody yells. This of course doesn't solve all our
build problems, but goes into the right direction...
Cheers,
S.
P.S. for pedantic people: ghc{,i}-usage.txt should be under "docdir", but I
think we can live with them being under "topdir". But at least we should say
so in the build system. This would add a third command line option if a) were
implemented.
_______________________________________________
Cvs-ghc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/cvs-ghc