This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: News MIPS option -mno-shared
- From: "Maciej W. Rozycki" <macro at linux-mips dot org>
- To: Ian Lance Taylor <ian at wasabisystems dot com>
- Cc: binutils at sourceware dot org
- Date: Thu, 9 Dec 2004 18:18:57 +0000 (GMT)
- Subject: Re: News MIPS option -mno-shared
- References: <20041209153403.5294.qmail@gossamer.airs.com>
On Thu, 9 Dec 2004, Ian Lance Taylor wrote:
> The idea is that you can use -KPIC -mno-shared and get code which
> still uses the usual Unix calling convention, but is slightly more
> efficient at each function entry. Of course, the resulting code is
> not position independent and can not be put into a shared library.
The resulting naming of options is a bit unfortunate -- -KPIC suggests
the result is PIC regardless of other options.
> Hence the name -mno-shared. (Note that nothing will prevent you from
> trying to put -mno-shared code into a shared library, but the
> resulting shared library will not work correctly.)
Shouldn't the relocations be forwarded to the .rel.dyn section upon
static linking for resolution (or complaint) by ld.so? Like it happens
for other platforms where you can build PDC shared libraries that still
work. Not that such libraries are optimal, but still better than ones
that silently break.
Maciej