Welcome 微信登录

首页 / 网页编程 / PHP / php安装gd(freetype、jpeg、png、zlib)

php安装gd(freetype、jpeg、png、zlib)2014-08-04 csdn博客 Liteboy安装php需要gd(freetype、jpeg、png)支持

1、安装freetype

[root@localhost softs]# tar xf freetype-2.5.0.tar.bz2 -C /usr/src/

[root@localhost softs]# cd /usr/src/freetype-2.5.0

[root@localhost freetype-2.5.0]# ./configure --prefix=/usr/local/freetype --enable-shared

[root@localhost freetype-2.5.0]#  make && make install

2、安装png

[root@localhost softs]# tar xf libpng-1.6.6.tar.gz -C /usr/src/

[root@localhost softs]# cd /usr/src/libpng-1.6.6/

[root@localhost libpng-1.6.6]# ./configure --prefix=/usr/local/png --enable-shared

[root@localhost libpng-1.6.6]# make  && make  install

3、安装jpeg

[root@localhost softs]# tar xf jpeg-6b.tar.gz -C /usr/src/

[root@localhost softs]# cd /usr/src/jpeg-9/

[root@localhost jpeg-9]# ./configure --prefix=/usr/local/jpeg --enable-shared

[root@localhost jpeg-9]# make  && make install

4、安装zlib

[root@localhost softs]# tar xf zlib-1.2.2.2.tar.gz -C /usr/src/

[root@localhost softs]# cd /usr/src/zlib-1.2.2.2

[root@localhost zlib-1.2.2.2]# ./configure --prefix=/usr/local/zlib

[root@localhost zlib-1.2.2.2]#  make && make install

5、安装libgd

[root@localhost softs]# tar xf libgd-2.1.0.tar.xz -C /usr/src/