[php-maint] Bug#470483: Solution relocated

Ben Corne bcorne at infogroep.be
Tue Jan 13 20:57:07 UTC 2009


the solution link has slightly changed:
http://scarybear.net/journal/articles/view/155/

Anyways (to be sure it doesn't change again), the solution is the folowing:

Problem:
Executing `php` prints the folowing error:|
PHP Warning: PHP Startup: Unable to load dynamic library 
'/usr/lib/php5/20060613+lfs/gd.so' - /usr/lib/php5/20060613+lfs/gd.so: 
undefined symbol: gdImageCreateFromJpeg in Unknown on line 0

more specifically when processing a php page it displays the folowing:
|*Fatal error*: Call to undefined function imageCreate() 
in */home/irc/website/makeworldmap.php* on line *13*
|
Answer:
There's something wrong with gd itself,|

|/usr/lib/php5/20060613+lfs/gd.so is different from one of a clean install
It actually loads the wrong libgd, which can be found by typing `locate libgd`
We find other versions of libgd in /usr/local/lib/:
libgd.so, libgd.so.2, libgd.so.2.0.0

do the folowing things:
sudo mkdir libgd.backup
sudo mv libgd.so* libgd.backup
restart apache: sudo /etc/init.d/apache2 restart|

|
Test:
make a small file: test.php and run it
<? print_r(gd_info()); ?>

this should output information about your gd installation.

Greets, Ben
|





More information about the pkg-php-maint mailing list