This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: Qustion about compile gdb-6.71. and gdb-6.8 error
- From: Paul Pluzhnikov <ppluzhnikov at google dot com>
- To: loody <miloody at gmail dot com>
- Cc: gdb at sourceware dot org
- Date: Mon, 22 Jun 2009 09:07:45 -0700
- Subject: Re: Qustion about compile gdb-6.71. and gdb-6.8 error
- References: <3a665c760906220630g24fa38ema81029cc9c52fb43@mail.gmail.com>
On Mon, Jun 22, 2009 at 6:30 AM, loody<miloody@gmail.com> wrote:
> I try to compile gdb but I get error message below:
> linux-nat.c:2834: error: ignoring return value of \u2018fgets\u2019,
> declared with attribute warn_unused_result
Current GDB sources do not contain fgets() call at that line.
> I know this error comes from my gcc waring option -Werror like below:
...
> Why we add -Werror here
Because it helps catch bugs.
> how can we compile it successfully except removing this option?
If you don't plan on modifying GDB sources, just remove the -Werror.
If you do, please use current sources from CVS Head.
Cheers,
--
Paul Pluzhnikov