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: [PATCH] add a configure option for using RELRO by default


On 19 Sep 2015 17:11, Romain Geissler wrote:
> --- a/gold/configure.ac
> +++ b/gold/configure.ac
>
> +AC_ARG_ENABLE(default-relro,
> +              [  --enable-default-relro       mark relocations read-only by default],

please use AS_HELP_STRING instead

> +[
> +  AC_DEFINE([ENABLE_DEFAULT_RELRO], [ ],
> +            [Define to mark relocations read-only by default.])
> +], [])

this is wrong for two reasons:
(1) you must check $enableval and change behavior based on that
(2) you should define it to a value like 1

you should also just omit the 4th arg

> --- a/ld/configure.ac
> +++ b/ld/configure.ac
>
> +AC_ARG_ENABLE(default-relro,
> +              [  --enable-default-relro       mark relocations read-only by default],
> +[
> +  AC_DEFINE([ENABLE_DEFAULT_RELRO], [ ],
> +            [Define to mark relocations read-only by default.])
> +], [])

same feedback here
-mike

Attachment: signature.asc
Description: Digital signature


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