我以为缺省就有PNG支持呢。应该怎样编译进PNG呢?
解决方案 »
- 关于学习php及相关知识的的顺序
- php学完了!想做一个项目,但是不知道做什么~``
- zen cart
- 严重费解的php问题,哪位高手能告诉我为什么?
- json问题请教
- Agent: Mozilla/4.0是什么意思?agent:google又是什么意思?
- 请问这是什么错误?
- 出现错误:Warning: MySQL Connection Failed: Can't connect to MySQL server on 'localhost' (10061)
- 有关用户认证,管理的几个问题
- 表单之间如何传递数组变量
- 关于session不能传递变量 的问题
- 从数据库里随机提出20条记录,并且不一样?谢谢
--with-png-dir=[path to libpng]
如果libpng时系统缺省安装path一般为/usr,如果自己安装一般为/usr/local
目录/usr/local/src
[jpeg-6b]
./configure
make
make test
make install[zlib]
make test
make install[freetype-2.0.8]
./configure --prefix=/usr/local
make
make install[libpng-1.0.10]
cp scripts/makefile.linux makefile
make test
pngtest pngnow.png (passed)
make install[gd-1.8.4]
edit Makefile
---uncomment follow lines:CFLAGS=-O -DHAVE_LIBXPM -DHAVE_LIBPNG -DHAVE_LIBJPEG \
-DHAVE_LIBFREETYPE -DHAVE_LIBTTF
LIBS=-lgd -lpng -lz -ljpeg -lfreetype -lm -lttf---comment follow lines:
CFLAGS=-O -DHAVE_LIBPNG -DHAVE_LIBJPEG
LIBS=-lgd -lpng -lz -lm---modify follow line:
INCLUDEDIRS=-I. -I/usr/local/include/freetype2 -I/usr/include/X11 -I/usr/X11R6/include/X11 -I/usr/local/include -I/usr/include/freetypemake
make install[php-4.1.1]
./configure \
--with-apache=/usr/local/src/apache_1.3.23 \
--with-config-file-path=/cal/apache/conf \
--with-enable-versioning \
--with-mysql=/usr/local/mysql \
--with-ftp \
--with-gd=/usr/local \
--with-enabled-bcmath=yes \
--with-disable-debug \
--enable-memory-limit=yes \
--enable-track-vars \
--with-zlib \
--with-jpeg-dir=/usr/local/
--with-png-dir=/usr/local/make
make install[apache_1.3.23]
./configure --prefix=/usr/local/apache --enable-module=most --enable-shared=enable-module=ssl --enable-sh
ared=ssl --activate-module=src/modules/php4/libphp4.a
make
make installphpinfo()中GD库的部分如下:
GD Support enabled
GD Version 1.6.2 or higher
WBMP Support enabled
JPEG和PNG部分都不支持,但却支持WBMP不知道为什么。