On Thu, May 26, 2011 at 01:24:09PM +0200, Igor Stasenko wrote:
On 26 May 2011 04:49, David T. Lewis lewis@mail.msen.com wrote:
On Wed, May 25, 2011 at 03:55:25PM -0400, Matthew Fulmer wrote:
X11Display class >> XOpenDisplay: displayName ?? ?? ?? "X11Display XOpenDisplay: nil" ?? ?? ?? <cdecl: X11Display* 'XOpenDisplay' (char*) module:'X11'> ?? ?? ?? ^self externalCallFailed
It also results in a series of calls to bogus files:
access("/etc/ld.so.nohwcap", F_OK) ?? ?? ??= -1 ENOENT (No such file or directory) open("/lib/i386-linux-gnu/X11", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/lib/i386-linux-gnu/X11", O_RDONLY) = -1 ENOENT (No such file or directory) open("/lib/X11", O_RDONLY) ?? ?? ?? ?? ?? ?? ??= -1 ENOENT (No such file or directory) open("/usr/lib/sse2/X11", O_RDONLY) ?? ?? = -1 ENOENT (No such file or directory) open("/usr/lib/X11", O_RDONLY) ?? ?? ?? ?? ??= 8
The library is actually at /usr/lib/i386-linux-gnu/libX11.so.6 , which is at least in whatever search path FFI seems to be using. It may have found the library had it been looking for the correct filename
And if you change the declaration to the following, it works?
??<cdecl: X11Display* 'XOpenDisplay' (char*) module:'libX11.so.6'>
yes, but if you change it like that, where the guarantees that it will work on another unix box?
Yes for sure, you would not want to declare it that way. I was just checking my understanding of the problem. Thanks.
Dave