安装nginx的每一步都有错(灬ꈍ ꈍ灬)
1.
./configure --with-openssl=../openssl-1.0.1t --with-pcre=../pcre-8.40 --with-zlib=../zlib-1.2.11
出现:sha1 library is not found
./configure --with-openssl=../openssl-1.0.1t --with-pcre=../pcre-8.40 --with-zlib=../zlib-1.2.11 --with-http_ssl_module
2.make时出现cc1: all warnings being treated as errors
解决方法:进入objs/Makefile 删除-Werror
Werror是把警告当错误了
3.再次make出现
解决方法:vim src/os/unix/ngx_user.c 把36行注释
ps:openssl版本不对,安装nginx也会错
最后make就好啦