This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: Understanding the default dynamic interpreter used by binutils/gcc....
- From: Ian Lance Taylor <ian at airs dot com>
- To: "Steven J. Hill" <sjhill at realitydiluted dot com>
- Cc: binutils at sources dot redhat dot com, gcc at gcc dot gnu dot org
- Date: 09 Jul 2002 13:16:21 -0700
- Subject: Re: Understanding the default dynamic interpreter used by binutils/gcc....
- References: <3D2B3B72.8030205@realitydiluted.com>
"Steven J. Hill" <sjhill@realitydiluted.com> writes:
> Would someone please just give me a quick explanation of the mechanism
> that places the final interpreter path/pathname into the output binary's
> '.interp' section. Thanks so much.
The -dynamic-linker option passed to ld overrides ld's default value
for the dynamic linker.
If gcc does not pass a -dynamic-linker option, the default will come
from ELF_INTERPRETER_NAME in the linker emulation, if it is defined.
In the sources this will be seen in the ld/emulparams file. Only a
couple of emulations define this.
Otherwise, the default will come from ELF_DYNAMIC_INTERPRETER defined
in bfd. This value is normally specified in the ELF processor
supplement, when there is one. Most free operating systems use
different values, and typically arrange for gcc to pass the right
value using the -dynamic-linker option.
Ian