build/clang: fix detection of valid warning compiler flags
authorThomas Haller <thaller@redhat.com>
Sat, 26 Jul 2014 18:11:31 +0000 (20:11 +0200)
committerThomas Haller <thaller@redhat.com>
Fri, 1 Aug 2014 11:16:33 +0000 (13:16 +0200)
commit5009f2c7a3dc4ba6d197cbe62029fd2a0c78ab8a
tree12ff508773b44e17ade8568e330b3c6554a3fb71
parent1de6d83e29b43ece726f49b43aeb632543aa42be
build/clang: fix detection of valid warning compiler flags

clang does not exit with error when it is called with an
unrecognized (warning) option. Instead it just prints
a warning that makes the configure script believe the
warning is supported. Later, during build we might pass
-Werror, which causes clang to fail due to unrecognized
arguments.

Fix the script to detect compiler warnings by passing
'-Werror=unknown-warning-option', which lets clang fail too.

Signed-off-by: Thomas Haller <thaller@redhat.com>
m4/compiler_warnings.m4