RFC src/configure* - "CFLAGS=-g -O" instead of "CFLAGS=... -Wall"
Tue Apr 4 17:16:00 GMT 2000
Geoff Keating wrote:
> > Date: Wed, 05 Apr 2000 09:53:42 +1000
> > From: Andrew Cagney <firstname.lastname@example.org>
> > Organization: Cygnus Solutions
> > X-Accept-Language: en
> > Hello,
> > At present the top level configure + Makefile.in force (when GCC) CFLAGS
> > to:
> > CFLAGS = -g -O -Wall
> > I'd like to scale that back to just:
> > CFLAGS = -g -O
> > letting each sub directory set their own -W* policy. The src/gdb and
> > src/sim directories try to do this now using separate WARN_CFLAGS (only
> > they get overuled by CFLAGS :-).
> GCC has
> CFLAGS = -g @stage1_warn_cflags@
> WARN_CFLAGS = -W -Wall -Wtraditional
> where @stage1_warn_cflags@ gets turned into $(WARN_CFLAGS), or not,
> depending on whether the compiler is GCC. This also gets overruled
> from the toplevel CFLAGS, which is probably why the -Wall is there.
I believe ALL the subdirectory CFLAGS are overruled by the
toplevel CFLAGS. If we make this change, then in order to
get the -Wall behavior, it will be necessary to run make
from the subdirectory, or pass CFLAGS in to make.
More information about the Newlib