From: Geoffrey Keating <geoffk@apple.com>
To: "H. J. Lu" <hjl@lucon.org>
Cc: binutils@sources.redhat.com, gcc@gcc.gnu.org
Subject: Re: ld -shared -Bsymbolic and C++ shared library
Date: Thu, 27 Jul 2006 22:37:00 -0000 [thread overview]
Message-ID: <m2hd12k72q.fsf@greed.local> (raw)
In-Reply-To: <20060716172604.GB29871@lucon.org>
"H. J. Lu" <hjl@lucon.org> writes:
> ld -shared -Bsymbolic will reduce number of dynamic relocations in
> a shared library. Unfortunately, it won't work correctly with C++
> exception and maybe other language features.
>
> However, I think it is possible to make -shared -Bsymbolic to work
> for C++ by providing a way to specify a list of symbols which must
> be dynamic. We then can do
>
> # g++ -Wl,-Bsymbolic -shared -xxx "list of dynamic symbols" -o libfoo.so ...
>
> and libfoo.so written in C++ will work correctly with much fewer dynamic
> relocations.
You may find this would be easier to use if you just had a flag which
made -Bsymbolic apply only to non-weak symbols.
next prev parent reply other threads:[~2006-07-27 22:37 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-16 17:26 H. J. Lu
2006-07-27 22:37 ` Geoffrey Keating [this message]
2006-07-28 1:21 ` H. J. Lu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m2hd12k72q.fsf@greed.local \
--to=geoffk@apple.com \
--cc=binutils@sources.redhat.com \
--cc=gcc@gcc.gnu.org \
--cc=hjl@lucon.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).