2 # Copyright (C) Igor Sysoev
5 echo $ngx_n "checking for $ngx_feature ...$ngx_c"
7 cat << END >> $NGX_AUTOCONF_ERR
9 ----------------------------------------
10 checking for $ngx_feature
16 if test -n "$ngx_feature_name"; then
17 ngx_have_feature=`echo $ngx_feature_name \
18 | tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ`
21 if test -n "$ngx_feature_path"; then
22 for ngx_temp in $ngx_feature_path; do
23 ngx_feature_inc_path="$ngx_feature_inc_path -I $ngx_temp"
27 cat << END > $NGX_AUTOTEST.c
29 #include <sys/types.h>
41 ngx_test="$CC $CC_TEST_FLAGS $CC_AUX_FLAGS $ngx_feature_inc_path \
42 -o $NGX_AUTOTEST $NGX_AUTOTEST.c $NGX_LD_OPT $ngx_feature_libs"
46 eval "/bin/sh -c \"$ngx_test\" >> $NGX_AUTOCONF_ERR 2>&1"
49 if [ -x $NGX_AUTOTEST ]; then
51 case "$ngx_feature_run" in
54 # /bin/sh is used to intercept "Killed" or "Abort trap" messages
55 if /bin/sh -c $NGX_AUTOTEST >/dev/null 2>&1; then
59 if test -n "$ngx_feature_name"; then
60 have=$ngx_have_feature . auto/have
64 echo " found but is not working"
69 # /bin/sh is used to intercept "Killed" or "Abort trap" messages
70 if /bin/sh -c $NGX_AUTOTEST >/dev/null 2>&1; then
77 if test -n "$ngx_feature_name"; then
78 have=$ngx_have_feature . auto/have
87 if test -n "$ngx_feature_name"; then
88 have=$ngx_have_feature . auto/have
97 echo "----------" >> $NGX_AUTOCONF_ERR
98 cat $NGX_AUTOTEST.c >> $NGX_AUTOCONF_ERR
99 echo "----------" >> $NGX_AUTOCONF_ERR
100 echo $ngx_test >> $NGX_AUTOCONF_ERR
101 echo "----------" >> $NGX_AUTOCONF_ERR