最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
Nginx编译安装错误error: the HTTP gzip module requires the zlib library
时间:2022-06-30 18:41:25 编辑:袖梨 来源:一聚教程网
下载后,解包,并进入nginx:
tar -zxf nginx-1.4.7.tar.gz
cd nginx-1.4.7
开始nginx安装:
./configure
make
make install
若在“./configure”后方加入了“--with-http_gzip_static_module”(添加gzip压缩模块)提示以下错误:
./configure: error: the HTTP gzip module requires the zlib library.
You can either disable the module by using –without-http_gzip_module
option, or install the zlib library into the system, or build the zlib
library
statically from the source with nginx by using –with-zlib=
则需要安装“zlib-devel”即可。SSH执行以下命令:
| 代码如下 | 复制代码 |
|
yum install -y zlib-devel |
|
然后再进行nginx的编译。表示问题即可解决。
像还有一些其它组件错误如:
You need a C++ compiler for C++ support
缺少c++编译器的原因
yum install -y gcc gcc-c++
make[1]: *** [/usr/local/pcre/Makefile] Error 127.pcre指向错误
指向源码包,不是编译安装后的包,所以
./configure –prefix=/export/lnmp/nginx-1.4.7 –with-pcre=../pcre-8.34
好了我在使用nginx编译安装时碰到几大问题都总结了一下,希望能帮助到各位。
相关文章
- 2026年Pika怎么用?5步生成与编辑视频 06-15
- 幸福岛幻想莉莉丝角色背景介绍-莉莉丝攻略 06-15
- 2026年Runway免费替代工具怎么选?4个开源方案对比 06-15
- Midjourney版权风险说明:办公场景下3种合规应对策略 06-15
- Midjourney报错怎么解决?3步排查常见原因 06-15
- 黑神话悟空龙鳞在哪里 龙鳞位置介绍 06-15