mirror of
https://github.com/nginx/nginx.git
synced 2025-02-25 18:55:26 -06:00
Move SO_ACCEPTFILTER and TCP_DEFER_ACCEPT checks into configure.
NetBSD 5.0+ has SO_ACCEPTFILTER support merged from FreeBSD, and having accept filter check in FreeBSD-specific ngx_freebsd_config.h prevents it from being used on NetBSD. Therefore move the check into configure (and do the same for Linux-specific TCP_DEFER_ACCEPT, just to be in line).
This commit is contained in:
23
auto/unix
23
auto/unix
@@ -295,6 +295,7 @@ if [ $ngx_found != yes ]; then
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
ngx_feature="SO_SETFIB"
|
||||
ngx_feature_name="NGX_HAVE_SETFIB"
|
||||
ngx_feature_run=no
|
||||
@@ -305,6 +306,28 @@ ngx_feature_test="setsockopt(0, SOL_SOCKET, SO_SETFIB, NULL, 4)"
|
||||
. auto/feature
|
||||
|
||||
|
||||
ngx_feature="SO_ACCEPTFILTER"
|
||||
ngx_feature_name="NGX_HAVE_DEFERRED_ACCEPT"
|
||||
ngx_feature_run=no
|
||||
ngx_feature_incs="#include <sys/socket.h>"
|
||||
ngx_feature_path=
|
||||
ngx_feature_libs=
|
||||
ngx_feature_test="setsockopt(0, SOL_SOCKET, SO_ACCEPTFILTER, NULL, 0)"
|
||||
. auto/feature
|
||||
|
||||
|
||||
ngx_feature="TCP_DEFER_ACCEPT"
|
||||
ngx_feature_name="NGX_HAVE_DEFERRED_ACCEPT"
|
||||
ngx_feature_run=no
|
||||
ngx_feature_incs="#include <sys/socket.h>
|
||||
#include <netinet/in.h>
|
||||
#include <netinet/tcp.h>"
|
||||
ngx_feature_path=
|
||||
ngx_feature_libs=
|
||||
ngx_feature_test="setsockopt(0, IPPROTO_TCP, TCP_DEFER_ACCEPT, NULL, 0)"
|
||||
. auto/feature
|
||||
|
||||
|
||||
ngx_feature="accept4()"
|
||||
ngx_feature_name="NGX_HAVE_ACCEPT4"
|
||||
ngx_feature_run=no
|
||||
|
||||
Reference in New Issue
Block a user