This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH v2] Don't define _FORTIFY_SOURCE on mingw
- From: Eli Zaretskii <eliz at gnu dot org>
- To: Christian Biesinger <cbiesinger at google dot com>
- Cc: brobecker at adacore dot com, gdb-patches at sourceware dot org
- Date: Wed, 08 Jan 2020 05:30:23 +0200
- Subject: Re: [PATCH v2] Don't define _FORTIFY_SOURCE on mingw
- References: <CAPTJ0XHS3mhnBzUmN0X1wJZMH69V_aQQPH7Trxf9TnQMfgH0ng@mail.gmail.com> <20191218190705.161582-1-cbiesinger@google.com> <20200102113102.GA4137@adacore.com> <CAPTJ0XF91qwr6aFLZLrQ0shwws-0sCOOdr3sMyKQL-aS6zfWYQ@mail.gmail.com>
> From: "Christian Biesinger via gdb-patches" <gdb-patches@sourceware.org>
> Date: Tue, 7 Jan 2020 17:42:55 -0600
> Cc: Christian Biesinger via gdb-patches <gdb-patches@sourceware.org>
>
> > I was also thinking of adding a NEWS entry. However, IIUC, this option
> > had no effect with previous versions of MinGW? Thus, in the end,
> > this patch makes the situation stay the same regardless of MinGW
> > version, meaning no NEWS updated needed.
>
> My understanding is that this did use to work (maybe it automatically
> linked against -lssp?). But I'm not sure a NEWS entry is needed? This
> does not seem user-visible.
I think it used to work because the MinGW GCC wasn't reacting to
_FORTIFY_SOURCE, so it was largely a no-op for MinGW. This changed in
a recent version of MinGW GCC.
I'm also not sure this should be in NEWS. It depends on how MinGW
users who build GDB are sensitive to _FORTIFY_SOURCE.