On Thu, Mar 3, 2011 at 9:36 AM, Andreas Rottmann <[email protected]> wrote: > Hans Aberg <[email protected]> writes:
>>> Why does this fail? �Can you strace it? >> >> If you tell me how. :-) >> > Apparently, on OS X, "dtruss" does fulfill the role of "strace": > <http://humberto.digi.com.br/blog/2008/02/25/strace-on-mac-os-x-leopard/>. Thanks for the tip about dtruss. Very useful to know about. For the record, here's some dtruss output created when I try to dynamic-link a library that doesn't have a .so softlink, ie (dynamic-link "libf77lapack"). As you can see it's trying 'open_nocancel', 'access', and 'stat64' looking for .la and .so in all all the right places before giving up. 89795/0x1bfacf: open_nocancel("/usr/local/lib/libf77lapack.la\0", 0x0, 0x1B6) = -1 Err#2 89795/0x1bfacf: open_nocancel("/usr/local/lib/libf77lapack.la\0", 0x0, 0x1B6) = -1 Err#2 89795/0x1bfacf: open_nocancel("/lib/libf77lapack.la\0", 0x0, 0x1B6) = -1 Err#2 89795/0x1bfacf: open_nocancel("/usr/lib/libf77lapack.la\0", 0x0, 0x1B6) = -1 Err#2 89795/0x1bfacf: open_nocancel("libf77lapack.la\0", 0x0, 0x1B6) = -1 Err#2 89795/0x1bfacf: access("/usr/local/lib/libf77lapack.so\0", 0x4, 0x10060A800) = -1 Err#2 89795/0x1bfacf: access("/usr/local/lib/libf77lapack.so\0", 0x4, 0x10060A800) = -1 Err#2 89795/0x1bfacf: access("/lib/libf77lapack.so\0", 0x4, 0x10060A800) = -1 Err#2 89795/0x1bfacf: access("/usr/lib/libf77lapack.so\0", 0x4, 0x10060A800) = -1 Err#2 89795/0x1bfacf: stat64("libf77lapack.so\0", 0x7FFF5FBFE630, 0x7FFF5FBFEC70) = -1 Err#2 89795/0x1bfacf: stat64("/Users/mellis/lib/libf77lapack.so\0", 0x7FFF5FBFEA10, 0x7FFF5FBFEC70) = -1 Err#2 89795/0x1bfacf: stat64("/usr/local/lib/libf77lapack.so\0", 0x7FFF5FBFEA10, 0x7FFF5FBFEC70) = -1 Err#2 89795/0x1bfacf: stat64("/usr/lib/libf77lapack.so\0", 0x7FFF5FBFEA20, 0x7FFF5FBFEC70) = -1 Err#2 89795/0x1bfacf: sigprocmask(0x1, 0x0, 0x7FFF5FBFEEC0) = 0x0 0 89795/0x1bfacf: sigaltstack(0x0, 0x7FFF5FBFEEB0, 0x0) = 0 0 89795/0x1bfacf: write(0x1, "ERROR: In procedure dynamic-link:\nERROR: In procedure dynamic-link: file: \"libf77lapack\", message: \"file not found\"\n\0", 0x74) = 116 0 If I try to specify the .dylib extension, dtruss shows that it fails because the standard extensions are being appended, e.g. open_nocancel("/usr/local/lib/libf77lapack.dylib.la\0", 0x0, 0x1B6) Is this something that can be fixed within Guile? Cheers, Mike
