A Digital Age Deserves A Digital Leader

Cent OS cant install php-gd [Solved]

Cent OS cant install php-gd [Solved]

Postby c0ldfyr3 » Thu Apr 16, 2009 1:01 am

i have tried numerous times to install php-gd on my VPN server, i always get
Code: Select all
yum install php-gd
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.nic.uoregon.edu
 * updates: mirrors.usc.edu
 * addons: mirrors.usc.edu
 * extras: pubmirrors.reflected.net
base                                                          | 1.1 kB     00:00
updates                                                       |  951 B     00:00
addons                                                        |  951 B     00:00
extras                                                        | 1.1 kB     00:00
Excluding Packages in global exclude list
Finished
Setting up Install Process
Parsing package install arguments
No package php-gd available.
Nothing to do


i have tried just
Code: Select all
 yum install gd

and when i use
Code: Select all
  rpm -qa | grep gd

i get
Code: Select all
gdbm-1.8.0-26.2.1
sysklogd-1.4.1-44.el5
gd-2.0.33-9.4.el5_1.1
gdb-6.8-27.el5
gdbm-devel-1.8.0-26.2.1

if i locate gd.so, and gd.dll itsin the correct directoy, and i enable it in php.ini but stuill no support.
Last edited by c0ldfyr3 on Sat Apr 18, 2009 7:50 am, edited 1 time in total.
Image
PRO Level 15
User avatar
Posts: 1346
Joined: Sun May 02, 2004 8:49 pm
Location: 127.0.0.1

Re: Cent OS cant install php-gd

Postby c0ldfyr3 » Fri Apr 17, 2009 7:20 am

well i finally got it working, i had to compile from source. for those that need to know how to do this i have the instructions below on how i got it to work. if anyone thinks i should add something please let me know, or if you see an error.

Code: Select all
curl -LO "http://us2.php.net/distributions/php-5.2.9.tar.bz2"

tar -xjf php-5.2.9.tar.bz2 && cd php-5.2.9 && ./configure --with-apxs2=/usr/bin/apxs --with-openssl --with-zlib --with-curl --enable-exif --enable-ftp --with-gd --with-png --with-jpeg-dir --enable-gd-native-ttf --with-gettext --enable-ttf --enable-mbstring  --with-mime-magic --with-mysql --with-mysqli --with-mysql-sock=/tmp/mysql.sock --enable-shmop --enable-soap --enable-sysvmsg --enable-sysvsem --enable-sysvshm --with-xpm --enable-zip --with-pear && make

make install

libtool --finish /root/php-5.2.9/php-5.2.9/php-5.2.9/php-5.2.9/php-5.2.9/php-5.2.9/php-5.2.9/libs

cp php.ini-dist /usr/local/lib/php.ini
Image
PRO Level 15
User avatar
Posts: 1346
Joined: Sun May 02, 2004 8:49 pm
Location: 127.0.0.1

Re: Cent OS cant install php-gd

Postby c0ldfyr3 » Fri Apr 17, 2009 6:19 pm

no one?
Image
PRO Level 15
User avatar
Posts: 1346
Joined: Sun May 02, 2004 8:49 pm
Location: 127.0.0.1

Re: Cent OS cant install php-gd

Postby Grav!ty » Fri Apr 17, 2009 6:30 pm

There are very few serious Linux users here other unfortunately. I see Ubuntu 9.04 is due for final release in a week or so and I'll probably give that a try simply because it doesn't require what looks like the advanced manipulating and coding you're doing here c0ldfyr3 :yesnod:
Image

"The great majority of mankind are satisfied with appearances, as though they were realities, and are often more influenced by the things that seem than by those that are." - Niccolo Machiavelli
PROfessional Member
User avatar
Posts: 15790
Joined: Tue Sep 14, 2004 5:22 am
Real Name: Graham

Re: Cent OS cant install php-gd

