php mysql nginx編譯配置文檔
LANG=C
yum -y install gcc gcc-c++ autoconf libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel libpng libpng-devel libxml2 libxml2-devel zlib zlib-devel glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devel ncurses ncurses-devel curl curl-devel
cd /usr/lib
ln -sf libjpeg.so.62.0.0 libjpeg.so
ln -sf libpng12.so.0.1.2.7 libpng.so
cd /usr/local/src
wget http://sysoev.ru/nginx/nginx-0.6.32.tar.gz
wget http://www.php.net/get/php-5.2.6.tar.gz/from/this/mirror
wget http://php-fpm.anight.org/downloads/head/php-5.2.6-fpm-0.5.8.diff.gz
wget http://dev.mysql.com/get/Downloads/MySQL-5.1/mysql-5.1.26-rc.tar.gz/from/http://mysql.ntu.edu.tw/
wget http://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.12.tar.gz
wget http://pecl.php.net/get/memcache-2.2.3.tgz
wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-7.7.tar.gz
wget ftp://xmlsoft.org/libxml2/libxml2-sources-2.6.32.tar.gz
wget ftp://ftp.gnome.org/pub/GNOME/sources/libxslt/1.1/libxslt-1.1.22.tar.bz2
/usr/sbin/groupadd mysql
/usr/sbin/useradd -g mysql mysql
./configure --prefix=/usr/local/mysql --without-debug --with-unix-socket-path=/tmp/mysql.sock --with-client-ldflags=-all-static --with-mysqld-ldflags=-all-static --enable-assembler --with-extra-charsets=utf8,gbk,gb2312 --with-pthread --enable-thread-safe-client
tar zxvf php-5.2.6.tar.gz -C dir
gzip -cd php-5.2.6-fpm-0.5.8.diff.gz | patch -d php-5.2.6/ -p1
./configure --prefix=/usr/local/php \
--with-config-file-path=/usr/local/php/etc \
--enable-xml \
--enable-fastcgi \
--enable-force-cgi-redirect \
--disable-rpath --enable-discard-path \
--with-mysql=/usr/local/mysql \
--with-mysqli=/usr/local/mysql/bin/mysql_config \
--with-curl \
--with-curlwrappers \
--with-bz2 \
--enable-mbstring \
--with-zlib \
--with-xsl \
--enable-calendar \
--with-gettext \
--with-gd \
--enable-exif \
--with-jpeg-dir=/usr/local \
--with-freetype-dir \
--with-png-dir \
--enable-gd-native-ttf \
--enable-sysvmsg \
--enable-sockets \
--with-ttf=/usr/lib \
--enable-bcmath \
--enable-safe-mode \
--without-iconv \
--enable-wddx \
--disable-debug \
--enable-discard-path \
--with-iconv-dir=/usr/local \
--disable-short-tags \
--disable-ctype \
--enable-fpm \
--enable-inline-optimization \
--enable-mbregex \
--enable-shmop \
--with-libxml-dir=/usr
sed -i 's#-lz -lm -lxml2 -lz -lm -lxml2 -lz -lm -lcrypt#& -liconv#' Makefile
make
make install
cp php.ini-recommended /usr/local/php/etc/php.ini
cd ../
tar zxvf pcre-7.7.tar.gz
cd pcre-7.7/
./configure
make && make install
cd ../
tar zxvf nginx-0.6.31.tar.gz
cd nginx-0.6.31/
./configure --user=www --group=www --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module
make && make install
cd ../
chkconfig --add mysqld
chkconfig --add nginx
chkconfig --level 2345 mysqld on
chkconfig --level 2345 nginx on
關鍵字:php mysql nginx 編譯 配置 文檔
新文章:
- CentOS7下圖形配置網絡的方法
- CentOS 7如何添加刪除用戶
- 如何解決centos7雙系統后丟失windows啟動項
- CentOS單網卡如何批量添加不同IP段
- CentOS下iconv命令的介紹
- Centos7 SSH密鑰登陸及密碼密鑰雙重驗證詳解
- CentOS 7.1添加刪除用戶的方法
- CentOS查找/掃描局域網打印機IP講解
- CentOS7使用hostapd實現無AP模式的詳解
- su命令不能切換root的解決方法
- 解決VMware下CentOS7網絡重啟出錯
- 解決Centos7雙系統后丟失windows啟動項
- CentOS下如何避免文件覆蓋
- CentOS7和CentOS6系統有什么不同呢
- Centos 6.6默認iptable規則詳解