Re: hackery (was: dynamic linking)

2010-02-16 Thread Tomas By
On Tue, February 16, 2010 16:20, Linas Vepstas wrote: > what does ldd libguile-mytest.so show? Are all dependencies resolved? I think so. > If you compile the following, will it run? [...] > i.e. is this enough to compile it: [...] Mercury needs to be initialized, and the C compiler needs to kn

Re: hackery (was: dynamic linking)

2010-02-16 Thread Linas Vepstas
On 15 February 2010 11:43, Tomas By wrote: > Hello again everybody, Just a wild guess -- i'm focusing on the "file not found" aspect of the error message: what does ldd libguile-mytest.so show? Are all dependencies resolved? If you compile the following, will it run? #include "mylibrary.h" #i

hackery (was: dynamic linking)

2010-02-15 Thread Tomas By
Hello again everybody, After some experimentation, it now seems clear that this has nothing to do with garbage collection or Mercury. It is probably just a silly programming error on my part. Here follows full source code for a simple example that illustrates the problem I am having. The importan

Re: dynamic linking

2010-02-09 Thread Tomas By
On Mon, February 8, 2010 13:50, Ludovic Courtès wrote: > Looking at the strace(1) output you sent doesn’t really help. Could you > instead send the strace(1) output starting at the first occurrence of > “libguile”? It should be this bit I think: open("/usr/lib/libguile.so.17", O_RDONLY) =

Re: dynamic linking

2010-02-08 Thread Ludovic Courtès
Hi, "Tomas By" writes: > The version of Guile I am using is 1.8.7 -- is it worth trying 1.9 > instead? > > Is it generally possible to use two different libgc at the same time? Guile 1.8 does *not* use libgc. So there must be something else going on. Looking at the strace(1) output you sent d

Re: dynamic linking

2010-02-08 Thread Tomas By
On Mon, February 8, 2010 13:15, Tomas By wrote: > I have now tried to link my Mercury library with the libgc that Guile > uses instead of the Mercury one, and I asked about it on the Mercury > mailing list, where I got this reply: > > "The version of libgc that Mercury uses contains Mercury specifi

Re: dynamic linking

2010-02-08 Thread Tomas By
Hello again, I have now tried to link my Mercury library with the libgc that Guile uses instead of the Mercury one, and I asked about it on the Mercury mailing list, where I got this reply: "The version of libgc that Mercury uses contains Mercury specific modifications; I would be surprised if li

Re: dynamic linking

2010-02-05 Thread Ludovic Courtès
Hi, "Tomas By" writes: > open("/usr/local/mercury-rotd-2009-12-28/lib/mercury/lib/libgc.so", > O_RDONLY) = 9 [...] > I guess that "libgc.so" is the Mercury garbage collector. Is there some > problem with having another GC in a Guile module? The problem is that Guile 1.9 is linked against anot

dynamic linking

2010-02-05 Thread Tomas By
Hi all, I'm trying to create a Guile module, using code written in Mercury. (http://www.cs.mu.oz.au/research/mercury/) I have managed to produce a library file (.so), but when I try to open it in Guile (with dynamic-link), I get "file not found". It's clear from the strace output that it does find