Re: glibc + libstdc++?
On Monday 07 June 2004 12:06 pm, Bob Proulx wrote:
>Jeff Elkins wrote:
>> Bob Proulx wrote:
>> > Jeff Elkins wrote:
>> > > pvconv: relocation error: pvconv: undefined symbol: __dynamic_cast_2
>> > I was curious enough to download the application and try it. I can
>> > get a usage string out of it so I think I have all of the libraries on
>> > my woody system. I got a usage string out of it on a sid system.
>> libstdc++-libc6.2-2.so.3 => /usr/lib/libstdc++-libc6.2-2.so.3
>> (0x40029000) [...]
>> dpkg -S /usr/lib/libstdc++-libc6.2-2.so.3
>> libstdc++2.10-glibc2.2: /usr/lib/libstdc++-libc6.2-2.so.3
>> Yep, I get a usage string, it just crashes when I try to use the app
>> <grrr> :)
>One of the things I am very interested in is cross distro
>compatibility. So I ran the binary on a RH7.3 machine. I just ran it
>against a random .wav file and it appeared that it runs there. It
>gave me error messages about the conversion but did not report the
>missing symbol __dynamic_cast_2.
>Then I copied the library from the RH machine to my Debian woody
>machine. I did not remove the debian package first. Too many things
>depend up it.
> apt-cache showpkg libstdc++2.10-glibc2.2
>But it is not required for basic C programs which make up the core
>utilities. That is I won't break 'mv' by doing this like I could
>moving other libs around.
>Therefore I moved my debian version of the library out of the way and
>moved the RH version into place directly. With that copied into place
>on Debian the pvconv program ran the same on my Debian machine as it
>did on the RH machine. With this library in place I think the program
> cd /usr/lib
> mv libstdc++-3-libc6.2-2-2.10.0.so libstdc++-3-libc6.2-2-2.10.0.so.debian
> cp libstdc++-3-libc6.2-2-2.10.0.so.redhat libstdc++-3-libc6.2-2-2.10.0.so
>Warning: I really can't recommend this type of low level shared
>library manipulation. Mistakes can really cause trouble with your
>system. You can definitely break your system and need to boot a
>recovery image to repair it. This is not the way to manage a system
>in production for example. But for debugging this type of hacking can
>be useful. And for your particular problem you might find this useful
>enough to solve your problem as much as you need it to be solved.
>I found an rpm of the library here:
>That can be unpacked using:
> rpm2cpio libstdc++-2.96-113.i386.rpm | cpio -idm
>I see this solution as only a workaround. The real solution would be
>to understand what RH did to their library which breaks compatibility,
>or the reverse. Then modify the Debian version so that it works there
Yippee!! It works :)
Thank you, thank you :)
I set up a script to swap the libs, run the converter, then swap them back so
as not to leave my system in an unstable state. Goodbye Windows!