+2015-12-16 Pedro Alves <palves@redhat.com>
+
+ * configure.ac (compiler warning flags): When testing a
+ -Wno-foo option, check whether -Wfoo works instead.
+ * configure: Regenerate.
+
2015-12-16 Pedro Alves <palves@redhat.com>
* common/vec.h (vec_offset): New macro.
# Separate out the -Werror flag as some files just cannot be
# compiled with it enabled.
for w in ${build_warnings}; do
+ # GCC does not complain about -Wno-unknown-warning. Invert
+ # and test -Wunknown-warning instead.
+ case $w in
+ -Wno-*)
+ wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
+ *)
+ wtest=$w ;;
+ esac
+
case $w in
-Werr*) WERROR_CFLAGS=-Werror ;;
*)
# Check whether GCC accepts it.
saved_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $w"
+ CFLAGS="$CFLAGS $wtest"
saved_CXXFLAGS="$CXXFLAGS"
- CXXFLAGS="$CXXFLAGS $w"
+ CXXFLAGS="$CXXFLAGS $wtest"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
# Separate out the -Werror flag as some files just cannot be
# compiled with it enabled.
for w in ${build_warnings}; do
+ # GCC does not complain about -Wno-unknown-warning. Invert
+ # and test -Wunknown-warning instead.
+ case $w in
+ -Wno-*)
+ wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
+ *)
+ wtest=$w ;;
+ esac
+
case $w in
-Werr*) WERROR_CFLAGS=-Werror ;;
*)
# Check whether GCC accepts it.
saved_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $w"
+ CFLAGS="$CFLAGS $wtest"
saved_CXXFLAGS="$CXXFLAGS"
- CXXFLAGS="$CXXFLAGS $w"
+ CXXFLAGS="$CXXFLAGS $wtest"
AC_TRY_COMPILE([],[],WARN_CFLAGS="${WARN_CFLAGS} $w",)
CFLAGS="$saved_CFLAGS"
CXXFLAGS="$saved_CXXFLAGS"
+2015-12-16 Pedro Alves <palves@redhat.com>
+
+ * configure.ac (compiler warning flags): When testing a
+ -Wno-foo option, check whether -Wfoo works instead.
+ * configure: Regenerate.
+
2015-12-11 Don Breazeal <donb@codesourcery.com>
* server.c (process_serial_event): Don't exit from gdbserver
# Separate out the -Werror flag as some files just cannot be
# compiled with it enabled.
for w in ${build_warnings}; do
+ # GCC does not complain about -Wno-unknown-warning. Invert
+ # and test -Wunknown-warning instead.
+ case $w in
+ -Wno-*)
+ wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
+ *)
+ wtest=$w ;;
+ esac
+
case $w in
-Werr*) WERROR_CFLAGS=-Werror ;;
*)
# Check whether GCC accepts it.
saved_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $w"
+ CFLAGS="$CFLAGS $wtest"
saved_CXXFLAGS="$CXXFLAGS"
- CXXFLAGS="$CXXFLAGS $w"
+ CXXFLAGS="$CXXFLAGS $wtest"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
# Separate out the -Werror flag as some files just cannot be
# compiled with it enabled.
for w in ${build_warnings}; do
+ # GCC does not complain about -Wno-unknown-warning. Invert
+ # and test -Wunknown-warning instead.
+ case $w in
+ -Wno-*)
+ wtest=`echo $w | sed 's/-Wno-/-W/g'` ;;
+ *)
+ wtest=$w ;;
+ esac
+
case $w in
-Werr*) WERROR_CFLAGS=-Werror ;;
*)
# Check whether GCC accepts it.
saved_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $w"
+ CFLAGS="$CFLAGS $wtest"
saved_CXXFLAGS="$CXXFLAGS"
- CXXFLAGS="$CXXFLAGS $w"
+ CXXFLAGS="$CXXFLAGS $wtest"
AC_TRY_COMPILE([],[],WARN_CFLAGS="${WARN_CFLAGS} $w",)
CFLAGS="$saved_CFLAGS"
CXXFLAGS="$saved_CXXFLAGS"