4 # ***** BEGIN GPL LICENSE BLOCK *****
6 # This program is free software; you can redistribute it and/or
7 # modify it under the terms of the GNU General Public License
8 # as published by the Free Software Foundation; either version 2
9 # of the License, or (at your option) any later version.
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, write to the Free Software Foundation,
18 # Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 # The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
21 # All rights reserved.
23 # The Original Code is: all of this file.
25 # Contributor(s): none yet.
27 # ***** END GPL LICENSE BLOCK *****
29 # NaN compiler and linker warning levels
30 # On some platforms, you will be flooded with system include file warnings.
31 # Use hmake to filter those away.
34 # Force the correct redefinition
35 LEVEL_1_C_WARNINGS = -FIX_NAN_WARN
36 LEVEL_1_CPP_WARNINGS = -FIX_NAN_WARN
37 LEVEL_2_C_WARNINGS = -FIX_NAN_WARN
38 LEVEL_2_CPP_WARNINGS = -FIX_NAN_WARN
39 FIX_STUBS_WARNINGS = -FIX_NAN_WARN
41 ########################################################################
42 # Level 1: basic C warnings.
44 LEVEL_1_C_WARNINGS = -Wall
45 LEVEL_1_C_WARNINGS += -Wno-char-subscripts
53 # 1001 # the source file does not end w/ a newline
54 # 1110 # unreachable statement
55 # 1201 # trailing comma in enums is nonstandard
56 # 1209 # constant controlling expressions
57 # 1355 # extra semicolon is ignored
58 # 1424 # unreferenced template paramaters
59 # 1681 # virtual function override
60 # 3201 # unreferenced formal paramaters
63 LEVEL_1_C_WARNINGS = -fullwarn -woff 1001,1110,1201,1209,1355,1424,1681,3201
67 # Microsoft Compilers and cl_wrapper.pl
68 LEVEL_1_C_WARNINGS = -Wall
72 # Level 1: basic CPP warnings.
74 LEVEL_1_CPP_WARNINGS = -Wall
75 LEVEL_1_CPP_WARNINGS += -Wno-reorder
80 # see warning descriptions above
81 LEVEL_1_CPP_WARNINGS = -woff 1001,1110,1201,1209,1355,1424,1681,3201
85 # Microsoft Compilers and cl_wrapper.pl
86 LEVEL_1_CPP_WARNINGS = -Wall
90 ########################################################################
91 # Level 2: paranoia level C warnings.
92 # DO NOT REUSE LEVEL_1_ DEFINES.
94 LEVEL_2_C_WARNINGS = -Wall
95 LEVEL_2_C_WARNINGS += -W
96 # deliberately enable char-subscript warnings
97 LEVEL_2_C_WARNINGS += -Wshadow
98 LEVEL_2_C_WARNINGS += -Wpointer-arith
99 LEVEL_2_C_WARNINGS += -Wbad-function-cast
100 LEVEL_2_C_WARNINGS += -Wcast-qual
101 LEVEL_2_C_WARNINGS += -Wcast-align
102 LEVEL_2_C_WARNINGS += -Waggregate-return
103 LEVEL_2_C_WARNINGS += -Wstrict-prototypes
104 LEVEL_2_C_WARNINGS += -Wmissing-prototypes
105 LEVEL_2_C_WARNINGS += -Wmissing-declarations
106 LEVEL_2_C_WARNINGS += -Wnested-externs
107 LEVEL_2_C_WARNINGS += -Wredundant-decls
112 # see warning descriptions above
113 LEVEL_2_C_WARNINGS = -fullwarn -woff 1001,1209,1424,3201
116 # Forte / Sun WorkShop Compilers
117 LEVEL_2_C_WARNINGS = -v
121 # Microsoft Compilers and cl_wrapper.pl
122 LEVEL_2_C_WARNINGS = -Wall
126 # Level 2: paranoia level CPP warnings.
127 # DO NOT REUSE LEVEL_1_ DEFINES.
129 LEVEL_2_CPP_WARNINGS = -Wall
130 LEVEL_2_CPP_WARNINGS += -W
131 # deliberately enable char-subscript warnings
132 LEVEL_2_CPP_WARNINGS += -Wshadow
133 LEVEL_2_CPP_WARNINGS += -Wpointer-arith
134 LEVEL_2_CPP_WARNINGS += -Wcast-qual
135 LEVEL_2_CPP_WARNINGS += -Wcast-align
136 # deliberately disable aggregate-return warnings
137 LEVEL_2_CPP_WARNINGS += -Wredundant-decls
138 LEVEL_2_CPP_WARNINGS += -Wreorder
139 LEVEL_2_CPP_WARNINGS += -Wctor-dtor-privacy
140 LEVEL_2_CPP_WARNINGS += -Wnon-virtual-dtor
141 #LEVEL_2_CPP_WARNINGS += -Wold-style-cast
142 LEVEL_2_CPP_WARNINGS += -Woverloaded-virtual
143 LEVEL_2_CPP_WARNINGS += -Wsign-promo
144 LEVEL_2_CPP_WARNINGS += -Wsynth
149 # see warning descriptions above
150 LEVEL_2_CPP_WARNINGS = -fullwarn -woff 1209,1424,3201
154 # Microsoft Compilers and cl_wrapper.pl
155 LEVEL_2_CPP_WARNINGS = -Wall
159 ########################################################################
162 FIX_STUBS_WARNINGS = -Wno-unused