Update and clean Tomato RAF files
[tomato.git] / release / src / router / nginx / auto / types / uintptr_t
blob2f19080352b14b24d71e06c5e3c3b9356ba3ce0a
2 # Copyright (C) Igor Sysoev
3 # Copyright (C) Nginx, Inc.
6 echo $ngx_n "checking for uintptr_t ...$ngx_c"
7 echo >> $NGX_AUTOCONF_ERR
8 echo "checking for uintptr_t" >> $NGX_AUTOCONF_ERR
10 found=no
12 cat << END > $NGX_AUTOTEST.c
14 #include <sys/types.h>
15 $NGX_INTTYPES_H
17 int main() {
18     uintptr_t i = 0;
19     return (int) i;
22 END
24 ngx_test="$CC $CC_TEST_FLAGS $CC_AUX_FLAGS \
25           -o $NGX_AUTOTEST $NGX_AUTOTEST.c $NGX_LD_OPT"
27 eval "$ngx_test >> $NGX_AUTOCONF_ERR 2>&1"
29 if [ -x $NGX_AUTOTEST ]; then
30     echo " uintptr_t found"
31     found=yes
32 else
33     echo $ngx_n " uintptr_t not found" $ngx_c
36 rm $NGX_AUTOTEST*
39 if [ $found = no ]; then
40     found="uint`expr 8 \* $ngx_ptr_size`_t"
41     echo ", $found used"
43     echo "typedef $found  uintptr_t;"                   >> $NGX_AUTO_CONFIG_H
44     echo "typedef $found  intptr_t;" | sed -e 's/u//g'  >> $NGX_AUTO_CONFIG_H