This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: -static-libgcc and static libstdc++.a,
- From: Ian Lance Taylor <iant at google dot com>
- To: Bob Rossi <bob at brasko dot net>
- Cc: gcc-help at gcc dot gnu dot org
- Date: Mon, 17 Jan 2011 22:37:46 -0800
- Subject: Re: -static-libgcc and static libstdc++.a,
- References: <20110116142125.GB16203@brasko.net>
Bob Rossi <bob@brasko.net> writes:
> Does it make sense to link in libstdc++.a and leave libgcc
> shared? The goal is maximum portability between different linux
> environments.
It makes sense if you do not plan to dlopen any shared libraries which
themselves depend on libstdc++.so.
> I'm hoping this will keep the c++ shared library symbols private,
> but allow the exception handling to work on the system the software
> is run on.
That by itself won't necessarily keep the C++ shared library symbols
private. To ensure that they are private you would need to use a
version script a link time.
Ian