This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: -Werror macro
- From: Duane Ellis <duane at duaneellis dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Sun, 25 May 2008 15:22:44 -0400
- Subject: Re: -Werror macro
- References: <1211720944.24822.ezmlm@gcc.gnu.org>
- Reply-to: duane-gcc-help at duaneellis dot com
bruno> How could I know if -Werror is set?? Is there some macro set when
it's
bruno> used or not?? I want to 'force' the use of -Werror when compiling
sources
bruno> which include some headers.
rkiesling> I had been planning such a feature in ctpp (shamless OT plug,
I know),
rkiesling> but there hasn't been any demand so far.
I too would like this feature in GCC... along with an number of other
warning flags
ie: -Wmissing-prototypes, -Wstrict-prototypes etc....
I would like to do something like this:
#if !defined(_GCC_Werror_defined)
#error Project policy and procedure requires GNU GCC -Werror be enable.
#endif
-Duane.