Created
February 16, 2012 03:04
-
-
Save g-k/1841336 to your computer and use it in GitHub Desktop.
build nginx with syslog
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NGINX_VERSION=1.0.6 | |
PCRE_VERSION=8.12 | |
# Download nginx | |
if `test ! -f nginx-${NGINX_VERSION}.tar.gz`; then | |
wget http://nginx.org/download/nginx-${NGINX_VERSION}.tar.gz | |
fi | |
tar -xzf nginx-${NGINX_VERSION}.tar.gz | |
# Download PCRE for the URL rewrite module | |
if `test ! -f pcre-${PCRE_VERSION}.tar.bz2`; then | |
wget -O pcre-${PCRE_VERSION}.tar.bz2 http://sourceforge.net/projects/pcre/files/pcre/${PCRE_VERSION}/pcre-${PCRE_VERSION}.tar.bz2/download | |
fi | |
tar -xjf pcre-${PCRE_VERSION}.tar.bz2 | |
PATCH_DIR=nginx_syslog_patch | |
if `test ! -d nginx_syslog_patch`; then | |
git clone https://github.com/yaoweibin/nginx_syslog_patch.git | |
fi | |
cd nginx_syslog_patch; git pull; cd .. | |
cd nginx-${NGINX_VERSION} | |
patch -p1 < $WORKSPACE/${PATCH_DIR}/syslog_0.8.54.patch | |
./configure --add-module=$WORKSPACE/${PATCH_DIR} --with-pcre=$WORKSPACE/pcre-${PCRE_VERSION} | |
make |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment