Mercurial > hg > nginx
annotate auto/unix @ 5312:ec8594b9bf11
Core: only resolve address families configured on the local system.
This is done by passing AI_ADDRCONFIG to getaddrinfo().
On Linux, setting net.ipv6.conf.all.disable_ipv6 to 1 will now be
respected.
On FreeBSD, AI_ADDRCONFIG filtering is currently implemented by
attempting to create a datagram socket for the corresponding family,
which succeeds even if the system doesn't in fact have any addresses
of that family configured. That is, if the system with IPv6 support
in the kernel doesn't have IPv6 addresses configured, AI_ADDRCONFIG
will filter out IPv6 only inside a jail without IPv6 addresses or
with IPv6 disabled.
author | Ruslan Ermilov <ru@nginx.com> |
---|---|
date | Mon, 05 Aug 2013 10:55:59 +0400 |
parents | eaf95350d75c |
children | 0300d97c6084 |
rev | line source |
---|---|
444
42d11f017717
nginx-0.1.0-2004-09-29-20:00:49 import; remove years from copyright
Igor Sysoev <igor@sysoev.ru>
parents:
417
diff
changeset
|
1 |
42d11f017717
nginx-0.1.0-2004-09-29-20:00:49 import; remove years from copyright
Igor Sysoev <igor@sysoev.ru>
parents:
417
diff
changeset
|
2 # Copyright (C) Igor Sysoev |
4412 | 3 # Copyright (C) Nginx, Inc. |
444
42d11f017717
nginx-0.1.0-2004-09-29-20:00:49 import; remove years from copyright
Igor Sysoev <igor@sysoev.ru>
parents:
417
diff
changeset
|
4 |
195
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
5 |
3933
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
6 NGX_USER=${NGX_USER:-nobody} |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
7 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
8 if [ -z "$NGX_GROUP" ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
9 if [ $NGX_USER = nobody ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
10 if grep nobody /etc/group 2>&1 >/dev/null; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
11 echo "checking for nobody group ... found" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
12 NGX_GROUP=nobody |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
13 else |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
14 echo "checking for nobody group ... not found" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
15 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
16 if grep nogroup /etc/group 2>&1 >/dev/null; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
17 echo "checking for nogroup group ... found" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
18 NGX_GROUP=nogroup |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
19 else |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
20 echo "checking for nogroup group ... not found" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
21 NGX_GROUP=nobody |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
22 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
23 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
24 else |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
25 NGX_GROUP=$NGX_USER |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
26 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
27 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
28 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
29 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
30 ngx_feature="poll()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
31 ngx_feature_name= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
32 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
33 ngx_feature_incs="#include <poll.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
34 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
35 ngx_feature_libs= |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
36 ngx_feature_test="int n; struct pollfd pl; |
3933
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
37 pl.fd = 0; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
38 pl.events = 0; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
39 pl.revents = 0; |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
40 n = poll(&pl, 1, 0); |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
41 if (n == -1) return 1" |
3933
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
42 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
43 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
44 if [ $ngx_found = no ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
45 EVENT_POLL=NONE |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
46 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
47 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
48 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
49 ngx_feature="/dev/poll" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
50 ngx_feature_name="NGX_HAVE_DEVPOLL" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
51 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
52 ngx_feature_incs="#include <sys/devpoll.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
53 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
54 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
55 ngx_feature_test="int n, dp; struct dvpoll dvp; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
56 dp = 0; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
57 dvp.dp_fds = NULL; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
58 dvp.dp_nfds = 0; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
59 dvp.dp_timeout = 0; |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
60 n = ioctl(dp, DP_POLL, &dvp); |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
61 if (n == -1) return 1" |
3933
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
62 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
63 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
64 if [ $ngx_found = yes ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
65 CORE_SRCS="$CORE_SRCS $DEVPOLL_SRCS" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
66 EVENT_MODULES="$EVENT_MODULES $DEVPOLL_MODULE" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
67 EVENT_FOUND=YES |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
68 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
69 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
70 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
71 if test -z "$NGX_KQUEUE_CHECKED"; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
72 ngx_feature="kqueue" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
73 ngx_feature_name="NGX_HAVE_KQUEUE" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
74 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
75 ngx_feature_incs="#include <sys/event.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
76 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
77 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
78 ngx_feature_test="int kq; kq = kqueue()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
79 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
80 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
81 if [ $ngx_found = yes ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
82 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
83 have=NGX_HAVE_CLEAR_EVENT . auto/have |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
84 EVENT_MODULES="$EVENT_MODULES $KQUEUE_MODULE" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
85 CORE_SRCS="$CORE_SRCS $KQUEUE_SRCS" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
86 EVENT_FOUND=YES |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
87 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
88 ngx_feature="kqueue's NOTE_LOWAT" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
89 ngx_feature_name="NGX_HAVE_LOWAT_EVENT" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
90 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
91 ngx_feature_incs="#include <sys/event.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
92 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
93 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
94 ngx_feature_test="struct kevent kev; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
95 kev.fflags = NOTE_LOWAT;" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
96 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
97 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
98 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
99 ngx_feature="kqueue's EVFILT_TIMER" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
100 ngx_feature_name="NGX_HAVE_TIMER_EVENT" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
101 ngx_feature_run=yes |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
102 ngx_feature_incs="#include <sys/event.h> |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
103 #include <sys/time.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
104 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
105 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
106 ngx_feature_test="int kq; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
107 struct kevent kev; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
108 struct timespec ts; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
109 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
110 if ((kq = kqueue()) == -1) return 1; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
111 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
112 kev.ident = 0; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
113 kev.filter = EVFILT_TIMER; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
114 kev.flags = EV_ADD|EV_ENABLE; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
115 kev.fflags = 0; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
116 kev.data = 1000; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
117 kev.udata = 0; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
118 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
119 ts.tv_sec = 0; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
120 ts.tv_nsec = 0; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
121 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
122 if (kevent(kq, &kev, 1, &kev, 1, &ts) == -1) return 1; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
123 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
124 if (kev.flags & EV_ERROR) return 1;" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
125 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
126 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
127 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
128 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
129 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
130 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
131 if [ "$NGX_SYSTEM" = "NetBSD" ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
132 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
133 # NetBSD 2.0 incompatibly defines kevent.udata as "intptr_t" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
134 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
135 cat << END >> $NGX_AUTO_CONFIG_H |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
136 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
137 #define NGX_KQUEUE_UDATA_T |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
138 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
139 END |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
140 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
141 else |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
142 cat << END >> $NGX_AUTO_CONFIG_H |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
143 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
144 #define NGX_KQUEUE_UDATA_T (void *) |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
145 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
146 END |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
147 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
148 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
149 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
150 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
151 ngx_feature="crypt()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
152 ngx_feature_name= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
153 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
154 ngx_feature_incs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
155 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
156 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
157 ngx_feature_test="crypt(\"test\", \"salt\");" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
158 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
159 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
160 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
161 if [ $ngx_found = no ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
162 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
163 ngx_feature="crypt() in libcrypt" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
164 ngx_feature_name= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
165 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
166 ngx_feature_incs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
167 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
168 ngx_feature_libs=-lcrypt |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
169 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
170 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
171 if [ $ngx_found = yes ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
172 CRYPT_LIB="-lcrypt" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
173 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
174 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
175 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
176 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
177 ngx_feature="F_READAHEAD" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
178 ngx_feature_name="NGX_HAVE_F_READAHEAD" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
179 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
180 ngx_feature_incs="#include <fcntl.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
181 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
182 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
183 ngx_feature_test="fcntl(0, F_READAHEAD, 1);" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
184 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
185 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
186 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
187 ngx_feature="posix_fadvise()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
188 ngx_feature_name="NGX_HAVE_POSIX_FADVISE" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
189 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
190 ngx_feature_incs="#include <fcntl.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
191 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
192 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
193 ngx_feature_test="posix_fadvise(0, 0, 0, POSIX_FADV_SEQUENTIAL);" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
194 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
195 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
196 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
197 ngx_feature="O_DIRECT" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
198 ngx_feature_name="NGX_HAVE_O_DIRECT" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
199 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
200 ngx_feature_incs="#include <fcntl.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
201 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
202 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
203 ngx_feature_test="fcntl(0, F_SETFL, O_DIRECT);" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
204 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
205 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
206 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
207 if [ $ngx_found = yes -a "$NGX_SYSTEM" = "Linux" ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
208 have=NGX_HAVE_ALIGNED_DIRECTIO . auto/have |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
209 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
210 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
211 ngx_feature="F_NOCACHE" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
212 ngx_feature_name="NGX_HAVE_F_NOCACHE" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
213 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
214 ngx_feature_incs="#include <fcntl.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
215 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
216 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
217 ngx_feature_test="fcntl(0, F_NOCACHE, 1);" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
218 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
219 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
220 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
221 ngx_feature="directio()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
222 ngx_feature_name="NGX_HAVE_DIRECTIO" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
223 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
224 ngx_feature_incs="#include <sys/types.h> |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
225 #include <sys/fcntl.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
226 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
227 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
228 ngx_feature_test="directio(0, DIRECTIO_ON);" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
229 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
230 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
231 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
232 ngx_feature="statfs()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
233 ngx_feature_name="NGX_HAVE_STATFS" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
234 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
235 ngx_feature_incs="$NGX_INCLUDE_SYS_PARAM_H |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
236 $NGX_INCLUDE_SYS_MOUNT_H |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
237 $NGX_INCLUDE_SYS_VFS_H" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
238 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
239 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
240 ngx_feature_test="struct statfs fs; |
4543
51744fa997c7
Fixed compilation warnings in configuration C tests.
Ruslan Ermilov <ru@nginx.com>
parents:
4475
diff
changeset
|
241 statfs(\".\", &fs);" |
3933
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
242 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
243 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
244 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
245 ngx_feature="statvfs()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
246 ngx_feature_name="NGX_HAVE_STATVFS" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
247 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
248 ngx_feature_incs="#include <sys/types.h> |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
249 #include <sys/statvfs.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
250 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
251 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
252 ngx_feature_test="struct statvfs fs; |
4543
51744fa997c7
Fixed compilation warnings in configuration C tests.
Ruslan Ermilov <ru@nginx.com>
parents:
4475
diff
changeset
|
253 statvfs(\".\", &fs);" |
3933
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
254 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
255 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
256 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
257 ngx_feature="dlopen()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
258 ngx_feature_name= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
259 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
260 ngx_feature_incs="#include <dlfcn.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
261 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
262 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
263 ngx_feature_test="dlopen(NULL, 0)" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
264 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
265 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
266 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
267 if [ $ngx_found != yes ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
268 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
269 ngx_feature="dlopen() in libdl" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
270 ngx_feature_libs="-ldl" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
271 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
272 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
273 if [ $ngx_found = yes ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
274 NGX_LIBDL="-ldl" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
275 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
276 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
277 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
278 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
279 ngx_feature="sched_yield()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
280 ngx_feature_name="NGX_HAVE_SCHED_YIELD" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
281 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
282 ngx_feature_incs="#include <sched.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
283 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
284 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
285 ngx_feature_test="sched_yield()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
286 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
287 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
288 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
289 if [ $ngx_found != yes ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
290 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
291 ngx_feature="sched_yield() in librt" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
292 ngx_feature_libs="-lrt" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
293 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
294 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
295 if [ $ngx_found = yes ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
296 CORE_LIBS="$CORE_LIBS -lrt" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
297 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
298 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
299 |
4016
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
300 |
3933
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
301 ngx_feature="SO_SETFIB" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
302 ngx_feature_name="NGX_HAVE_SETFIB" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
303 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
304 ngx_feature_incs="#include <sys/socket.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
305 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
306 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
307 ngx_feature_test="setsockopt(0, SOL_SOCKET, SO_SETFIB, NULL, 4)" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
308 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
309 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
310 |
4016
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
311 ngx_feature="SO_ACCEPTFILTER" |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
312 ngx_feature_name="NGX_HAVE_DEFERRED_ACCEPT" |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
313 ngx_feature_run=no |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
314 ngx_feature_incs="#include <sys/socket.h>" |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
315 ngx_feature_path= |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
316 ngx_feature_libs= |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
317 ngx_feature_test="setsockopt(0, SOL_SOCKET, SO_ACCEPTFILTER, NULL, 0)" |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
318 . auto/feature |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
319 |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
320 |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
321 ngx_feature="TCP_DEFER_ACCEPT" |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
322 ngx_feature_name="NGX_HAVE_DEFERRED_ACCEPT" |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
323 ngx_feature_run=no |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
324 ngx_feature_incs="#include <sys/socket.h> |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
325 #include <netinet/in.h> |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
326 #include <netinet/tcp.h>" |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
327 ngx_feature_path= |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
328 ngx_feature_libs= |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
329 ngx_feature_test="setsockopt(0, IPPROTO_TCP, TCP_DEFER_ACCEPT, NULL, 0)" |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
330 . auto/feature |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
331 |
b044d6553d52
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4003
diff
changeset
|
332 |
4323
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
333 ngx_feature="TCP_KEEPIDLE, TCP_KEEPINTVL, TCP_KEEPCNT" |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
334 ngx_feature_name="NGX_HAVE_KEEPALIVE_TUNABLE" |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
335 ngx_feature_run=no |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
336 ngx_feature_incs="#include <sys/socket.h> |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
337 #include <netinet/in.h> |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
338 #include <netinet/tcp.h>" |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
339 ngx_feature_path= |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
340 ngx_feature_libs= |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
341 ngx_feature_test="setsockopt(0, IPPROTO_TCP, TCP_KEEPIDLE, NULL, 0); |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
342 setsockopt(0, IPPROTO_TCP, TCP_KEEPINTVL, NULL, 0); |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
343 setsockopt(0, IPPROTO_TCP, TCP_KEEPCNT, NULL, 0)" |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
344 . auto/feature |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
345 |
c4513d4dd024
Added the "so_keepalive=" parameter to the "listen" directive.
Valentin Bartenev <vbart@nginx.com>
parents:
4302
diff
changeset
|
346 |
4545
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
347 ngx_feature="TCP_INFO" |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
348 ngx_feature_name="NGX_HAVE_TCP_INFO" |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
349 ngx_feature_run=no |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
350 ngx_feature_incs="#include <sys/socket.h> |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
351 #include <netinet/in.h> |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
352 #include <netinet/tcp.h>" |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
353 ngx_feature_path= |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
354 ngx_feature_libs= |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
355 ngx_feature_test="socklen_t optlen = sizeof(struct tcp_info); |
4550
d29dc0486e8e
The addition of $tcpinfo_* variables has broken the build on Linux
Ruslan Ermilov <ru@nginx.com>
parents:
4545
diff
changeset
|
356 struct tcp_info ti; |
d29dc0486e8e
The addition of $tcpinfo_* variables has broken the build on Linux
Ruslan Ermilov <ru@nginx.com>
parents:
4545
diff
changeset
|
357 ti.tcpi_rtt = 0; |
d29dc0486e8e
The addition of $tcpinfo_* variables has broken the build on Linux
Ruslan Ermilov <ru@nginx.com>
parents:
4545
diff
changeset
|
358 ti.tcpi_rttvar = 0; |
d29dc0486e8e
The addition of $tcpinfo_* variables has broken the build on Linux
Ruslan Ermilov <ru@nginx.com>
parents:
4545
diff
changeset
|
359 ti.tcpi_snd_cwnd = 0; |
d29dc0486e8e
The addition of $tcpinfo_* variables has broken the build on Linux
Ruslan Ermilov <ru@nginx.com>
parents:
4545
diff
changeset
|
360 ti.tcpi_rcv_space = 0; |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
361 getsockopt(0, IPPROTO_TCP, TCP_INFO, &ti, &optlen)" |
4545
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
362 . auto/feature |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
363 |
ba39af7274ed
Implemented $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd, and
Ruslan Ermilov <ru@nginx.com>
parents:
4543
diff
changeset
|
364 |
3933
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
365 ngx_feature="accept4()" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
366 ngx_feature_name="NGX_HAVE_ACCEPT4" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
367 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
368 ngx_feature_incs="#include <sys/socket.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
369 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
370 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
371 ngx_feature_test="accept4(0, NULL, NULL, SOCK_NONBLOCK)" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
372 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
373 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
374 if [ $NGX_FILE_AIO = YES ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
375 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
376 ngx_feature="kqueue AIO support" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
377 ngx_feature_name="NGX_HAVE_FILE_AIO" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
378 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
379 ngx_feature_incs="#include <aio.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
380 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
381 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
382 ngx_feature_test="int n; struct aiocb iocb; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
383 iocb.aio_sigevent.sigev_notify = SIGEV_KEVENT; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
384 n = aio_read(&iocb)" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
385 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
386 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
387 if [ $ngx_found = yes ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
388 CORE_SRCS="$CORE_SRCS $FILE_AIO_SRCS" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
389 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
390 elif [ $ngx_found = no ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
391 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
392 ngx_feature="Linux AIO support" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
393 ngx_feature_name="NGX_HAVE_FILE_AIO" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
394 ngx_feature_run=no |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
395 ngx_feature_incs="#include <linux/aio_abi.h> |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
396 #include <sys/syscall.h>" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
397 ngx_feature_path= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
398 ngx_feature_libs= |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
399 ngx_feature_test="int n = SYS_eventfd; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
400 struct iocb iocb; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
401 iocb.aio_lio_opcode = IOCB_CMD_PREAD; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
402 iocb.aio_flags = IOCB_FLAG_RESFD; |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
403 iocb.aio_resfd = -1;" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
404 . auto/feature |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
405 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
406 if [ $ngx_found = yes ]; then |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
407 have=NGX_HAVE_EVENTFD . auto/have |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
408 CORE_SRCS="$CORE_SRCS $LINUX_AIO_SRCS" |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
409 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
410 else |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
411 cat << END |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
412 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
413 $0: no supported file AIO was found |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
414 Currently file AIO is supported on FreeBSD 4.3+ and Linux 2.6.22+ only |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
415 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
416 END |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
417 exit 1 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
418 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
419 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
420 fi |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
421 |
b5c169873c6b
concatenate auto/os/features and auto/unix
Igor Sysoev <igor@sysoev.ru>
parents:
3931
diff
changeset
|
422 |
479 | 423 have=NGX_HAVE_UNIX_DOMAIN . auto/have |
424 | |
583 | 425 ngx_feature_libs= |
195
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
426 |
493 | 427 |
196
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
428 # C types |
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
429 |
267
83205e0b5522
nginx-0.0.2-2004-02-24-20:31:46 import
Igor Sysoev <igor@sysoev.ru>
parents:
256
diff
changeset
|
430 ngx_type="int"; . auto/types/sizeof |
195
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
431 |
267
83205e0b5522
nginx-0.0.2-2004-02-24-20:31:46 import
Igor Sysoev <igor@sysoev.ru>
parents:
256
diff
changeset
|
432 ngx_type="long"; . auto/types/sizeof |
195
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
433 |
267
83205e0b5522
nginx-0.0.2-2004-02-24-20:31:46 import
Igor Sysoev <igor@sysoev.ru>
parents:
256
diff
changeset
|
434 ngx_type="long long"; . auto/types/sizeof |
195
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
435 |
370
54f76b0b8dca
nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents:
361
diff
changeset
|
436 ngx_type="void *"; . auto/types/sizeof; ngx_ptr_size=$ngx_size |
493 | 437 ngx_param=NGX_PTR_SIZE; ngx_value=$ngx_size; . auto/types/value |
195
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
438 |
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
439 |
253
b6793bc5034b
nginx-0.0.2-2004-02-09-10:46:43 import
Igor Sysoev <igor@sysoev.ru>
parents:
252
diff
changeset
|
440 # POSIX types |
196
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
441 |
665 | 442 case "$NGX_AUTO_CONFIG_H" in |
443 /*) | |
444 NGX_INCLUDE_AUTO_CONFIG_H="#include \"$NGX_AUTO_CONFIG_H\"" | |
445 ;; | |
446 *) | |
447 NGX_INCLUDE_AUTO_CONFIG_H="#include \"../$NGX_AUTO_CONFIG_H\"" | |
448 ;; | |
449 esac | |
196
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
450 |
370
54f76b0b8dca
nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents:
361
diff
changeset
|
451 ngx_type="uint64_t"; ngx_types="u_int64_t"; . auto/types/typedef |
196
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
452 |
370
54f76b0b8dca
nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents:
361
diff
changeset
|
453 ngx_type="sig_atomic_t"; ngx_types="int"; . auto/types/typedef |
54f76b0b8dca
nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents:
361
diff
changeset
|
454 . auto/types/sizeof |
477 | 455 ngx_param=NGX_SIG_ATOMIC_T_SIZE; ngx_value=$ngx_size; . auto/types/value |
252
84b1c672ec5a
nginx-0.0.2-2004-02-05-19:58:36 import
Igor Sysoev <igor@sysoev.ru>
parents:
218
diff
changeset
|
456 |
515 | 457 ngx_type="socklen_t"; ngx_types="int"; . auto/types/typedef |
196
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
458 |
370
54f76b0b8dca
nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents:
361
diff
changeset
|
459 ngx_type="in_addr_t"; ngx_types="uint32_t"; . auto/types/typedef |
196
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
460 |
417
0526206251f6
nginx-0.0.10-2004-09-07-19:29:22 import
Igor Sysoev <igor@sysoev.ru>
parents:
370
diff
changeset
|
461 ngx_type="in_port_t"; ngx_types="u_short"; . auto/types/typedef |
0526206251f6
nginx-0.0.10-2004-09-07-19:29:22 import
Igor Sysoev <igor@sysoev.ru>
parents:
370
diff
changeset
|
462 |
370
54f76b0b8dca
nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents:
361
diff
changeset
|
463 ngx_type="rlim_t"; ngx_types="int"; . auto/types/typedef |
196
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
464 |
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
465 . auto/types/uintptr_t |
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
466 |
4681
bb37a9cc08fb
Fixed spelling of "endianness", and called it "byte ordering" in the
Ruslan Ermilov <ru@nginx.com>
parents:
4563
diff
changeset
|
467 . auto/endianness |
370
54f76b0b8dca
nginx-0.0.7-2004-06-27-22:01:57 import
Igor Sysoev <igor@sysoev.ru>
parents:
361
diff
changeset
|
468 |
473 | 469 ngx_type="size_t"; . auto/types/sizeof |
477 | 470 ngx_param=NGX_MAX_SIZE_T_VALUE; ngx_value=$ngx_max_value; . auto/types/value |
471 ngx_param=NGX_SIZE_T_LEN; ngx_value=$ngx_max_len; . auto/types/value | |
196
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
472 |
473 | 473 ngx_type="off_t"; . auto/types/sizeof |
477 | 474 ngx_param=NGX_MAX_OFF_T_VALUE; ngx_value=$ngx_max_value; . auto/types/value |
475 ngx_param=NGX_OFF_T_LEN; ngx_value=$ngx_max_len; . auto/types/value | |
473 | 476 |
477 ngx_type="time_t"; . auto/types/sizeof | |
477 | 478 ngx_param=NGX_TIME_T_SIZE; ngx_value=$ngx_size; . auto/types/value |
479 ngx_param=NGX_TIME_T_LEN; ngx_value=$ngx_max_len; . auto/types/value | |
195
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
480 |
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
481 |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
482 # syscalls, libc calls and some features |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
483 |
455 | 484 |
2512
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
485 if [ $NGX_IPV6 = YES ]; then |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
486 ngx_feature="AF_INET6" |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
487 ngx_feature_name="NGX_HAVE_INET6" |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
488 ngx_feature_run=no |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
489 ngx_feature_incs="#include <sys/socket.h> |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
490 #include <netinet/in.h> |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
491 #include <arpa/inet.h>" |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
492 ngx_feature_path= |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
493 ngx_feature_libs= |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
494 ngx_feature_test="struct sockaddr_in6 sin6; |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
495 sin6.sin6_family = AF_INET6;" |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
496 . auto/feature |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
497 fi |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
498 |
2e91aecb9e57
a prelimiary IPv6 support, HTTP listen
Igor Sysoev <igor@sysoev.ru>
parents:
2234
diff
changeset
|
499 |
467 | 500 ngx_feature="setproctitle()" |
469 | 501 ngx_feature_name="NGX_HAVE_SETPROCTITLE" |
467 | 502 ngx_feature_run=no |
4543
51744fa997c7
Fixed compilation warnings in configuration C tests.
Ruslan Ermilov <ru@nginx.com>
parents:
4475
diff
changeset
|
503 ngx_feature_incs="#include <stdlib.h>" |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
504 ngx_feature_path= |
509 | 505 ngx_feature_libs=$NGX_SETPROCTITLE_LIB |
467 | 506 ngx_feature_test="setproctitle(\"test\");" |
507 . auto/feature | |
508 | |
509 | |
455 | 510 ngx_feature="pread()" |
469 | 511 ngx_feature_name="NGX_HAVE_PREAD" |
455 | 512 ngx_feature_run=no |
513 ngx_feature_incs= | |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
514 ngx_feature_path= |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
515 ngx_feature_libs= |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
516 ngx_feature_test="char buf[1]; ssize_t n; n = pread(0, buf, 1, 0); |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
517 if (n == -1) return 1" |
455 | 518 . auto/feature |
195
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
519 |
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
520 |
455 | 521 ngx_feature="pwrite()" |
469 | 522 ngx_feature_name="NGX_HAVE_PWRITE" |
455 | 523 ngx_feature_run=no |
524 ngx_feature_incs= | |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
525 ngx_feature_path= |
455 | 526 ngx_feature_libs= |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
527 ngx_feature_test="char buf[1]; ssize_t n; n = pwrite(1, buf, 1, 0); |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
528 if (n == -1) return 1" |
455 | 529 . auto/feature |
195
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
530 |
8dee38ea9117
nginx-0.0.1-2003-11-25-23:44:56 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
531 |
3787
e294f37401c0
use copied strerror() messages and autoconfigured sys_nerr value
Igor Sysoev <igor@sysoev.ru>
parents:
3472
diff
changeset
|
532 ngx_feature="sys_nerr" |
e294f37401c0
use copied strerror() messages and autoconfigured sys_nerr value
Igor Sysoev <igor@sysoev.ru>
parents:
3472
diff
changeset
|
533 ngx_feature_name="NGX_SYS_NERR" |
e294f37401c0
use copied strerror() messages and autoconfigured sys_nerr value
Igor Sysoev <igor@sysoev.ru>
parents:
3472
diff
changeset
|
534 ngx_feature_run=value |
4302
52c881519427
o AIX 7 defines sys_nerr in errno.h, therefore <errno.h> included
Maxim Konovalov <maxim@nginx.com>
parents:
4016
diff
changeset
|
535 ngx_feature_incs='#include <errno.h> |
52c881519427
o AIX 7 defines sys_nerr in errno.h, therefore <errno.h> included
Maxim Konovalov <maxim@nginx.com>
parents:
4016
diff
changeset
|
536 #include <stdio.h>' |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
537 ngx_feature_path= |
455 | 538 ngx_feature_libs= |
3787
e294f37401c0
use copied strerror() messages and autoconfigured sys_nerr value
Igor Sysoev <igor@sysoev.ru>
parents:
3472
diff
changeset
|
539 ngx_feature_test='printf("%d", sys_nerr);' |
3472
65481698535c
use sys_errlist[] in signal handler instead
Igor Sysoev <igor@sysoev.ru>
parents:
2916
diff
changeset
|
540 . auto/feature |
65481698535c
use sys_errlist[] in signal handler instead
Igor Sysoev <igor@sysoev.ru>
parents:
2916
diff
changeset
|
541 |
65481698535c
use sys_errlist[] in signal handler instead
Igor Sysoev <igor@sysoev.ru>
parents:
2916
diff
changeset
|
542 |
3819
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
543 if [ $ngx_found = no ]; then |
3820 | 544 |
3819
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
545 # Cygiwn defines _sys_nerr |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
546 ngx_feature="_sys_nerr" |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
547 ngx_feature_name="NGX_SYS_NERR" |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
548 ngx_feature_run=value |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
549 ngx_feature_incs='#include <errno.h> |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
550 #include <stdio.h>' |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
551 ngx_feature_path= |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
552 ngx_feature_libs= |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
553 ngx_feature_test='printf("%d", _sys_nerr);' |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
554 . auto/feature |
5e1e406f10ff
test for _sys_nerr only if sys_nerr was not found
Igor Sysoev <igor@sysoev.ru>
parents:
3811
diff
changeset
|
555 fi |
3811
4af1c7f53711
fix building by Cygwin: Cygwin defines _sys_nerr instead of sys_nerr,
Igor Sysoev <igor@sysoev.ru>
parents:
3787
diff
changeset
|
556 |
4af1c7f53711
fix building by Cygwin: Cygwin defines _sys_nerr instead of sys_nerr,
Igor Sysoev <igor@sysoev.ru>
parents:
3787
diff
changeset
|
557 |
3821
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
558 if [ $ngx_found = no ]; then |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
559 |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
560 # Solaris has no sys_nerr |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
561 ngx_feature='maximum errno' |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
562 ngx_feature_name=NGX_SYS_NERR |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
563 ngx_feature_run=value |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
564 ngx_feature_incs='#include <errno.h> |
3908 | 565 #include <string.h> |
3821
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
566 #include <stdio.h>' |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
567 ngx_feature_path= |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
568 ngx_feature_libs= |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
569 ngx_feature_test='int n; |
3901 | 570 char *p; |
3821
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
571 for (n = 1; n < 1000; n++) { |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
572 errno = 0; |
3901 | 573 p = strerror(n); |
574 if (errno == EINVAL | |
575 || p == NULL | |
576 || strncmp(p, "Unknown error", 13) == 0) | |
577 { | |
4302
52c881519427
o AIX 7 defines sys_nerr in errno.h, therefore <errno.h> included
Maxim Konovalov <maxim@nginx.com>
parents:
4016
diff
changeset
|
578 break; |
3821
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
579 } |
4302
52c881519427
o AIX 7 defines sys_nerr in errno.h, therefore <errno.h> included
Maxim Konovalov <maxim@nginx.com>
parents:
4016
diff
changeset
|
580 } |
52c881519427
o AIX 7 defines sys_nerr in errno.h, therefore <errno.h> included
Maxim Konovalov <maxim@nginx.com>
parents:
4016
diff
changeset
|
581 printf("%d", n);' |
3821
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
582 . auto/feature |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
583 fi |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
584 |
573cd56f006b
test for maximum errno value, since Solaris has no sys_nerr
Igor Sysoev <igor@sysoev.ru>
parents:
3820
diff
changeset
|
585 |
455 | 586 ngx_feature="localtime_r()" |
469 | 587 ngx_feature_name="NGX_HAVE_LOCALTIME_R" |
455 | 588 ngx_feature_run=no |
589 ngx_feature_incs="#include <time.h>" | |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
590 ngx_feature_path= |
455 | 591 ngx_feature_libs= |
592 ngx_feature_test="struct tm t; time_t c=0; localtime_r(&c, &t)" | |
593 . auto/feature | |
256
8e39cab6abd5
nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents:
253
diff
changeset
|
594 |
8e39cab6abd5
nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents:
253
diff
changeset
|
595 |
455 | 596 ngx_feature="posix_memalign()" |
469 | 597 ngx_feature_name="NGX_HAVE_POSIX_MEMALIGN" |
455 | 598 ngx_feature_run=no |
599 ngx_feature_incs="#include <stdlib.h>" | |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
600 ngx_feature_path= |
455 | 601 ngx_feature_libs= |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
602 ngx_feature_test="void *p; int n; n = posix_memalign(&p, 4096, 4096); |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
603 if (n != 0) return 1" |
455 | 604 . auto/feature |
346
55e496a8ece3
nginx-0.0.3-2004-06-06-23:49:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
279
diff
changeset
|
605 |
55e496a8ece3
nginx-0.0.3-2004-06-06-23:49:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
279
diff
changeset
|
606 |
455 | 607 ngx_feature="memalign()" |
469 | 608 ngx_feature_name="NGX_HAVE_MEMALIGN" |
455 | 609 ngx_feature_run=no |
4543
51744fa997c7
Fixed compilation warnings in configuration C tests.
Ruslan Ermilov <ru@nginx.com>
parents:
4475
diff
changeset
|
610 ngx_feature_incs="#include <stdlib.h> |
51744fa997c7
Fixed compilation warnings in configuration C tests.
Ruslan Ermilov <ru@nginx.com>
parents:
4475
diff
changeset
|
611 #include <malloc.h>" |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
612 ngx_feature_path= |
455 | 613 ngx_feature_libs= |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
614 ngx_feature_test="void *p; p = memalign(4096, 4096); |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
615 if (p == NULL) return 1" |
455 | 616 . auto/feature |
346
55e496a8ece3
nginx-0.0.3-2004-06-06-23:49:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
279
diff
changeset
|
617 |
55e496a8ece3
nginx-0.0.3-2004-06-06-23:49:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
279
diff
changeset
|
618 |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
619 ngx_feature="mmap(MAP_ANON|MAP_SHARED)" |
469 | 620 ngx_feature_name="NGX_HAVE_MAP_ANON" |
455 | 621 ngx_feature_run=yes |
622 ngx_feature_incs="#include <sys/mman.h>" | |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
623 ngx_feature_path= |
455 | 624 ngx_feature_libs= |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
625 ngx_feature_test="void *p; |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
626 p = mmap(NULL, 4096, PROT_READ|PROT_WRITE, |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
627 MAP_ANON|MAP_SHARED, -1, 0); |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
628 if (p == MAP_FAILED) return 1;" |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
629 . auto/feature |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
630 |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
631 |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
632 ngx_feature='mmap("/dev/zero", MAP_SHARED)' |
469 | 633 ngx_feature_name="NGX_HAVE_MAP_DEVZERO" |
455 | 634 ngx_feature_run=yes |
635 ngx_feature_incs="#include <sys/mman.h> | |
2598 | 636 #include <sys/stat.h> |
637 #include <fcntl.h>" | |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
638 ngx_feature_path= |
455 | 639 ngx_feature_libs= |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
640 ngx_feature_test='void *p; int fd; |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
641 fd = open("/dev/zero", O_RDWR); |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
642 p = mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0); |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
643 if (p == MAP_FAILED) return 1;' |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
644 . auto/feature |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
645 |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
646 |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
647 ngx_feature="System V shared memory" |
469 | 648 ngx_feature_name="NGX_HAVE_SYSVSHM" |
455 | 649 ngx_feature_run=yes |
650 ngx_feature_incs="#include <sys/ipc.h> | |
2598 | 651 #include <sys/shm.h>" |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
652 ngx_feature_path= |
455 | 653 ngx_feature_libs= |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
654 ngx_feature_test="int id; |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
655 id = shmget(IPC_PRIVATE, 4096, (SHM_R|SHM_W|IPC_CREAT)); |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
656 if (id == -1) return 1; |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
657 shmctl(id, IPC_RMID, NULL);" |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
658 . auto/feature |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
659 |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
346
diff
changeset
|
660 |
3909
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
661 ngx_feature="POSIX semaphores" |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
662 ngx_feature_name="NGX_HAVE_POSIX_SEM" |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
663 ngx_feature_run=yes |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
664 ngx_feature_incs="#include <semaphore.h>" |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
665 ngx_feature_path= |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
666 ngx_feature_libs= |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
667 ngx_feature_test="sem_t sem; |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
668 if (sem_init(&sem, 1, 0) == -1) return 1; |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
669 sem_destroy(&sem);" |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
670 . auto/feature |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
671 |
0daede16d68b
use POSIX semaphores in shmtx instead of sched_yield()
Igor Sysoev <igor@sysoev.ru>
parents:
3908
diff
changeset
|
672 |
3931
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
673 if [ $ngx_found = no ]; then |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
674 |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
675 # Linux has POSIX semaphores in libpthread |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
676 ngx_feature="POSIX semaphores in libpthread" |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
677 ngx_feature_libs=-lpthread |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
678 . auto/feature |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
679 |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
680 if [ $ngx_found = yes ]; then |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
681 CORE_LIBS="$CORE_LIBS -lpthread" |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
682 fi |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
683 fi |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
684 |
c8884c8f7c74
Support POSIX semaphores on Linux.
Igor Sysoev <igor@sysoev.ru>
parents:
3909
diff
changeset
|
685 |
4003
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
686 if [ $ngx_found = no ]; then |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
687 |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
688 # Solaris has POSIX semaphores in librt |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
689 ngx_feature="POSIX semaphores in librt" |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
690 ngx_feature_libs=-lrt |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
691 . auto/feature |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
692 |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
693 if [ $ngx_found = yes ]; then |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
694 CORE_LIBS="$CORE_LIBS -lrt" |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
695 fi |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
696 fi |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
697 |
8cca96abbc3e
Detect POSIX semaphores in librt on Solaris (ticket #3).
Maxim Dounin <mdounin@mdounin.ru>
parents:
3933
diff
changeset
|
698 |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
699 ngx_feature="struct msghdr.msg_control" |
469 | 700 ngx_feature_name="NGX_HAVE_MSGHDR_MSG_CONTROL" |
455 | 701 ngx_feature_run=no |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
702 ngx_feature_incs="#include <sys/socket.h> |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
703 #include <stdio.h>" |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
704 ngx_feature_path= |
455 | 705 ngx_feature_libs= |
4563
cc038cc834be
Configure: fixed msghdr.msg_control test on 64bit platforms.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4559
diff
changeset
|
706 ngx_feature_test="struct msghdr msg; |
cc038cc834be
Configure: fixed msghdr.msg_control test on 64bit platforms.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4559
diff
changeset
|
707 printf(\"%d\", (int) sizeof(msg.msg_control))" |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
708 . auto/feature |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
709 |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
710 |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
711 ngx_feature="ioctl(FIONBIO)" |
469 | 712 ngx_feature_name="NGX_HAVE_FIONBIO" |
455 | 713 ngx_feature_run=no |
714 ngx_feature_incs="#include <sys/ioctl.h> | |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
715 #include <stdio.h> |
2598 | 716 $NGX_INCLUDE_SYS_FILIO_H" |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
717 ngx_feature_path= |
455 | 718 ngx_feature_libs= |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
719 ngx_feature_test="int i = FIONBIO; printf(\"%d\", i)" |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
720 . auto/feature |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
721 |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
722 |
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
723 ngx_feature="struct tm.tm_gmtoff" |
469 | 724 ngx_feature_name="NGX_HAVE_GMTOFF" |
455 | 725 ngx_feature_run=no |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
726 ngx_feature_incs="#include <time.h> |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
727 #include <stdio.h>" |
875
7af8276b1c2f
test PCRE in FreeBSD, Linux, and NetBSD
Igor Sysoev <igor@sysoev.ru>
parents:
665
diff
changeset
|
728 ngx_feature_path= |
455 | 729 ngx_feature_libs= |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
730 ngx_feature_test="struct tm tm; tm.tm_gmtoff = 0; |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
731 printf(\"%d\", (int) tm.tm_gmtoff)" |
358
0a03c921c81d
nginx-0.0.7-2004-06-17-21:18:53 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
732 . auto/feature |
2234
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
733 |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
734 |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
735 ngx_feature="struct dirent.d_namlen" |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
736 ngx_feature_name="NGX_HAVE_D_NAMLEN" |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
737 ngx_feature_run=no |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
738 ngx_feature_incs="#include <dirent.h> |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
739 #include <stdio.h>" |
2234
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
740 ngx_feature_path= |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
741 ngx_feature_libs= |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
742 ngx_feature_test="struct dirent dir; dir.d_namlen = 0; |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
743 printf(\"%d\", (int) dir.d_namlen)" |
2234
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
744 . auto/feature |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
745 |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
746 |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
747 ngx_feature="struct dirent.d_type" |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
748 ngx_feature_name="NGX_HAVE_D_TYPE" |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
749 ngx_feature_run=no |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
750 ngx_feature_incs="#include <dirent.h> |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
751 #include <stdio.h>" |
2234
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
752 ngx_feature_path= |
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
753 ngx_feature_libs= |
4559
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
754 ngx_feature_test="struct dirent dir; dir.d_type = DT_REG; |
62d8db8c7157
Fixed more gcc46 warnings in configure tests.
Maxim Dounin <mdounin@mdounin.ru>
parents:
4550
diff
changeset
|
755 printf(\"%d\", (int) dir.d_type)" |
2234
c7c319896bb4
*) autoconfigure struct dirent capabilities
Igor Sysoev <igor@sysoev.ru>
parents:
875
diff
changeset
|
756 . auto/feature |
4459
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
757 |
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
758 |
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
759 ngx_feature="sysconf(_SC_NPROCESSORS_ONLN)" |
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
760 ngx_feature_name="NGX_HAVE_SC_NPROCESSORS_ONLN" |
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
761 ngx_feature_run=no |
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
762 ngx_feature_incs= |
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
763 ngx_feature_path= |
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
764 ngx_feature_libs= |
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
765 ngx_feature_test="sysconf(_SC_NPROCESSORS_ONLN)" |
ccb2f8e3d08d
Added ngx_ncpu detection for most *nix platforms.
Valentin Bartenev <vbart@nginx.com>
parents:
4412
diff
changeset
|
766 . auto/feature |
4475 | 767 |
768 | |
769 ngx_feature="openat(), fstatat()" | |
770 ngx_feature_name="NGX_HAVE_OPENAT" | |
771 ngx_feature_run=no | |
772 ngx_feature_incs="#include <sys/types.h> | |
773 #include <sys/stat.h> | |
774 #include <fcntl.h>" | |
775 ngx_feature_path= | |
776 ngx_feature_libs= | |
777 ngx_feature_test="struct stat sb; | |
778 openat(AT_FDCWD, \".\", O_RDONLY|O_NOFOLLOW); | |
779 fstatat(AT_FDCWD, \".\", &sb, AT_SYMLINK_NOFOLLOW);" | |
780 . auto/feature | |
4971
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
781 |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
782 |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
783 ngx_feature="getaddrinfo()" |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
784 ngx_feature_name="NGX_HAVE_GETADDRINFO" |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
785 ngx_feature_run=no |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
786 ngx_feature_incs="#include <sys/types.h> |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
787 #include <sys/socket.h> |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
788 #include <netdb.h>" |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
789 ngx_feature_path= |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
790 ngx_feature_libs= |
5312
ec8594b9bf11
Core: only resolve address families configured on the local system.
Ruslan Ermilov <ru@nginx.com>
parents:
4971
diff
changeset
|
791 ngx_feature_test='struct addrinfo hints, *res; |
ec8594b9bf11
Core: only resolve address families configured on the local system.
Ruslan Ermilov <ru@nginx.com>
parents:
4971
diff
changeset
|
792 hints.ai_family = AF_UNSPEC; |
ec8594b9bf11
Core: only resolve address families configured on the local system.
Ruslan Ermilov <ru@nginx.com>
parents:
4971
diff
changeset
|
793 hints.ai_socktype = SOCK_STREAM; |
ec8594b9bf11
Core: only resolve address families configured on the local system.
Ruslan Ermilov <ru@nginx.com>
parents:
4971
diff
changeset
|
794 hints.ai_flags = AI_ADDRCONFIG; |
ec8594b9bf11
Core: only resolve address families configured on the local system.
Ruslan Ermilov <ru@nginx.com>
parents:
4971
diff
changeset
|
795 if (getaddrinfo("localhost", NULL, &hints, &res) != 0) |
ec8594b9bf11
Core: only resolve address families configured on the local system.
Ruslan Ermilov <ru@nginx.com>
parents:
4971
diff
changeset
|
796 return 1; |
4971
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
797 freeaddrinfo(res)' |
eaf95350d75c
Implemented IPv6 support for URLs specified using domain names.
Ruslan Ermilov <ru@nginx.com>
parents:
4681
diff
changeset
|
798 . auto/feature |