public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Ian Lance Taylor <iant@google.com>
To: Amit Gud <agud@redhat.com>
Cc: binutils@sourceware.org, bug-binutils@gnu.org,
	        Vivek Goyal <vgoyal@in.ibm.com>
Subject: Re: relocation entries for absolute symbols
Date: Tue, 27 Jun 2006 07:29:00 -0000	[thread overview]
Message-ID: <m3bqsfbltm.fsf@localhost.localdomain> (raw)
In-Reply-To: <44A05DA5.7070507@redhat.com>

Amit Gud <agud@redhat.com> writes:

> I'm compiling the GNU/Linux kernel as a shared library and I've found
> that relocation entries are created even for absolute symbols. Is
> there any work-around for this, or is it a known bug?

That is correct behaviour if the symbol is globally visible.  In a
shared library, by default, any symbol may be overridden by the main
executable.  That means that a relocation entry is required.

One fix would be to force the symbol to be hidden using an attribute
or a linker script.

Ian

  reply	other threads:[~2006-06-26 22:21 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-26 22:21 Amit Gud
2006-06-27  7:29 ` Ian Lance Taylor [this message]
2006-07-13  2:45   ` Vivek Goyal
2006-07-13  8:45     ` Peter S. Mazinger
2006-07-13 13:34       ` Vivek Goyal
2006-07-19  9:12         ` Alan Modra

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=m3bqsfbltm.fsf@localhost.localdomain \
    --to=iant@google.com \
    --cc=agud@redhat.com \
    --cc=binutils@sourceware.org \
    --cc=bug-binutils@gnu.org \
    --cc=vgoyal@in.ibm.com \
    /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).