build: avoid clang's colored diagnostics in the test suite

The syncline tests, which try to recognize compiler diagnostics,
are confused by escapes for colors.

* configure.ac (warn_tests): New, to factor the warnings for both
C and C++ tests.
Add -fno-color-diagnostics to it.
* tests/local.at (AT_TEST_TABLES_AND_PARSE): Do not remove glue
together compiler flags.
This commit is contained in:
Akim Demaille
2013-01-30 15:52:34 +01:00
parent 1217688141
commit df1ca1b0de
2 changed files with 16 additions and 7 deletions

View File

@@ -982,8 +982,8 @@ $9
# There is no "" around `wc` since some indent the result.
m4_bmatch([$4], [%define lr.type canonical-lr],
[if test 32767 -lt `wc -l < input.c`; then
CFLAGS=`echo " $CFLAGS " | sed -e 's/ -pedantic //'`
CXXFLAGS=`echo " $CXXFLAGS " | sed -e 's/ -pedantic //'`
CFLAGS=`echo " $CFLAGS " | sed -e 's/ -pedantic / /'`
CXXFLAGS=`echo " $CXXFLAGS " | sed -e 's/ -pedantic / /'`
fi])
AT_COMPILE([[input]])