mirror of
https://github.com/nginx/nginx.git
synced 2025-06-07 17:52:38 +08:00
disable rtsig automatic building in post 2.6.18 Linux kernels
This commit is contained in:
parent
d48d0d9f42
commit
001a9cfa37
@ -22,9 +22,10 @@ version=`grep "#define LINUX_VERSION_CODE" /usr/include/linux/version.h \
|
|||||||
version=${version:-0}
|
version=${version:-0}
|
||||||
|
|
||||||
|
|
||||||
# enable the rt signals on Linux 2.2.19 and onward
|
# enable the rt signals on Linux between 2.2.19 and 2.6.17
|
||||||
|
|
||||||
if [ $version -ge 131609 -o $EVENT_RTSIG = YES ]; then
|
if [ \( $version -ge 131609 -a $version -lt 132632 \) -o $EVENT_RTSIG = YES ]
|
||||||
|
then
|
||||||
echo " + rt signals found"
|
echo " + rt signals found"
|
||||||
have=NGX_HAVE_RTSIG . auto/have
|
have=NGX_HAVE_RTSIG . auto/have
|
||||||
EVENT_MODULES="$EVENT_MODULES $RTSIG_MODULE"
|
EVENT_MODULES="$EVENT_MODULES $RTSIG_MODULE"
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
u_char ngx_linux_kern_ostype[50];
|
u_char ngx_linux_kern_ostype[50];
|
||||||
u_char ngx_linux_kern_osrelease[50];
|
u_char ngx_linux_kern_osrelease[50];
|
||||||
|
|
||||||
int ngx_linux_rtsig_max;
|
int ngx_linux_rtsig_max;
|
||||||
|
|
||||||
|
|
||||||
static ngx_os_io_t ngx_linux_io = {
|
static ngx_os_io_t ngx_linux_io = {
|
||||||
@ -32,9 +32,6 @@ static ngx_os_io_t ngx_linux_io = {
|
|||||||
ngx_int_t
|
ngx_int_t
|
||||||
ngx_os_specific_init(ngx_log_t *log)
|
ngx_os_specific_init(ngx_log_t *log)
|
||||||
{
|
{
|
||||||
int name[2];
|
|
||||||
size_t len;
|
|
||||||
ngx_err_t err;
|
|
||||||
struct utsname u;
|
struct utsname u;
|
||||||
|
|
||||||
if (uname(&u) == -1) {
|
if (uname(&u) == -1) {
|
||||||
@ -48,6 +45,12 @@ ngx_os_specific_init(ngx_log_t *log)
|
|||||||
(void) ngx_cpystrn(ngx_linux_kern_osrelease, (u_char *) u.release,
|
(void) ngx_cpystrn(ngx_linux_kern_osrelease, (u_char *) u.release,
|
||||||
sizeof(ngx_linux_kern_osrelease));
|
sizeof(ngx_linux_kern_osrelease));
|
||||||
|
|
||||||
|
#if (NGX_HAVE_RTSIG)
|
||||||
|
{
|
||||||
|
int name[2];
|
||||||
|
size_t len;
|
||||||
|
ngx_err_t err;
|
||||||
|
|
||||||
name[0] = CTL_KERN;
|
name[0] = CTL_KERN;
|
||||||
name[1] = KERN_RTSIGMAX;
|
name[1] = KERN_RTSIGMAX;
|
||||||
len = sizeof(ngx_linux_rtsig_max);
|
len = sizeof(ngx_linux_rtsig_max);
|
||||||
@ -65,6 +68,8 @@ ngx_os_specific_init(ngx_log_t *log)
|
|||||||
ngx_linux_rtsig_max = 0;
|
ngx_linux_rtsig_max = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
ngx_os_io = ngx_linux_io;
|
ngx_os_io = ngx_linux_io;
|
||||||
|
|
||||||
@ -78,6 +83,8 @@ ngx_os_specific_status(ngx_log_t *log)
|
|||||||
ngx_log_error(NGX_LOG_NOTICE, log, 0, "OS: %s %s",
|
ngx_log_error(NGX_LOG_NOTICE, log, 0, "OS: %s %s",
|
||||||
ngx_linux_kern_ostype, ngx_linux_kern_osrelease);
|
ngx_linux_kern_ostype, ngx_linux_kern_osrelease);
|
||||||
|
|
||||||
|
#if (NGX_HAVE_RTSIG)
|
||||||
ngx_log_error(NGX_LOG_NOTICE, log, 0, "sysctl(KERN_RTSIGMAX): %d",
|
ngx_log_error(NGX_LOG_NOTICE, log, 0, "sysctl(KERN_RTSIGMAX): %d",
|
||||||
ngx_linux_rtsig_max);
|
ngx_linux_rtsig_max);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user