comparison src/os/unix/ngx_linux_config.h @ 5255:7f4ec5bfb715

Fixed build on Linux with x32 ABI. On Linux x32 inclusion of sys/sysctl.h produces an error. As sysctl() is only used by rtsig event method code, which is legacy and not compiled in by default on modern linuxes, the sys/sysctl.h file now only included if rtsig support is enabled. Based on patch by Serguei I. Ivantsov.
author Maxim Dounin <mdounin@mdounin.ru>
date Wed, 26 Jun 2013 15:47:27 +0400
parents d620f497c50f
children 72e31d88defa
comparison
equal deleted inserted replaced
5254:7ecaa9e4bf1b 5255:7f4ec5bfb715
49 49
50 #include <time.h> /* tzset() */ 50 #include <time.h> /* tzset() */
51 #include <malloc.h> /* memalign() */ 51 #include <malloc.h> /* memalign() */
52 #include <limits.h> /* IOV_MAX */ 52 #include <limits.h> /* IOV_MAX */
53 #include <sys/ioctl.h> 53 #include <sys/ioctl.h>
54 #include <sys/sysctl.h>
55 #include <crypt.h> 54 #include <crypt.h>
56 #include <sys/utsname.h> /* uname() */ 55 #include <sys/utsname.h> /* uname() */
57 56
58 57
59 #include <ngx_auto_config.h> 58 #include <ngx_auto_config.h>
75 extern ssize_t sendfile(int s, int fd, int32_t *offset, size_t size); 74 extern ssize_t sendfile(int s, int fd, int32_t *offset, size_t size);
76 #define NGX_SENDFILE_LIMIT 0x80000000 75 #define NGX_SENDFILE_LIMIT 0x80000000
77 #endif 76 #endif
78 77
79 78
80 #if (NGX_HAVE_POLL || NGX_HAVE_RTSIG) 79 #if (NGX_HAVE_POLL)
81 #include <poll.h> 80 #include <poll.h>
81 #endif
82
83
84 #if (NGX_HAVE_RTSIG)
85 #include <poll.h>
86 #include <sys/sysctl.h>
82 #endif 87 #endif
83 88
84 89
85 #if (NGX_HAVE_EPOLL) 90 #if (NGX_HAVE_EPOLL)
86 #include <sys/epoll.h> 91 #include <sys/epoll.h>