最近升级nginx版本为 0.8.41 在make时提示如下警告:
objs/src/os/unix/ngx_process.o: In function `ngx_process_get_status':
/data/soft/nginx-0.8.42/src/os/unix/ngx_process.c:490: warning: `sys_errlist' is deprecated; use `strerror' or `strerror_r' instead
/data/soft/nginx-0.8.42/src/os/unix/ngx_process.c:490: warning: `sys_nerr' is deprecated; use `strerror' or `strerror_r' instead
根据其官方描述,这属于正常现象,没有替换废弃的函数是因为新的为非异步信号安全的函数。
以下为官方说明:
A message “ ‘sys_errlist’ is deprecated; use ‘strerror’ or ‘strerror_r’ instead ”
While building nginx version 0.7.66, 0.8.35 or higher on Linux the following warning messages are issued:
warning: `sys_errlist' is deprecated;
use `strerror' or `strerror_r' instead
warning: `sys_nerr' is deprecated;
use `strerror' or `strerror_r' instead
This is normal: nginx has to use the deprecated sys_errlist[] and sys_nerr in signal handlers because strerror() and strerror_r() functions are not Async-Signal-Safe.
转载自 <a href="http://www.yanghengfei.com/archives/341/" title="nginx 0.8.41 编译时侯出现警告" rel="bookmark">nginx 0.8.41 编译时侯出现警告 | 星外飞客 </a>
我简单说几句