1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

waf: use the correct WERROR_CFLAGS in CHECK_CODE

all the non gcc version were incorrectly set here till now

Signed-off-by: Bjoern Jacke <bjacke@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
This commit is contained in:
Björn Jacke 2019-02-10 01:29:22 +01:00 committed by Bjoern Jacke
parent 99dd2ae810
commit 918bf89dc7

View File

@ -397,13 +397,8 @@ def CHECK_CODE(conf, code, define,
# Be strict when relying on a compiler check
# Some compilers (e.g. xlc) ignore non-supported features as warnings
if strict:
extra_cflags = None
if conf.env["CC_NAME"] == "gcc":
extra_cflags = "-Werror"
elif conf.env["CC_NAME"] == "xlc":
extra_cflags = "-qhalt=w"
if extra_cflags:
cflags.append(extra_cflags)
if 'WERROR_CFLAGS' in conf.env:
cflags.extend(conf.env['WERROR_CFLAGS'])
if local_include:
cflags.append('-I%s' % conf.path.abspath())