diff options
author | rbuj <[email protected]> | 2019-10-11 12:52:50 +0200 |
---|---|---|
committer | raveit65 <[email protected]> | 2019-10-12 13:36:25 +0200 |
commit | 21c0318f701f8ff2b4a0d183b61cb0de6b064997 (patch) | |
tree | 22ec99d514a89d37fbec5460dda80c7dfacde7a5 /configure.ac | |
parent | 316de0ff0fd92c7ed44397b7e912581250d0dd85 (diff) | |
download | mate-screensaver-21c0318f701f8ff2b4a0d183b61cb0de6b064997.tar.bz2 mate-screensaver-21c0318f701f8ff2b4a0d183b61cb0de6b064997.tar.xz |
Use WARN_CFLAGS which are only set with --enable-compiler-warnings
It removes --enable-more-warnings, since it is recommended to use
--enable-compile-warnings=maximum
It updates configure summary.
Test:
./autogen.sh --disable-silent-rules --enable-compile-warnings=maximum --prefix=/usr && make
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 45 |
1 files changed, 2 insertions, 43 deletions
diff --git a/configure.ac b/configure.ac index ee88500..ff6f819 100644 --- a/configure.ac +++ b/configure.ac @@ -14,6 +14,7 @@ m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) AC_CONFIG_HEADERS(config.h) AM_MAINTAINER_MODE +MATE_COMPILE_WARNINGS([yes]) IT_PROG_INTLTOOL([0.50.1]) AC_PROG_CC @@ -115,8 +116,6 @@ if test -z "$XMLLINT"; then AC_MSG_ERROR([xmllint not found]) fi -MATE_COMPILE_WARNINGS(yes) - # Solaris requires libresolv for daemon() case "$host" in *-*-solaris*) @@ -1053,47 +1052,6 @@ AC_SUBST(EXPANDED_DATADIR) prefix=$old_prefix exec_prefix=$old_exec_prefix -# Turn on the additional warnings last, so -Werror doesn't affect other tests. - -AC_ARG_ENABLE(more-warnings, - AC_HELP_STRING([--enable-more-warnings], [Maximum compiler warnings]), -set_more_warnings="$enableval",[ -if test -d $srcdir/.git; then - is_cvs_version=true - set_more_warnings=yes -else - set_more_warnings=no -fi -]) -AC_MSG_CHECKING(for more warnings) -if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then - AC_MSG_RESULT(yes) - CFLAGS="\ - -Wall \ - -Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes \ - -Wnested-externs -Wpointer-arith \ - -Wcast-align -Wsign-compare \ - $CFLAGS" - - for option in -Wno-strict-aliasing -Wno-sign-compare; do - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS $option" - AC_MSG_CHECKING([whether gcc understands $option]) - AC_TRY_COMPILE([], [], - has_option=yes, - has_option=no,) - if test $has_option = no; then - CFLAGS="$SAVE_CFLAGS" - fi - AC_MSG_RESULT($has_option) - unset has_option - unset SAVE_CFLAGS - done - unset option -else - AC_MSG_RESULT(no) -fi - # # Enable Debug # @@ -1177,6 +1135,7 @@ echo " source code location: ${srcdir} compiler: ${CC} cflags: ${CFLAGS} + Warning flags: ${WARN_CFLAGS} Base libs: ${MATE_SCREENSAVER_LIBS} Extension libs: ${SAVER_LIBS} Maintainer mode: ${USE_MAINTAINER_MODE} |