This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: Partial symbol export vs --export-dynamic
On Mon, Jun 18, 2001 at 09:13:22AM +0200, Hans-Peter Nilsson wrote:
> > From: Ben Elliston <bje@redhat.com>
> > Date: Mon, 18 Jun 2001 12:38:00 +1000 (EST)
>
> > I see no reason why it shouldn't be possible for you to list C++
> > symbols in an unmangled form and let the linker mangle them as the
> > export file is processed. Am I missing something, anyone?
>
> Perhaps something like that there's only a *de*mangler built-in
> through libiberty? A mangler generally requires a C++-parser,
> IIUC. Or some other trick currently not implemented.
The version script has been supporting C++ since 1999:
1999-04-11 Richard Henderson <rth@cygnus.com>
* ldgram.y (ldgram_vers_current_lang): New.
(vers_defns): Accept `extern "lang" { }' syntax.
* ldlex.l (vers_node_nesting): New.
(V_IDENTIFIER): Accept . and $ in symbols.
(VERS_NODE): Accept `extern "lang" { }' tokens. Nest VERS_NODE states.
* ldlang.c (lang_new_vers_regex): New `lang' argument. Update callers.
(lang_vers_match_lang_c): New function.
(lang_vers_match_lang_cplusplus): New function.
(lang_vers_match_lang_java): New function.
(lang_do_version_exports_section): Fix iteration. Don't free
section contents, as it is still in use by the patterns.
But I am not sure if it is documented. Richard?
H.J.