源码安装执行到
./configure
时
出错:
./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.
ERROR: failed to run command: sh ./configure --prefix=/usr/local/openresty/nginx \...
解决方法:
brew update
brew install pcre openssl
然后又出错:
./configure: error: SSL modules require the OpenSSL library.
You can either do not enable the modules, or install the OpenSSL library
into the system, or build the OpenSSL library statically from the source
with nginx by using --with-openssl=<path> option.
ERROR: failed to run command: sh ./configure --prefix=/usr/local/openresty/nginx \...
网上有人说解决方法是:告诉他openssl位置(错误的解决方法)
./configure --with-openssl=/usr/local/Cellar/openssl/1.0.2r
但是,不好使。
正确的解决方法应该是:用--with-openssl 告诉它的是源码位置
到https://www.openssl.org/下载了最新的,openssl.1.0.2r版本,到bundle目录里:
./configure --with-openssl=bundle/openssl-1.0.2r
然后 make
然后 sudo make install
·
网友评论