[mutter] configure.ac: move CFLAGS modifications after all tests
- From: Owen Taylor <otaylor src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] configure.ac: move CFLAGS modifications after all tests
- Date: Mon, 22 Nov 2010 15:50:15 +0000 (UTC)
commit 54e82daae28990deba8b0b2a4735098ca18fcf31
Author: Owen W. Taylor <otaylor fishsoup net>
Date: Mon Nov 22 09:50:47 2010 -0500
configure.ac: move CFLAGS modifications after all tests
-Werror in CFLAGS was causing the check for GNU gettext in
AM_GNU_GLIB_GETTEXT to fail, resulting in .mo files in $libdir.
https://bugzilla.gnome.org/show_bug.cgi?id=635528
configure.in | 132 +++++++++++++++++++++++++++++-----------------------------
1 files changed, 66 insertions(+), 66 deletions(-)
---
diff --git a/configure.in b/configure.in
index ff266ae..09d1f63 100644
--- a/configure.in
+++ b/configure.in
@@ -61,72 +61,6 @@ AC_CHECK_SIZEOF(__int64)
## byte order
AC_C_BIGENDIAN
-#### Warnings
-
-# Stay command-line compatible with the gnome-common configure option. Here
-# minimum/yes/maximum are the same, however.
-AC_ARG_ENABLE(compile_warnings,
- AS_HELP_STRING([--enable-compile-warnings=@<:@no/minimum/yes/maximum/error@:>@],[Turn on compiler warnings]),,
- enable_compile_warnings=error)
-
-changequote(,)dnl
-if test "$enable_compile_warnings" != no ; then
- if test "x$GCC" = "xyes"; then
- case " $CFLAGS " in
- *[\ \ ]-Wall[\ \ ]*) ;;
- *) CFLAGS="$CFLAGS -Wall" ;;
- esac
-
-# case " $CFLAGS " in
-# *[\ \ ]-Wshadow[\ \ ]*) ;;
-# *) CFLAGS="$CFLAGS -Wshadow" ;;
-# esac
-
- case " $CFLAGS " in
- *[\ \ ]-Wchar-subscripts[\ \ ]*) ;;
- *) CFLAGS="$CFLAGS -Wchar-subscripts" ;;
- esac
-
- case " $CFLAGS " in
- *[\ \ ]-Wmissing-declarations[\ \ ]*) ;;
- *) CFLAGS="$CFLAGS -Wmissing-declarations" ;;
- esac
-
- case " $CFLAGS " in
- *[\ \ ]-Wmissing-prototypes[\ \ ]*) ;;
- *) CFLAGS="$CFLAGS -Wmissing-prototypes" ;;
- esac
-
- case " $CFLAGS " in
- *[\ \ ]-Wnested-externs[\ \ ]*) ;;
- *) CFLAGS="$CFLAGS -Wnested-externs" ;;
- esac
-
- case " $CFLAGS " in
- *[\ \ ]-Wpointer-arith[\ \ ]*) ;;
- *) CFLAGS="$CFLAGS -Wpointer-arith" ;;
- esac
-
- case " $CFLAGS " in
- *[\ \ ]-Wcast-align[\ \ ]*) ;;
- *) CFLAGS="$CFLAGS -Wcast-align" ;;
- esac
-
- case " $CFLAGS " in
- *[\ \ ]-Wsign-compare[\ \ ]*) ;;
- *) CFLAGS="$CFLAGS -Wsign-compare" ;;
- esac
-
- if test "$enable_compile_warnings" = error; then
- case " $CFLAGS " in
- *[\ \ ]-Werror[\ \ ]*) ;;
- *) CFLAGS="$CFLAGS -Werror" ;;
- esac
- fi
- fi
-fi
-changequote([,])dnl
-
GTK_MIN_VERSION=2.90.7
CANBERRA_GTK=libcanberra-gtk3
CANBERRA_GTK_VERSION=0.26
@@ -518,6 +452,72 @@ AM_PATH_PYTHON([2.5])
# Use gnome-doc-utils:
GNOME_DOC_INIT([0.8.0])
+#### Warnings (last since -Werror can disturb other tests)
+
+# Stay command-line compatible with the gnome-common configure option. Here
+# minimum/yes/maximum are the same, however.
+AC_ARG_ENABLE(compile_warnings,
+ AS_HELP_STRING([--enable-compile-warnings=@<:@no/minimum/yes/maximum/error@:>@],[Turn on compiler warnings]),,
+ enable_compile_warnings=error)
+
+changequote(,)dnl
+if test "$enable_compile_warnings" != no ; then
+ if test "x$GCC" = "xyes"; then
+ case " $CFLAGS " in
+ *[\ \ ]-Wall[\ \ ]*) ;;
+ *) CFLAGS="$CFLAGS -Wall" ;;
+ esac
+
+# case " $CFLAGS " in
+# *[\ \ ]-Wshadow[\ \ ]*) ;;
+# *) CFLAGS="$CFLAGS -Wshadow" ;;
+# esac
+
+ case " $CFLAGS " in
+ *[\ \ ]-Wchar-subscripts[\ \ ]*) ;;
+ *) CFLAGS="$CFLAGS -Wchar-subscripts" ;;
+ esac
+
+ case " $CFLAGS " in
+ *[\ \ ]-Wmissing-declarations[\ \ ]*) ;;
+ *) CFLAGS="$CFLAGS -Wmissing-declarations" ;;
+ esac
+
+ case " $CFLAGS " in
+ *[\ \ ]-Wmissing-prototypes[\ \ ]*) ;;
+ *) CFLAGS="$CFLAGS -Wmissing-prototypes" ;;
+ esac
+
+ case " $CFLAGS " in
+ *[\ \ ]-Wnested-externs[\ \ ]*) ;;
+ *) CFLAGS="$CFLAGS -Wnested-externs" ;;
+ esac
+
+ case " $CFLAGS " in
+ *[\ \ ]-Wpointer-arith[\ \ ]*) ;;
+ *) CFLAGS="$CFLAGS -Wpointer-arith" ;;
+ esac
+
+ case " $CFLAGS " in
+ *[\ \ ]-Wcast-align[\ \ ]*) ;;
+ *) CFLAGS="$CFLAGS -Wcast-align" ;;
+ esac
+
+ case " $CFLAGS " in
+ *[\ \ ]-Wsign-compare[\ \ ]*) ;;
+ *) CFLAGS="$CFLAGS -Wsign-compare" ;;
+ esac
+
+ if test "$enable_compile_warnings" = error; then
+ case " $CFLAGS " in
+ *[\ \ ]-Werror[\ \ ]*) ;;
+ *) CFLAGS="$CFLAGS -Werror" ;;
+ esac
+ fi
+ fi
+fi
+changequote([,])dnl
+
AC_CONFIG_FILES([
Makefile
doc/Makefile
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]