This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Question on use of relro, now, and nodlopen


Jeffrey Walton <noloader@gmail.com> writes:

> How does the team recommend determining the availability of relro,
> now, and nodlopen?
>
> Formerly, I was using the following in my makefile (which I suspect is
> wrong even though there's a tight coupling between GCC and Binutils).
> OpenSolaris proved that its possible to ship a 2004 compiler with a
> 2010 distribution.
>
> GCC_COMPILER = $(shell $(CXX) -v 2>&1 | $(EGREP) -i -c "^gcc version")
> ...
> ifneq ($(GCC_COMPILER),0)
>   LDFLAGS +=	-Wl,-z,relro -Wl,-z,now -Wl,-z,nodlopen
> endif
>
> Is there a matrix of tool/feature/version that would help determine
> when the flags made it into ld?

I didn't quite get that that was your question earlier.

To determine whether the linker supports a particular option, look at
the output of ld --help.

Ideally each new option would be listed in the ld/NEWS file in the
source code.  Unfortunately I checked each of the options you mentioned,
and none are listed.  As far as I know, the only other source of this
kind of information is the ld ChangeLog files.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]