summaryrefslogtreecommitdiffhomepage
path: root/auto/types/uintptr_t
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2003-12-14 20:10:27 +0000
committerIgor Sysoev <igor@sysoev.ru>2003-12-14 20:10:27 +0000
commitdc867cd0fed793f86ce2b460f8c2ad069ddec1b5 (patch)
tree507db64a0a152c9ec99785a3ea887154ec4873b3 /auto/types/uintptr_t
parent2b58fbf045acee349c323de8f50501f94c41c04d (diff)
downloadnginx-dc867cd0fed793f86ce2b460f8c2ad069ddec1b5.tar.gz
nginx-dc867cd0fed793f86ce2b460f8c2ad069ddec1b5.tar.bz2
nginx-0.0.1-2003-12-14-23:10:27 import
Diffstat (limited to 'auto/types/uintptr_t')
-rw-r--r--auto/types/uintptr_t42
1 files changed, 26 insertions, 16 deletions
diff --git a/auto/types/uintptr_t b/auto/types/uintptr_t
index 7c941c0bf..eb375b08d 100644
--- a/auto/types/uintptr_t
+++ b/auto/types/uintptr_t
@@ -1,27 +1,37 @@
-echo 'checking for uintptr_t'
+echo -n "checking for uintptr_t ... "
+echo >> $NGX_ERR
+echo "checking for uintptr_t" >> $NGX_ERR
-FOUND=NO
+found=no
-echo "#include <sys/types.h>" > autotest.c
-echo "$NGX_INTTYPES_H" >> autotest.c
-echo "int main() { uintptr_t i = 0; return 0; }" >> autotest.c
+cat << END > $NGX_AUTOTEST.c
-eval "$CC -o autotest autotest.c > /dev/null 2>&1"
+#include <sys/types.h>
+$NGX_INTTYPES_H
-if [ -x autotest ]; then
- echo " + uintptr_t found"
- FOUND=YES
+int main() {
+ uintptr_t i = 0;
+ return 0;
+}
+
+END
+
+eval "$CC -o $NGX_AUTOTEST $NGX_AUTOTEST.c >> $NGX_ERR 2>&1"
+
+if [ -x $NGX_AUTOTEST ]; then
+ echo " uintptr_t found"
+ found=yes
else
- echo " + uintptr_t not found"
+ echo -n " uintptr_t not found"
fi
-rm autotest*
+rm $NGX_AUTOTEST*
+
+if [ $found = no ]; then
+ found="uint`expr 8 \* $ngx_ptr_bytes`_t"
+ echo ", $found used"
-if [ $FOUND = NO ]; then
- FOUND="uint`expr 8 \* $NGX_PTR_BYTES`_t"
- echo " + $FOUND used"
- echo "typedef $FOUND uintptr_t;" >> $NGX_AUTO_CONFIG_H
- echo >> $NGX_AUTO_CONFIG_H
+ echo "typedef $found uintptr_t;" >> $NGX_AUTO_CONFIG_H
fi