From: Eric Blake Date: Thu, 6 Sep 2012 14:20:17 +0000 (-0600) Subject: build: default to --enable-gcc-warnings for git tree X-Git-Tag: v8.20~63 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=47fd706a7540e7ae3d19c625d90c28b88a8a640c;p=thirdparty%2Fcoreutils.git build: default to --enable-gcc-warnings for git tree Anyone developing on coreutils can be assumed to have a new enough environment, such that enabling gcc warnings by default will be useful. Tarballs still default to no warnings, and the defaults can still be overridden with --disable-gcc-warnings. * configure.ac (gl_gcc_warnings): Set default based on environment. Suggested by Bernhard Voelker. --- diff --git a/configure.ac b/configure.ac index d087c33b50..e1aa6caf1c 100644 --- a/configure.ac +++ b/configure.ac @@ -75,7 +75,11 @@ AC_ARG_ENABLE([gcc-warnings], *) AC_MSG_ERROR([bad value $enableval for gcc-warnings option]) ;; esac gl_gcc_warnings=$enableval], - [gl_gcc_warnings=no] + [if test -d "$srcdir"/.git; then + gl_gcc_warnings=yes + else + gl_gcc_warnings=no + fi] ) # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])