This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Re: [PATCH v4] BFD: Prevent writing the MIPS _gp_disp symbol into symbol tables
- From: Joseph Myers <joseph at codesourcery dot com>
- To: "Maciej W. Rozycki" <macro at mips dot com>
- Cc: Simon Atanasyan <simon at atanasyan dot com>, <binutils at sourceware dot org>, <libc-alpha at sourceware dot org>
- Date: Tue, 1 May 2018 14:40:48 +0000
- Subject: Re: [PATCH v4] BFD: Prevent writing the MIPS _gp_disp symbol into symbol tables
- References: <20180429065756.bvponxkyyqtmdrbg@debian64.galaxy.int> <alpine.DEB.2.00.1804300946270.11756@tp.orcam.me.uk> <alpine.DEB.2.20.1804301518320.17105@digraph.polyomino.org.uk> <alpine.DEB.2.00.1804301654210.11756@tp.orcam.me.uk> <alpine.DEB.2.20.1804301935440.3035@digraph.polyomino.org.uk> <alpine.DEB.2.00.1805011247380.11756@tp.orcam.me.uk>
On Tue, 1 May 2018, Maciej W. Rozycki wrote:
> As I noted stripping the problematic symbol is IMO the best solution.
> Using `$CC -print-prog-name=strip' to discover where the right `strip'
> binary is should be a straightforward way to arrange that in a platform
> `configure' fragment. Then we can dump `_gp_disp' from .abilist files.
But adding an extra step to the process for linking shared objects (which
is in architecture-independent code; after-link is used for executables as
well as shared libraries, so doesn't seem suitable here) seems like excess
complexity here, compared to changing existing handling of absolute
symbols in abilist.awk to do something else (a net reduction in the amount
of code).
Does strip even work to remove symbols from the dynamic symbol table (as
opposed to the static symbol table)?
--
Joseph S. Myers
joseph@codesourcery.com