# Install build tools, debian helpers and fakeroot
apt-get install build-essential debhelper fakeroot
# Get PHP source (it should go into /usr/src)
cd /usr/src
apt-get source php5
# Install all packages required to build PHP5
apt-get build-dep php5
#Now what we need is to update compile options,
# so we need to edit debian/rules file:
cd php5-5.2.6.dfsg.1
vim debian/rules
#locate the line having "--with-gd=shared,/usr --enable-gd-native-ttf "
# replace with "--with-gd=shared --enable-gd-native-ttf "
# that's remove reference to /usr so that bundled library is used
# compile (drink some coffee, walk you dog, see the latest House episode)
dpkg-buildpackage -rfakeroot
# install the new php5-gd package
cd ..
dpkg -i php5-gd_5.2.6.dfsg.1-3ubuntu4.2_i386.deb
# finally restart apache
/etc/init.d/apache2 restart
Post being viewed right now
Item date: 10.04.2009
Views: 1472
Item date: 06.02.2009
Views: 1859
Item date: 25.09.2009
Views: 427
Item date: 05.02.2009
Views: 912
Item date: 10.04.2009
Views: 2014
Item date: 30.10.2009
Views: 6634
Item date: 16.06.2009
Views: 544
Item date: 01.01.2009
Views: 630
Item date: 24.08.2009
Views: 327
Item date: 26.09.2009
Views: 1448