[PVFS2-developers] configure.in and AC_PROG_CC
pw at osc.edu
Thu Jun 23 20:54:42 EDT 2005
slang at mcs.anl.gov wrote on Thu, 23 Jun 2005 15:22 -0500:
> A further caveat of all this is the --enable-strict option in
> configure, which is supposed to enable strict debugging. Right now
> it just does:
> CFLAGS += -Wall -O2 -Wstrict-prototypes -Wmissing-prototypes -Wundef
> -Wpointer-arith -Wbad-function-cast
> (so -O2 will appear twice in CFLAGS)
> Any reason for having -O2 in strict debugging?
That was probably borrowed from mpich's configure. You need some sort
of -O to catch certain warnings, like variable used before set. I tend
to compile with -O2 once in a while to catch things like that, but for
debugging purposes, no -O is of course easier to deal with.
Your propsal sounds great. One point: I would prefer to honor whatever
the user set in the environment, though. Perhaps you just didn't
mention that. If $CFLAGS starts being non-empty, don't change it at
all. I think configure may handle this already somehow.
More information about the PVFS2-developers