执行make出现:make: *** No rule to make target `build'

执行make出现:make: *** No rule to make target build', needed bydefault'. Stop.

1.安装nginx执行./configure...会在最后报以下几种错误,之后执行make就会报:make: *** No rule to make target build', needed bydefault'. Stop.错误。

注:个人经历,错误1、2、3可能会逐个出现,所以出现那个就解决那个吧。我把第三个处理了才ok的。

错误列表:

(1)

./configure: error: the HTTP rewrite module requires the PCRE library.

You can either disable the module by using --without-http_rewrite_module

option, or install the PCRE library into the system, or build the PCRE library

statically from the source with nginx by using --with-pcre=<path> option.

(2)

./configure: error: the HTTP cache module requires md5 functions

from OpenSSL library.  You can either disable the module by using

--without-http-cache option, or install the OpenSSL library into the system,

or build the OpenSSL library statically from the source with nginx by using

--with-http_ssl_module --with-openssl=<path> options.

(3)

./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

网上解决办法:

需要安装openssl以及ncurses组件

yum install -y openssl*
yum -y install ncurses-devel

2.但执行以上操作依然不行:

经过一番折腾~发现在执行.configure时就报了很多错误:上述错误,因此需要逐个解决!

解决办法:

出现(1)错误:

需要安装pcre包:

下载地址:https://ftp.pcre.org/pub/pcre/

tar zxvf pcre-8.12.tar.gz
cd pcre-8.12
./configure
make
make install

出现(2)错误:

需要安装openssl

下载地址:http://gnuwin32.sourceforge.net/packages/openssl.htm

tar zxvf openssl-0.9.8h.tar.gz

cd openssl-0.9.8h
./config --prefix=/usr/local/ --openssldir=/usr/local/openssl -g3 shared zlib-dynamic enable-camellia
make
make install

测试是否安装成功:openssl version

出现(3)错误:

需要安装zlib包:

下载地址:http://www.zlib.net/

tar zxvf zlib-1.2.11.tar.gz
cd zlib-1.2.11
./configure
make
make install

转载于:https://blog.51cto.com/14142911/2344072

  • 1
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值