SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
The easiest way is to get the latest php-5..2.14 (for security reasons) and compile it, adding the necessary options for gd in the ./configure script used to compile php-5.2.9. Eg:
If for some reason you don't want to go this way, here is what you can do to install gd as an extension.
Go into the php-5.2.9 sources directory and run:
Code:
cd ext/gd
phpize
./configure --with-zlib-dir --with-jpeg-dir --with-png-dir --with-freetype-dir
make
su -
make install
Watch the last lines of make install to see where gd.so is copied (something like /usr/local/lib/php/extensions/no-debug-XYZ)
After that open php.ini and make sure you use:
i'm try with your 2nd solution but having an error when run "make"
sorry..i'm really newbie.
Code:
root@jbendkck1:/home/zihan/serverfile/php-5.2.9/ext# cd gd
root@jbendkck1:/home/zihan/serverfile/php-5.2.9/ext/gd# ls
CREDITS config.w32 gd.dsp gdcache.c gdttf.c libgd/ tests/
config.m4 gd.c gd_ctx.c gdcache.h gdttf.h php_gd.h
root@jbendkck1:/home/zihan/serverfile/php-5.2.9/ext/gd# phpize ./configure --wit
h-zlib-dir --with-jpeg-dir --with-png-dir --with-freetype-dir
Configuring for:
PHP Api Version: 20041225
Zend Module Api No: 20060613
Zend Extension Api No: 220060519
configure.in:144: warning: AC_CACHE_VAL(lt_prog_compiler_static_works, ...): sus
picious cache-id, must contain _cv_ to be cached
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:3535: AC_LIBTOOL_LINKER_OPTION is expanded from...
aclocal.m4:5473: _LT_AC_LANG_C_CONFIG is expanded from...
aclocal.m4:5472: AC_LIBTOOL_LANG_C_CONFIG is expanded from...
aclocal.m4:2952: AC_LIBTOOL_SETUP is expanded from...
aclocal.m4:2932: _AC_PROG_LIBTOOL is expanded from...
aclocal.m4:2895: AC_PROG_LIBTOOL is expanded from...
configure.in:144: the top level
configure.in:144: warning: AC_CACHE_VAL(lt_prog_compiler_pic_works, ...): suspic
ious cache-id, must contain _cv_ to be cached
aclocal.m4:3490: AC_LIBTOOL_COMPILER_OPTION is expanded from...
aclocal.m4:7600: AC_LIBTOOL_PROG_COMPILER_PIC is expanded from...
configure.in:144: warning: AC_CACHE_VAL(lt_prog_compiler_pic_works_CXX, ...): su
spicious cache-id, must contain _cv_ to be cached
aclocal.m4:5586: _LT_AC_LANG_CXX_CONFIG is expanded from...
aclocal.m4:5585: AC_LIBTOOL_LANG_CXX_CONFIG is expanded from...
aclocal.m4:4621: _LT_AC_TAGCONFIG is expanded from...
configure.in:144: warning: AC_CACHE_VAL(lt_prog_compiler_static_works, ...): sus
picious cache-id, must contain _cv_ to be cached
../../lib/autoconf/general.m4:1974: AC_CACHE_VAL is expanded from...
../../lib/autoconf/general.m4:1994: AC_CACHE_CHECK is expanded from...
aclocal.m4:3535: AC_LIBTOOL_LINKER_OPTION is expanded from...
aclocal.m4:5473: _LT_AC_LANG_C_CONFIG is expanded from...
aclocal.m4:5472: AC_LIBTOOL_LANG_C_CONFIG is expanded from...
aclocal.m4:2952: AC_LIBTOOL_SETUP is expanded from...
aclocal.m4:2932: _AC_PROG_LIBTOOL is expanded from...
aclocal.m4:2895: AC_PROG_LIBTOOL is expanded from...
configure.in:144: the top level
configure.in:144: warning: AC_CACHE_VAL(lt_prog_compiler_pic_works, ...): suspic
ious cache-id, must contain _cv_ to be cached
aclocal.m4:3490: AC_LIBTOOL_COMPILER_OPTION is expanded from...
aclocal.m4:7600: AC_LIBTOOL_PROG_COMPILER_PIC is expanded from...
configure.in:144: warning: AC_CACHE_VAL(lt_prog_compiler_pic_works_CXX, ...): su
spicious cache-id, must contain _cv_ to be cached
aclocal.m4:5586: _LT_AC_LANG_CXX_CONFIG is expanded from...
aclocal.m4:5585: AC_LIBTOOL_LANG_CXX_CONFIG is expanded from...
aclocal.m4:4621: _LT_AC_TAGCONFIG is expanded from...
root@jbendkck1:/home/zihan/serverfile/php-5.2.9/ext/gd# make
make: *** No targets specified and no makefile found. Stop.
root@jbendkck1:/home/zihan/serverfile/php-5.2.9/ext/gd# ls
CREDITS config.guess* configure.in gdttf.c mkinstalldirs
Makefile.global config.h.in gd.c gdttf.h php_gd.h
acinclude.m4 config.m4 gd.dsp install-sh run-tests.php
aclocal.m4 config.sub* gd_ctx.c libgd/ tests/
autom4te.cache/ config.w32 gdcache.c ltmain.sh
build/ configure* gdcache.h missing
You forgot to run phpize before anything else. It's use to prepare the extension for compiling.
Now I guess you have to run "make distclean" into the gd directory and start over.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.