diff options
Diffstat (limited to 'auto')
-rw-r--r-- | auto/options | 4 | ||||
-rw-r--r-- | auto/summary | 1 | ||||
-rw-r--r-- | auto/zlib | 39 |
3 files changed, 30 insertions, 14 deletions
diff --git a/auto/options b/auto/options index 0550c699..ef0459f3 100644 --- a/auto/options +++ b/auto/options @@ -20,6 +20,8 @@ NXT_PCRE_LIB= NXT_REGEX=YES NXT_TRY_PCRE2=YES +NXT_ZLIB=YES + NXT_TLS=NO NXT_OPENSSL=NO NXT_GNUTLS=NO @@ -104,6 +106,8 @@ do --no-regex) NXT_REGEX=NO ;; --no-pcre2) NXT_TRY_PCRE2=NO ;; + --no-zlib) NXT_ZLIB=NO ;; + --openssl) NXT_OPENSSL=YES ;; --gnutls) NXT_GNUTLS=YES ;; --cyassl) NXT_CYASSL=YES ;; diff --git a/auto/summary b/auto/summary index 3aa41669..0e87b88a 100644 --- a/auto/summary +++ b/auto/summary @@ -29,6 +29,7 @@ Unit configuration summary: Unix domain sockets support: $NXT_UNIX_DOMAIN TLS support: ............... $NXT_OPENSSL Regex support: ............. $NXT_REGEX + zlib support: .............. $NXT_ZLIB NJS support: ............... $NXT_NJS process isolation: ......... $NXT_ISOLATION @@ -3,21 +3,32 @@ # Copyright (C) NGINX, Inc. -NXT_ZLIB_CFLAGS="$(pkgconf --cflags-only-I zlib 2>/dev/null || echo "")" -NXT_ZLIB_LIBS="$(pkgconf --libs zlib 2>/dev/null || echo "-lz")" +NXT_HAVE_ZLIB=no +NXT_ZLIB_CFLAGS= +NXT_ZLIB_LIBS= -nxt_feature="zlib" -nxt_feature_name=NXT_HAVE_ZLIB -nxt_feature_run=no -nxt_feature_incs=$NXT_ZLIB_CFLAGS -nxt_feature_libs=$NXT_ZLIB_LIBS -nxt_feature_test="#include <stdio.h> +if [ $NXT_ZLIB = YES ]; then - #include <zlib.h> + NXT_ZLIB_CFLAGS="$(pkgconf --cflags-only-I zlib 2>/dev/null || echo "")" + NXT_ZLIB_LIBS="$(pkgconf --libs zlib 2>/dev/null || echo "-lz")" - int main(void) { - puts(zlibVersion()); - return 0; - }" -. auto/feature + nxt_feature="zlib" + nxt_feature_name=NXT_HAVE_ZLIB + nxt_feature_run=no + nxt_feature_incs=$NXT_ZLIB_CFLAGS + nxt_feature_libs=$NXT_ZLIB_LIBS + nxt_feature_test="#include <stdio.h> + + #include <zlib.h> + + int main(void) { + puts(zlibVersion()); + return 0; + }" + . auto/feature + + if [ $nxt_found = yes ]; then + NXT_HAVE_ZLIB=YES + fi +fi |