"libc.so" is somewhat of the standard system default on all things Unix, with Darwin being different. The idea is to have libc.so be a symbolic link to the real thing. Loading with an explicit version number is a bad idea, but then, Unix is full of bad ideas.
What I mean to say is: There is no sensible way to load libc in a system independent manner. It is certainly supposed into every program anyway.
-Hans
On Wed, Oct 1, 2008 at 03:40, Chun Tian (binghe) binghe.lisp@gmail.com wrote:
No. libc.so.6 just for Linux, I think it means the 6th big revision (with incompatible API changes) of the GNU C Library.
On Solaris (I have some Solaris 10 (both SPARC and x86) boxes), there's no libc.so.6 but libc.so.1:
binghe@sparc-1:/usr/lib$ ls -l libc.so* lrwxrwxrwx 1 root root 19 Aug 4 17:16 libc.so -> ../../lib/libc.so.1 lrwxrwxrwx 1 root root 19 Aug 4 17:16 libc.so.1 -> ../../lib/libc.so.1
binghe@sparc-1:/usr/lib$ ldd /bin/ls libsec.so.1 => /lib/libsec.so.1 libc.so.1 => /lib/libc.so.1 libavl.so.1 => /lib/libavl.so.1 libm.so.2 => /lib/libm.so.2 /platform/SUNW,Ultra-80/lib/libc_psr.so.1
And on FreeBSD (which I don't have a running one), since they also do not use GNU C Library either, it's quite possible that the libc.so revision isn't "6" too.
But, on all UNIX, I think the file "/usr/lib/libc.so" will be the right answer.
Except Darwin (Mac OS X), which is "/usr/lib/libc.dylib", which point to "libSystem.dylib", I don't know if it's also from FreeBSD.
--binghe
usocket-devel mailing list usocket-devel@common-lisp.net http://common-lisp.net/cgi-bin/mailman/listinfo/usocket-devel