[nSLUG] Help? libstdc++ question/confusion

Mike Spencer mspencer at tallships.ca
Wed Jan 14 02:52:08 AST 2009


Summary: App works with config/libs on 2.4 kernel.  Fails with 2.6
         kernel. Problem with libstdc++-libc6.1-1.so.2 apparently
         hard-coded in a program.

Details:

I'm trying to run a rather old app [1] on a Slackware 12.1 install with
2.6 kernel.  I get:

     Error while loading shared libraries: libstdc++-libc6.1-1.so.2
     No such file or directory

Sure enough, that lib doesn't exist in the new install on nudel.

Okay, I look on my working machine (named bogus, Slak 10.1, 2.4
kernel) and find:

     bogus% cd /usr/i486-slackware-linux/lib/

     bogus% ls -l libstdc++-libc6.1-1.so.2

        libstdc++-libc6.1-1.so.2 -> libstdc++-2-libc6.1-1-2.9.0.so

     bogus% ls -l libstdc++-2-libc6.1-1-2.9.0.so

        libstdc++-2-libc6.1-1-2.9.0.so

So I copy the real lib over to the same dir on the new box (nudel),
create the corresponding symlink:

     nudel-root$  mount bogus:/

     nudel-root$ pwd

      /usr/i486-slackware-linux/lib
 
    nudel-root$ cp \

      /mnt/bogus/usr/i486-slackware-linux/lib/libstdc++-2-libc6.1-1-2.9.0.so .

    nudel-root$ ln -s libstdc++-2-libc6.1-1-2.9.0.so  libstdc++-libc6.1-1.so.2

and now the app in question segfaults.

If I remove the symlink and recreate it pointing at either of the
newer lib versions, libstdc++-3-libc6*, it also segfaults.

What can I do to fix this?

Why does it all worn on bogus but not on nudel?

(Yes, I ran ldconfig on nudel after each change and
 /usr/i486-slackware-linux/lib is listed in /etc/ld.so.conf.)

I find this lib management stuff way more confusing than writing or
even debugging C code.  I don't even know where to look for a lucid
description of what the various libc* libraries do, how they differ,
how they're systematically (?!) named and why there are so many that
are just symlinks.  So I haven't doggedly documented, listed and
researched this in tedious detail because I don't really know where to
start. 

Really hoping for a helpful clue here.


- Mike



[1] old app: Netscape Navigator 4.76.  

-- 
Michael Spencer                  Nova Scotia, Canada       .~. 
                                                           /V\ 
mspencer at tallships.ca                                     /( )\
http://home.tallships.ca/mspencer/                        ^^-^^



More information about the nSLUG mailing list