chiark / gitweb /
Add -Wundef to compiler flags (but not for gtest, sigh)
authorRoss Younger <onyx-commits@impropriety.org.uk>
Sat, 6 Apr 2013 08:40:49 +0000 (21:40 +1300)
committerRoss Younger <onyx-commits@impropriety.org.uk>
Sat, 6 Apr 2013 08:40:49 +0000 (21:40 +1300)
Makefile.am
configure.ac

index fa5a8cf..d2dcfbb 100644 (file)
@@ -98,6 +98,7 @@ check_LIBRARIES+=libgtest.a
 nodist_libgtest_a_SOURCES= $(GTEST)/gtest_main.cc $(GTEST)/gtest-all.cc
 
 libgtest_a_CPPFLAGS= -I$(GTEST_INC) -I$(GTEST_SRC)
+libgtest_a_CXXFLAGS= $(AM_CPPFLAGS) -Wno-undef
 # Yes, include GTEST_SRC, because gtest-all includes some .cc files ...
 endif
 
index 50278b6..6b0a609 100644 (file)
@@ -21,7 +21,7 @@ pkg_cflags=""
 pkg_cxxflags="-std=c++0x"
 AC_DEFINE([_GNU_SOURCE], [1], [use GNU extensions])
 if test "x$GXX" = xyes; then
-       pkg_cxxflags="${pkg_cxxflags} -Wall -Wextra -Werror -Wpointer-arith -Wwrite-strings -Woverloaded-virtual -Wnon-virtual-dtor -Wctor-dtor-privacy -Wstrict-null-sentinel -Wnon-template-friend -Woverloaded-virtual -Wpmf-conversions -Wsign-promo"
+       pkg_cxxflags="${pkg_cxxflags} -Wall -Wextra -Werror -Wpointer-arith -Wwrite-strings -Woverloaded-virtual -Wnon-virtual-dtor -Wctor-dtor-privacy -Wstrict-null-sentinel -Wnon-template-friend -Woverloaded-virtual -Wpmf-conversions -Wsign-promo -Wundef"
 fi
 if test "x$GCC" = xyes; then
        pkg_cflags="${pkg_cflags} -Wall -Wextra -Werror -Wpointer-arith -Wwrite-strings"