[root@ipython lnmp]# tar zxf zlib-1.2.8.tar.gz
[root@ipython lnmp]# cd zlib-1.2.8
[root@ipython zlib-1.2.8]# ./configure --prefix=/software/sharelib
[root@ipython zlib-1.2.8]# make && make install
pcre库(rewrite的支持)
[root@ipython lnmp]# tar zxf pcre-8.35.tar.gz
[root@ipython lnmp]# cd pcre-8.35
[root@ipython pcre-8.35]# ./configure --prefix=/software/pcre --enable-utf8 --enable-unicode-properties
[root@ipython pcre-8.35]# make && make install
OpenSSL库(https的支持)
[root@ipython lnmp]# tar zxf openssl-1.0.1h.tar.gz
[root@ipython lnmp]# cd openssl-1.0.1h
[root@ipython openssl-1.0.1h]# ./config --prefix=/software/openssl
[root@ipython openssl-1.0.1h]# make && make install
TCMalloc工具(google内存管理套件)
[root@ipython lnmp]# tar zxf libunwind-1.1.tar.gz
[root@ipython lnmp]# cd libunwind-1.1
[root@ipython libunwind-1.1]# CFLAGS=-fPIC ./configure --prefix=/software/google-libunwind
[root@ipython libunwind-1.1]# make CFLAGS=-fPIC && make CFLAGS=-fPIC install
[root@ipython lnmp]# tar zxf gperftools-2.2.tar.gz
[root@ipython lnmp]# cd gperftools-2.2
[root@ipython gperftools-2.2]# LDFLAGS="-L/software/google-libunwind/lib" CPPFLAGS="-I/software/google-libunwind/include" ./configure --prefix=/software/google-perftools
[root@ipython gperftools-2.2]# make && make install
路径加到动态链接库
[root@ipython gperftools-2.2]# echo "/software/google-libunwind/lib/" >> /etc/ld.so.conf
[root@ipython gperftools-2.2]# echo "/software/google-perftools/lib/" >> /etc/ld.so.conf
[root@ipython gperftools-2.2]# echo "/software/sharelib/lib/" >> /etc/ld.so.conf && ldconfig
[root@ipython lnmp]# tar zxf libiconv-1.14.tar.gz打补丁吧,避免手动修改隐患逻辑错误
[root@ipython lnmp]# gzip -d libiconv-glibc-2.16.patch.gz
[root@ipython lnmp]# cd libiconv-1.14/srclib
[root@ipython srclib]# patch -p1 < ../../libiconv-glibc-2.16.patch
patching file stdio.in.h
[root@ipython libiconv-1.14]# cd ..
[root@ipython libiconv-1.14]# ./configure --prefix=/software/sharelib/
[root@ipython libiconv-1.14]# make && make install
libxml库(XML库)
[root@ipython lnmp]# tar jxf libxml2-2.8.0.tar.bz2
[root@ipython lnmp]# cd libxml2-2.8.0
[root@ipython libxml2-2.8.0]# ./configure --prefix=/software/sharelib
[root@ipython libxml2-2.8.0]# make && make install
libpng库(图片库)
[root@ipython lnmp]# tar jxf libpng-1.6.8.tar.bz2
[root@ipython lnmp]# cd libpng-1.6.8
[root@ipython libpng-1.6.8]# LDFLAGS="-L/software/sharelib/lib/" CPPFLAGS="-I/software/sharelib/include" ./configure --prefix=/software/sharelib
[root@ipython libpng-1.6.8]# make && make install
jpeg库(图片库)
[root@ipython lnmp]# tar jxf jpegsrc.v9a.tar.bz2
[root@ipython lnmp]# cd jpeg-9a/
[root@ipython jpeg-9a]# ./configure --prefix=/software/sharelib/
[root@ipython jpeg-9a]# make && make install
freetype(字库)
[root@ipython lnmp]# tar jxf freetype-2.5.2.tar.bz2
[root@ipython lnmp]# cd freetype-2.5.2
[root@ipython freetype-2.5.2]# LIBPNG_CFLAGS="-I/software/sharelib/include/" LIBPNG_LDFLAGS="-L/software/sharelib/lib/" ./configure --prefix=/software/sharelib
[root@ipython freetype-2.5.2]# make && make install
[root@ipython freetype-2.5.2]# ln -s /software/sharelib/include/freetype2 /software/sharelib/include/freetype2/freetype
libmcrypt库(加密算法)
[root@ipython lnmp]# tar jxf libmcrypt-2.5.8.tar.bz2
[root@ipython lnmp]# cd libmcrypt-2.5.8
[root@ipython libmcrypt-2.5.8]# ./configure --prefix=/software/sharelib
[root@ipython libmcrypt-2.5.8]# make && make install
mhash库(加密)
[root@ipython lnmp]# tar jxf mhash-0.9.9.9.tar.bz2
[root@ipython lnmp]# cd mhash-0.9.9.9
[root@ipython mhash-0.9.9.9]# ./configure --prefix=/software/sharelib/
[root@ipython mhash-0.9.9.9]# make && make install
curl库(URL传输)
[root@ipython lnmp]# tar jxf curl-7.36.0.tar.bz2
[root@ipython lnmp]# cd curl-7.36.0
[root@ipython curl-7.36.0]# ./configure --prefix=/software/curl
[root@ipython curl-7.36.0]# make && make install
gd库(绘图)
[root@ipython lnmp]# tar zxf gd-2.0.35.tar.gz
[root@ipython lnmp]# cd gd-2.0.35
[root@ipython gd-2.0.35]# LDFLAGS="-L/software/sharelib/lib" CPPFLAGS="-I/software/sharelib/include" ./configure --prefix=/software/sharelib --enable-shared --with-png=/software/sharelib --with-freetype=/software/sharelib --with-libiconv-prefix=/software/sharelib --with-jpeg=/software/sharelib
[root@ipython gd-2.0.35]# make && make install
libtool(库编译支持)
[root@ipython lnmp]# tar zxf libtool-2.4.2.tar.gz
[root@ipython lnmp]# cd libtool-2.4.2
[root@ipython libtool-2.4.2]# ./configure --prefix=/software/sharelib/ --enable-ltdl-install
[root@ipython libtool-2.4.2]# make && make install