[mercury-users] dynamic linking, Guile

Julien Fischer juliensf at csse.unimelb.edu.au
Sun Feb 7 15:30:50 AEDT 2010


On Sat, 6 Feb 2010, Tomas By wrote:

> I am trying to write a Guile module in Mercury. Have created a dynamic
> library using the Mercury compiler, but when I try to load it in Guile,
> with "dynamic link", I get errors. Apparently Guile, like Mercury, uses
> the Boehm GC, and the problem seems related to this. In my first try,
> my Mercury .so was linked with the libgc.so in the Mercury distribution,
> and then I tried linking it with the one that Guile uses instead (by
> the crude method of renaming the Mercury libgc.so). It seems to me that
> the problems are the same in both cases. What the "mmap2", "mprotect",
> and "munmap" calls are about I do not know.
> Has anybody done this before? Could somebody explain how to tell the
> Mercury compiler to use the system wide libgc using polite language?

The version of libgc that Mercury uses contains Mercury specific
modifications; I would be surprised if linking against the system
wide one worked.

mercury-users mailing list
Post messages to:       mercury-users at csse.unimelb.edu.au
Administrative Queries: owner-mercury-users at csse.unimelb.edu.au
Subscriptions:          mercury-users-request at csse.unimelb.edu.au

More information about the users mailing list