8
7

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

nginxビルド時のエラー

Last updated at Posted at 2013-05-03

CentOSにてnginxをビルドしてみたらエラー

まずはソースをダウンロード

wget http://nginx.org/download/nginx-1.4.0.tar.gz

configure実行

./configure --prefix=/usr/local --conf-path=/etc/nginx/nginx.conf


そしたらエラー

./configure: error: the HTTP rewrite module requires the PCRE librSary.
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.


PCRE libraryが必要と言ってはる。
PCRE libraryは正規表現ライブラリ。
URLのrewriteやLocationの指定で正規表現によるマッチングが行えるようになるとのこと。

というわけでインストールしてみる

yum -y install pcre-devel

再度configure実行

./configure --prefix=/usr/local --conf-path=/etc/nginx/nginx.conf

ようやく成功。

8
7
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
8
7

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?