A Digital Age Deserves A Digital Leader

HowTo: CentOS and php GD with freetype support

HowTo: CentOS and php GD with freetype support

Postby c0ldfyr3 » Mon Apr 20, 2009 1:33 pm

php with gd2 and freetype support. among a few other features.

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


decompress, move into directory and configure, then make
Code: Select all
tar -xjf php-5.2.9.tar.bz2 && cd php-5.2.9 &&  ./configure  --with-apxs2=/usr/bin/apxs --with-curl --

with-curl-dir=/usr/local/lib --with-gd --with-gd-dir=/usr/local --with-gettext --with-jpeg-

dir=/usr/local/lib --with-kerberos --with-mysql --with-pear --with-png-dir=/usr/local/lib --with-xml --

with-zlib --with-zlib-dir=/usr/local/lib --with-zip --with-openssl --enable-bcmath --enable-calendar --

enable-ftp --enable-magic-quotes --enable-sockets --enable-track-vars --enable-mbstring --enable-memory-

limit --with-iconv --enable-dba --with-db4 --with-freetype-dir=/usr/include/freetype2/ --with-freetype &&

make


install
Code: Select all
make install


finish up...
Code: Select all
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

If you have a premade php.ini file replace the new with the old.
Code: Select all
cp php.ini-dist /usr/local/lib/php.ini


restart your apache
Code: Select all
/etc/init.d/httpd stop

/etc/init.d/httpd start



I had to make a how to for this, since there is not one online that i can find. this worked perfect for CentOS 5.x
Image
PRO Level 15
User avatar
Posts: 1346
Joined: Sun May 02, 2004 8:49 pm
Location: 127.0.0.1

Re: HowTo: CentOS and php GD with freetype support

Postby Grav!ty » Mon Apr 20, 2009 5:05 pm

Thanks very much for posting such a detailed and complete guide to getting this working Andrew :notworthy
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: HowTo: CentOS and php GD with freetype support

Postby c0ldfyr3 » Mon Apr 20, 2009 9:58 pm

next i am gonna get lighttpd with fastcgi and xCache to install...

i hate CentOS... :-x
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 1 guest

cron
cron