Back to home page

Nginx displayed by LXR

Source navigation ]
Diff markup ]
Identifier search ]
general search ]
 
 
Version: nginx-1.19.2 ]​[ nginx-1.18.0 ]​

0001 
0002 /*
0003  * Copyright (C) Igor Sysoev
0004  * Copyright (C) Nginx, Inc.
0005  */
0006 
0007 
0008 #ifndef _NGX_FREEBSD_CONFIG_H_INCLUDED_
0009 #define _NGX_FREEBSD_CONFIG_H_INCLUDED_
0010 
0011 
0012 #include <sys/types.h>
0013 #include <sys/time.h>
0014 #include <unistd.h>
0015 #include <stdarg.h>
0016 #include <stddef.h>             /* offsetof() */
0017 #include <stdio.h>
0018 #include <stdlib.h>
0019 #include <ctype.h>
0020 #include <errno.h>
0021 #include <string.h>
0022 #include <signal.h>
0023 #include <pwd.h>
0024 #include <grp.h>
0025 #include <dirent.h>
0026 #include <glob.h>
0027 #include <time.h>
0028 #include <sys/param.h>          /* ALIGN() */
0029 #include <sys/mount.h>          /* statfs() */
0030 
0031 #include <sys/filio.h>          /* FIONBIO */
0032 #include <sys/uio.h>
0033 #include <sys/stat.h>
0034 #include <fcntl.h>
0035 
0036 #include <sys/wait.h>
0037 #include <sys/mman.h>
0038 #include <sys/resource.h>
0039 #include <sched.h>
0040 
0041 #include <sys/socket.h>
0042 #include <netinet/in.h>
0043 #include <netinet/tcp.h>        /* TCP_NODELAY, TCP_NOPUSH */
0044 #include <arpa/inet.h>
0045 #include <netdb.h>
0046 #include <sys/un.h>
0047 
0048 #include <libutil.h>            /* setproctitle() before 4.1 */
0049 #include <osreldate.h>
0050 #include <sys/sysctl.h>
0051 
0052 #include <dlfcn.h>
0053 
0054 
0055 #if __FreeBSD_version < 400017
0056 
0057 /*
0058  * FreeBSD 3.x has no CMSG_SPACE() and CMSG_LEN() and has the broken CMSG_DATA()
0059  */
0060 
0061 #undef  CMSG_SPACE
0062 #define CMSG_SPACE(l)       (ALIGN(sizeof(struct cmsghdr)) + ALIGN(l))
0063 
0064 #undef  CMSG_LEN
0065 #define CMSG_LEN(l)         (ALIGN(sizeof(struct cmsghdr)) + (l))
0066 
0067 #undef  CMSG_DATA
0068 #define CMSG_DATA(cmsg)     ((u_char *)(cmsg) + ALIGN(sizeof(struct cmsghdr)))
0069 
0070 #endif
0071 
0072 
0073 #include <ngx_auto_config.h>
0074 
0075 
0076 #if (NGX_HAVE_POSIX_SEM)
0077 #include <semaphore.h>
0078 #endif
0079 
0080 
0081 #if (NGX_HAVE_POLL)
0082 #include <poll.h>
0083 #endif
0084 
0085 
0086 #if (NGX_HAVE_KQUEUE)
0087 #include <sys/event.h>
0088 #endif
0089 
0090 
0091 #if (NGX_HAVE_FILE_AIO)
0092 
0093 #include <aio.h>
0094 typedef struct aiocb  ngx_aiocb_t;
0095 
0096 #if (__FreeBSD_version < 700005 && !defined __DragonFly__)
0097 #define sival_ptr     sigval_ptr
0098 #endif
0099 
0100 #endif
0101 
0102 
0103 #define NGX_LISTEN_BACKLOG        -1
0104 
0105 
0106 #ifdef __DragonFly__
0107 #define NGX_KEEPALIVE_FACTOR      1000
0108 #endif
0109 
0110 
0111 #ifndef IOV_MAX
0112 #define IOV_MAX   1024
0113 #endif
0114 
0115 
0116 #ifndef NGX_HAVE_INHERITED_NONBLOCK
0117 #define NGX_HAVE_INHERITED_NONBLOCK  1
0118 #endif
0119 
0120 
0121 #define NGX_HAVE_OS_SPECIFIC_INIT    1
0122 #define NGX_HAVE_DEBUG_MALLOC        1
0123 
0124 
0125 extern char **environ;
0126 extern char  *malloc_options;
0127 
0128 
0129 #endif /* _NGX_FREEBSD_CONFIG_H_INCLUDED_ */