This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Patch to correct LINK_PIE_SPEC
On Mon, Nov 15, 2004 at 05:38:44PM +0100, Peter S. Mazinger wrote:
> On Mon, 15 Nov 2004, Daniel Jacobowitz wrote:
> >
> > Please read the documentation of the options whose behavior you are
> > changing.
> >
> > `-nostartfiles'
> > Do not use the standard system startup files when linking. The
> > standard system libraries are used normally, unless `-nostdlib' or
> > `-nodefaultlibs' is used.
> >
> > `-nostdlib'
> > Do not use the standard system startup files or libraries when
> > linking. No startup files and only the libraries you specify will
> > be passed to the linker.
> >
> > Where do you see any justification for these options affecting the
> > linker arguments, other than libraries or startfiles?
>
> Sorry, I do not change nostdlib/nostartfiles behaviour, I use these as
> exclusion for -pie. If we provide -nostartfiles, the Scrt1.o file won't be
> provided and a PIE executable can't be built
Actually, you are changing the behavior of -nostdlib. Before, it would
not inhibit passing pie. Now, it will. It shouldn't.
A working non-PIE executable can't be built with -nostdlib either,
unless you provide _start. That's what the option is for: to let you
do that.
--
Daniel Jacobowitz