ghc 6.0.1 and Mac OS X 10.2.6 build
Sven Panne
Sven.Panne at informatik.uni-muenchen.de
Thu Sep 11 13:33:43 EDT 2003
Alastair Reid wrote:
> Could I recommend that you use or adapt the autoconf test HUGS_TRY_DYNLINK
> (hugs98/src/unic/aclocal.m4 in the same cvs repository that has ghc).
I would recommend against this. :-)
> This test generates a C object file to be loaded then tries to load the object
> file using one of dlopen, LoadLibrary, NSCreateObjectFileImageFromFile and
> shl_load then tries looking up both the symbol '_test' and 'test' in the
> file. It sets the linker flags to use to build dynamically loadable object
> files and whether or not to use an underscore when doing the lookup and it
> works on HPUX, Mac, Win32 and most mainstream unix variants. (Bug reports and
> improvements are, of course, welcome.)
Tests needing a *target* machine are bad when it comes to cross-compilation,
so we should try to avoid this for GHC. OK, GHC is not really capable of
cross-compilation yet, but we shouldn't make things worse. Regarding the
underscore story: I think I've seen similar tests in other programs (some
version of Guile?), but I can't remember. Could somebody explain in a few
sentences what exactly the "underscore problem" is in GHC(i) and/or the
libraries? Things look a bit muddled in the source code... :-]
Cheers,
S.
More information about the Glasgow-haskell-bugs
mailing list