Mercurial > hg > nginx
annotate src/os/unix/ngx_freebsd_config.h @ 2779:7bb23b7d9f73
delete useless debug log
author | Igor Sysoev <igor@sysoev.ru> |
---|---|
date | Wed, 29 Apr 2009 15:15:17 +0000 |
parents | 418c9f97bd01 |
children | 6060225e9261 |
rev | line source |
---|---|
441
da8c5707af39
nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents:
374
diff
changeset
|
1 |
da8c5707af39
nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents:
374
diff
changeset
|
2 /* |
444
42d11f017717
nginx-0.1.0-2004-09-29-20:00:49 import; remove years from copyright
Igor Sysoev <igor@sysoev.ru>
parents:
441
diff
changeset
|
3 * Copyright (C) Igor Sysoev |
441
da8c5707af39
nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents:
374
diff
changeset
|
4 */ |
da8c5707af39
nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents:
374
diff
changeset
|
5 |
da8c5707af39
nginx-0.1.0-2004-09-28-12:34:51 import; set copyright and remove unused files
Igor Sysoev <igor@sysoev.ru>
parents:
374
diff
changeset
|
6 |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
7 #ifndef _NGX_FREEBSD_CONFIG_H_INCLUDED_ |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
8 #define _NGX_FREEBSD_CONFIG_H_INCLUDED_ |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
9 |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
10 |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
11 #include <sys/types.h> |
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
12 #include <sys/time.h> |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
13 #include <unistd.h> |
115
be27f922b9a2
nginx-0.0.1-2003-07-10-20:26:57 import
Igor Sysoev <igor@sysoev.ru>
parents:
105
diff
changeset
|
14 #include <stdarg.h> |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
15 #include <stddef.h> /* offsetof() */ |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
16 #include <stdio.h> |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
17 #include <stdlib.h> |
256
8e39cab6abd5
nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents:
249
diff
changeset
|
18 #include <errno.h> |
8e39cab6abd5
nginx-0.0.2-2004-02-10-19:23:38 import
Igor Sysoev <igor@sysoev.ru>
parents:
249
diff
changeset
|
19 #include <string.h> |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
20 #include <signal.h> |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
21 #include <pwd.h> |
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
22 #include <grp.h> |
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
23 #include <dirent.h> |
727 | 24 #include <glob.h> |
2624
418c9f97bd01
fix FreeBSD before 7 building, broken in r2616
Igor Sysoev <igor@sysoev.ru>
parents:
2615
diff
changeset
|
25 #include <sys/param.h> /* ALIGN() */ |
2615 | 26 #include <sys/mount.h> /* statfs() */ |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
27 |
455 | 28 #include <sys/filio.h> /* FIONBIO */ |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
29 #include <sys/uio.h> |
185
d5f50cefc322
nginx-0.0.1-2003-11-14-19:52:04 import
Igor Sysoev <igor@sysoev.ru>
parents:
183
diff
changeset
|
30 #include <sys/stat.h> |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
31 #include <fcntl.h> |
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
32 |
191
71ce40b3c37b
nginx-0.0.1-2003-11-19-19:26:41 import
Igor Sysoev <igor@sysoev.ru>
parents:
190
diff
changeset
|
33 #include <sys/wait.h> |
105
00bee6e7b485
nginx-0.0.1-2003-06-15-22:32:13 import
Igor Sysoev <igor@sysoev.ru>
parents:
104
diff
changeset
|
34 #include <sys/mman.h> |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
35 #include <sys/resource.h> |
374
213f17e9f776
nginx-0.0.7-2004-07-02-09:47:00 import
Igor Sysoev <igor@sysoev.ru>
parents:
370
diff
changeset
|
36 #include <sched.h> |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
37 |
94
8220378432a8
nginx-0.0.1-2003-05-22-19:23:47 import
Igor Sysoev <igor@sysoev.ru>
parents:
93
diff
changeset
|
38 #include <sys/socket.h> |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
39 #include <netinet/in.h> |
452 | 40 #include <netinet/tcp.h> /* TCP_NODELAY, TCP_NOPUSH */ |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
41 #include <arpa/inet.h> |
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
42 #include <netdb.h> |
479 | 43 #include <sys/un.h> |
355
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
44 |
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
45 #include <libutil.h> /* setproctitle() before 4.1 */ |
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
46 #include <osreldate.h> |
0fb6c53fb135
nginx-0.0.7-2004-06-15-21:47:16 import
Igor Sysoev <igor@sysoev.ru>
parents:
267
diff
changeset
|
47 #include <sys/sysctl.h> |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
48 |
361
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
49 |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
50 #if __FreeBSD_version < 400017 |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
51 |
1901
d880fa02fb65
use CMSG_LEN(), this fixes an alert "sendmsg() failed (9: Bad file descriptor)"
Igor Sysoev <igor@sysoev.ru>
parents:
1377
diff
changeset
|
52 /* |
d880fa02fb65
use CMSG_LEN(), this fixes an alert "sendmsg() failed (9: Bad file descriptor)"
Igor Sysoev <igor@sysoev.ru>
parents:
1377
diff
changeset
|
53 * FreeBSD 3.x has no CMSG_SPACE() and CMSG_LEN() and has the broken CMSG_DATA() |
d880fa02fb65
use CMSG_LEN(), this fixes an alert "sendmsg() failed (9: Bad file descriptor)"
Igor Sysoev <igor@sysoev.ru>
parents:
1377
diff
changeset
|
54 */ |
361
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
55 |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
56 #undef CMSG_SPACE |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
57 #define CMSG_SPACE(l) (ALIGN(sizeof(struct cmsghdr)) + ALIGN(l)) |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
58 |
1901
d880fa02fb65
use CMSG_LEN(), this fixes an alert "sendmsg() failed (9: Bad file descriptor)"
Igor Sysoev <igor@sysoev.ru>
parents:
1377
diff
changeset
|
59 #undef CMSG_LEN |
d880fa02fb65
use CMSG_LEN(), this fixes an alert "sendmsg() failed (9: Bad file descriptor)"
Igor Sysoev <igor@sysoev.ru>
parents:
1377
diff
changeset
|
60 #define CMSG_LEN(l) (ALIGN(sizeof(struct cmsghdr)) + (l)) |
d880fa02fb65
use CMSG_LEN(), this fixes an alert "sendmsg() failed (9: Bad file descriptor)"
Igor Sysoev <igor@sysoev.ru>
parents:
1377
diff
changeset
|
61 |
361
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
62 #undef CMSG_DATA |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
63 #define CMSG_DATA(cmsg) ((u_char *)(cmsg) + ALIGN(sizeof(struct cmsghdr))) |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
64 |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
65 #endif |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
66 |
446782c909b3
nginx-0.0.7-2004-06-20-23:54:15 import
Igor Sysoev <igor@sysoev.ru>
parents:
355
diff
changeset
|
67 |
249
2a0540287298
nginx-0.0.2-2004-02-03-19:43:54 import
Igor Sysoev <igor@sysoev.ru>
parents:
242
diff
changeset
|
68 #include <ngx_auto_config.h> |
2a0540287298
nginx-0.0.2-2004-02-03-19:43:54 import
Igor Sysoev <igor@sysoev.ru>
parents:
242
diff
changeset
|
69 |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
70 |
469 | 71 #if (NGX_HAVE_POLL) |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
72 #include <poll.h> |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
73 #endif |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
74 |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
75 |
469 | 76 #if (NGX_HAVE_AIO) |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
77 #include <aio.h> |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
78 #endif |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
79 |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
80 |
469 | 81 #if (NGX_HAVE_KQUEUE) |
467 | 82 #include <sys/event.h> |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
83 #endif |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
84 |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
85 |
1377
0d57c150115b
set default listen() backlog to 511 on all platforms except FreeBSD
Igor Sysoev <igor@sysoev.ru>
parents:
1354
diff
changeset
|
86 #define NGX_LISTEN_BACKLOG -1 |
0d57c150115b
set default listen() backlog to 511 on all platforms except FreeBSD
Igor Sysoev <igor@sysoev.ru>
parents:
1354
diff
changeset
|
87 |
0d57c150115b
set default listen() backlog to 511 on all platforms except FreeBSD
Igor Sysoev <igor@sysoev.ru>
parents:
1354
diff
changeset
|
88 |
523 | 89 #if (defined SO_ACCEPTFILTER && !defined NGX_HAVE_DEFERRED_ACCEPT) |
469 | 90 #define NGX_HAVE_DEFERRED_ACCEPT 1 |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
91 #endif |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
92 |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
93 |
267
83205e0b5522
nginx-0.0.2-2004-02-24-20:31:46 import
Igor Sysoev <igor@sysoev.ru>
parents:
262
diff
changeset
|
94 #if (__FreeBSD_version < 430000 || __FreeBSD_version < 500012) |
83205e0b5522
nginx-0.0.2-2004-02-24-20:31:46 import
Igor Sysoev <igor@sysoev.ru>
parents:
262
diff
changeset
|
95 |
83205e0b5522
nginx-0.0.2-2004-02-24-20:31:46 import
Igor Sysoev <igor@sysoev.ru>
parents:
262
diff
changeset
|
96 pid_t rfork_thread(int flags, void *stack, int (*func)(void *arg), void *arg); |
83205e0b5522
nginx-0.0.2-2004-02-24-20:31:46 import
Igor Sysoev <igor@sysoev.ru>
parents:
262
diff
changeset
|
97 |
83205e0b5522
nginx-0.0.2-2004-02-24-20:31:46 import
Igor Sysoev <igor@sysoev.ru>
parents:
262
diff
changeset
|
98 #endif |
83205e0b5522
nginx-0.0.2-2004-02-24-20:31:46 import
Igor Sysoev <igor@sysoev.ru>
parents:
262
diff
changeset
|
99 |
262
8c5bdde0d9f0
nginx-0.0.2-2004-02-18-18:45:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
256
diff
changeset
|
100 #ifndef IOV_MAX |
8c5bdde0d9f0
nginx-0.0.2-2004-02-18-18:45:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
256
diff
changeset
|
101 #define IOV_MAX 1024 |
8c5bdde0d9f0
nginx-0.0.2-2004-02-18-18:45:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
256
diff
changeset
|
102 #endif |
8c5bdde0d9f0
nginx-0.0.2-2004-02-18-18:45:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
256
diff
changeset
|
103 |
8c5bdde0d9f0
nginx-0.0.2-2004-02-18-18:45:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
256
diff
changeset
|
104 |
469 | 105 #ifndef NGX_HAVE_INHERITED_NONBLOCK |
106 #define NGX_HAVE_INHERITED_NONBLOCK 1 | |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
107 #endif |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
108 |
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
109 |
539 | 110 #define NGX_HAVE_OS_SPECIFIC_INIT 1 |
111 | |
196
11fbd0fc041d
nginx-0.0.1-2003-11-26-18:42:18 import
Igor Sysoev <igor@sysoev.ru>
parents:
195
diff
changeset
|
112 |
601 | 113 extern char **environ; |
1354
f69d1aab6a0f
make 64-bit ngx_int_t on 64-bit platforms
Igor Sysoev <igor@sysoev.ru>
parents:
727
diff
changeset
|
114 extern char *malloc_options; |
601 | 115 |
116 | |
93
738fe44c70d5
nginx-0.0.1-2003-05-21-17:28:21 import
Igor Sysoev <igor@sysoev.ru>
parents:
diff
changeset
|
117 #endif /* _NGX_FREEBSD_CONFIG_H_INCLUDED_ */ |