Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20130724233611.5bac4fe7@sibserver.ru>
Date: Wed, 24 Jul 2013 23:36:11 +0800
From: orc <orc@...server.ru>
To: musl@...ts.openwall.com
Subject: Re: Missing symbols for supporting glibc-built
 libstdc++.so.6

On Wed, 24 Jul 2013 10:47:27 -0400
Rich Felker <dalias@...ifal.cx> wrote:

> On Wed, Jul 24, 2013 at 10:20:03PM +0800, orc wrote:
> > About a year ago while experimenting with musl desktop, various
> > binary blobs I unfortunately tied to (you should remember
> > short discuss about nvidia blob compatibility) I tried to use my
> > host libstdc++.so with musl linker and that failed because of gnu
> > "unique symbol" extension. Did you encountered same problem here?
> > If so, is it solved now?
> 
> I have only tested with simple C++ .so files using the musl-built
> libstdc++.so, and so far, they've worked fine. These tests are by no
> means extensive, just "hello world". I have not tried using the
> glibc-built libstdc++.so.6 again; the "missing symbols" check was
> based purely on the output of:
> 
>     nm -u -D libstdc++.so.6 | grep -v -e _[UJ] -e ' w '
> 
> Do you know the subject line of the thread where your issue was
> discussed before? I'd be happy to go look and see if I think the issue
> is fixed now.

I did not send a report about this especially, just my experiments
showed that. Just because nvidia blob did not require libstdc++.so at
all. But others did.
You can start reading somewhere in long 'Hello' thread about 6 Jul 2012.

Tested now:
- Hello world prog:
#include <iostream>
 
int main()
{
    std::cout << "Hello, world!" << std::endl;
    return 0;
}

% g++ test.cc -o test-cpp
% musl-out/lib/libc.so ./test-cpp
[lots of "Error relocating..." errors]
% musl-out/lib/libc.so ./test-cpp 2>&1 | fgrep _ZGVNSt7collateIwE2idE #
picking one
% nm /usr/lib/libstdc++.so.6 | fgrep _ZGVNSt7collateIwE2idE
00000000002e40d8 u _ZGVNSt7collateIwE2idE
(man nm says that 'u' is "unique global" and gnu extension)

On musl system there is 'V' instead of 'u'.
Is my example falls under "glibc-built libstdc++.so.6"?

> 
> Rich

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.