Postby c0ldfyr3 » Fri Apr 17, 2009 7:23 pm

i spent 60 hours looking for an answer to my issue above, and on every tech site and forum i went to no one had the answer to getting php-gd to actually work. not even the CentOS site had the answer. :-?

so after i figured out how to achieve what i needed, i figured why not place it here. ^*^
Besides we need more *nix users. the best servers out there use *nix as their OS so why not. heck if i am not mistaken even Microsoft uses *Nix servers for some things.
infact if wanted you could just C&P all that to install your own php server with GD2 on CentOS. SSH makes it quite easy i might add.
IMHO its better to compile from source, its more system specific and you know exactly whats going on.
my next feat is to work this line in...
Code: Select all

tar -xjf php-5.2.9.tar.bz2 && cd php-5.2.9 && ./configure --libdir=/usr/lib --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man --infodir=/usr/share/info --cache-file=../config.cache --with-config-file-path=/etc --with-config-file-scan-dir=/etc/php.d --enable-force-cgi-redirect --disable-debug --enable-pic --disable-rpath --enable-inline-optimization --with-bz2 --with-db4=/usr --with-curl --with-exec-dir=/usr/bin --with-freetype-dir=/usr --with-png-dir=/usr --with-gd=shared --enable-gd-native-ttf --without-gdbm --with-gettext --with-ncurses=shared --with-gmp --with-iconv --with-jpeg-dir=/usr --with-openssl --with-png --with-pspell --with-xml --with-expat-dir=/usr --with-dom=shared,/usr --with-dom-xslt=/usr --with-dom-exslt=/usr --with-xmlrpc=shared --with-pcre-regex=/usr --with-zlib --with-layout=GNU --enable-bcmath --enable-exif --enable-ftp --enable-magic-quotes --enable-sockets --enable-sysvsem --enable-sysvshm --enable-track-vars --enable-trans-sid --enable-yp --enable-wddx --with-pear=/usr/share/pear --with-imap=shared --with-imap-ssl --with-kerberos --with-ldap=shared --with-mysql=shared,/usr --with-pgsql=shared --with-snmp=shared,/usr --with-snmp=shared --enable-ucd-snmp-hack --with-unixODBC=shared,/usr --enable-memory-limit --enable-shmop --enable-calendar --enable-dbx --enable-dio --enable-mbstring=shared --enable-mbstr-enc-trans --enable-mbregex --with-mime-magic=/usr/share/file/magic.mime  && make


and then get lighttpd with fastcgi and xCache working.
Image
PRO Level 15
User avatar
Posts: 1346
Joined: Sun May 02, 2004 8:49 pm
Location: 127.0.0.1

Re: Cent OS cant install php-gd

Postby imnuts » Fri Apr 17, 2009 9:44 pm

I use either FreeBSD or Gentoo, so I wouldn't be much help. I tried out a few other systems before, but didn't like them as much, possibly because many of the mainstream distros use KDE and I prefer Gnome, and Ubuntu is to bloated by default. At least you got it figured out.
Image
PRO SUPREME
User avatar
Posts: 7457
Joined: Wed Mar 24, 2004 5:19 am
Location: Boothwyn, Pennsylvania
Real Name: Mark

Re: Cent OS cant install php-gd

Postby c0ldfyr3 » Fri Apr 17, 2009 10:46 pm

yeah i tried for Gentoo, but they wanted an additional $150. i am going to try ( note i said try ) to install gentoo on a partition within CentOS and reboot into Gentoo. its a long shot, btu i might get Gentoo on there.

I use Gentoo, and Debian Sarge net install as my main servers OS. i prefer no GUI, however if i have to have one its gnome.
Image
PRO Level 15
User avatar
Posts: 1346
Joined: Sun May 02, 2004 8:49 pm
Location: 127.0.0.1

Return to Other Operating Systems

Who is online

Users browsing this forum: No registered users and 0 guests

cron
cron