waf: fix WERROR_CFLAGS check
authorBjörn Jacke <bj@sernet.de>
Sat, 9 Feb 2019 00:33:13 +0000 (01:33 +0100)
committerBjoern Jacke <bjacke@samba.org>
Sun, 17 Feb 2019 12:33:14 +0000 (13:33 +0100)
if we found the right WERROR flags of the compiler then the compiler is right
to fail because we explicitly give it an empty file to compile. We
should not do that because that makes the almost successful test fail.
This fixed the studio compiler test.

Signed-off-by: Bjoern Jacke <bjacke@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
buildtools/wafsamba/wscript

index 86293d347a1cd0994969971d44a2d2ea60bcf98f..75f24158600e3361d26590b7ca2150beabe7ca08 100644 (file)
@@ -308,8 +308,7 @@ def configure(conf):
               "-qhalt=w",     # IBM xlc
               "-w2",           # Tru64
              ]:
-        if conf.CHECK_CFLAGS([f], '''
-'''):
+        if conf.CHECK_CFLAGS([f]):
             if not 'WERROR_CFLAGS' in conf.env:
                 conf.env['WERROR_CFLAGS'] = []
             conf.env['WERROR_CFLAGS'].extend([f])