linux下php5源码编译安装实践

php5源码编译安装,以及一些组件的安装:

a.安装jpeg7

#tar-zvxfjpegsrc.v7b.tar.gz

#cdjpeg-7b

#./configure--prefix=/usr/local/jpeg7/--enable-shared--enable-static

#make;makeinstall

b.安装libpng

#tar-zvxflibpng-1.2.8.tar.gz

#cdlibpng-1.2.8

#cpscripts/makefile.stdmakefile

#make;makeinstall

c.安装freetype

#tar-zvxffreetype-2.1.10.tar.gz

#cdfreetype-2.1.10

#mkdir-p/usr/local/freetype

#./configure--prefix=/usr/local/freetype

#make;makeinstall

d.:安装zlib

#tar-zxvfzlib-1.2.3.tar.gz

#cdzlib.1.2.3

#./configure

#make;makeinstall

e.安装gd库

#tar-zvxfgd-2.0.33.tar.gz

#mkdir-p/usr/local/gd2

#cdgd-2.0.33

#./configure--prefix=/usr/local/gd2--with-jpeg=/usr/local/jpeg7/

--with-png=/usr/local/lib/

--with-zlib=/usr/local/lib/

--with-freetype=/usr/local/freetype/

#make;makeinstall

f.安装php

#libs='-lresolv'./configure-prefix=/usr/local/php--with-apxs2=/usr/sbin/apxs--with-mysql=/usr/local/mysql--with-pdo-mysql=/usr/local/mysql--without-pear-with-gd=/usr/local/gd2/--with-jpeg-dir=/usr/local/jpeg7/--with-zlib-dir=/usr/local/lib/--with-png-dir=/usr/local/lib/--with-freetype-dir=/usr/local/freetype/

#make&&makeinstall

相关推荐