]> git.ipfire.org Git - thirdparty/zlib-ng.git/commitdiff
Add --warn option to ./configure, instead of environment variable.
authorMark Adler <madler@alumni.caltech.edu>
Wed, 12 Oct 2016 05:21:04 +0000 (22:21 -0700)
committerHans Kristian Rosbach <hk-git@circlestorm.org>
Wed, 1 Feb 2017 11:04:00 +0000 (12:04 +0100)
configure

index c4be2b56b76602b76a337c9130c92c729070cc72..be2dbd9bc9b8d82123da3f3aa49b210106415aeb 100755 (executable)
--- a/configure
+++ b/configure
@@ -107,6 +107,7 @@ build64=0
 without_optimizations=0
 without_new_strategies=0
 gcc=0
+warn=0
 old_cc="$CC"
 old_cflags="$CFLAGS"
 OBJC='$(OBJZ)'
@@ -160,6 +161,7 @@ case "$1" in
     --localstatedir=*) echo "ignored option: --localstatedir" | tee -a configure.log; shift ;;
     -noopt | --without-optimizations) without_optimizations=1; shift;;
     -oldstrat | --without-new-strategies) without_new_strategies=1; shift;;
+    -w* | --warn) warn=1; shift ;;
     *)
       echo "unknown option: $1" | tee -a configure.log
       echo "$0 --help for help" | tee -a configure.log
@@ -226,7 +228,7 @@ if test "$gcc" -eq 1 && ($cc -c $test.c) >> configure.log 2>&1; then
     CFLAGS="${CFLAGS} -m64"
     SFLAGS="${SFLAGS} -m64"
   fi
-  if test "${ZLIBGCCWARN}" = "YES"; then
+  if test "$warn" -eq 1; then
     CFLAGS="${CFLAGS} -Wextra -pedantic"
   fi
   if test -z "$uname"; then