mirror of https://github.com/ArduPilot/ardupilot
waf: Enable werror on sitl for gcc
Signed-off-by: Ryan Friedman <ryanfriedman5410+github@gmail.com>
This commit is contained in:
parent
33c1e23e55
commit
819f93b778
|
@ -775,6 +775,18 @@ class sitl(Board):
|
|||
'-m32',
|
||||
]
|
||||
|
||||
# whitelist of compilers which we should build with -Werror
|
||||
gcc_whitelist = frozenset([
|
||||
('11','3','0'),
|
||||
])
|
||||
|
||||
if cfg.options.Werror or cfg.env.CC_VERSION in gcc_whitelist:
|
||||
cfg.msg("Enabling -Werror", "yes")
|
||||
if '-Werror' not in env.CXXFLAGS:
|
||||
env.CXXFLAGS += [ '-Werror' ]
|
||||
else:
|
||||
cfg.msg("Enabling -Werror", "no")
|
||||
|
||||
def get_name(self):
|
||||
return self.__class__.__name__
|
||||
|
||||
|
|
Loading…
Reference in New Issue