Mercurial > hg > nginx-quic
annotate auto/types/uintptr_t @ 192:31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Thu, 20 Nov 2003 07:05:50 +0000 |
parents | |
children | dd66383796a5 |
rev | line source |
---|---|
192
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
1 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
2 found=0 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
3 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
4 echo 'Checking for uintptr_t' |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
5 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
6 echo '#include <sys/types.h>' > autotest.c |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
7 echo 'int main() { uintptr_t i = 0; return i; }' >> autotest.c |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
8 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
9 eval "${CC} -o autotest autotest.c > /dev/null 2>&1" |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
10 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
11 if [ -x autotest ]; then |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
12 echo ' + uintptr_t found' |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
13 found=1 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
14 else |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
15 echo ' + uintptr_t not found' |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
16 fi |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
17 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
18 rm autotest* |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
19 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
20 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
21 if [ $found = 0 ]; then |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
22 echo 'int main() { printf("%d", 8 * sizeof(void *)); return 0; }' \ |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
23 > autotest.c |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
24 eval "${CC} -o autotest autotest.c > /dev/null 2>&1" |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
25 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
26 if [ -x autotest ]; then |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
27 type="uint`./autotest`_t" |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
28 echo " + $type used" |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
29 type="typedef $type uintptr_t;" |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
30 found=2 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
31 fi |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
32 fi |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
33 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
34 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
35 if [ $found = 0 ]; then |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
36 echo "$0: error: uintptr_t not found" |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
37 exit 1 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
38 fi |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
39 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
40 |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
41 if [ $found = 2 ]; then |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
42 echo $type >> ngx_auto_config.h |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
43 echo >> ngx_auto_config.h |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
44 fi |
31824be1fc66
nginx-0.0.1-2003-11-20-10:05:50 import; auto/configure
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
45 |