Navigation |
php imagerotate function on ubuntu hardyLooks like many people are having problem with the function imagerotate from the gd library on php. Here is how I do it on my server. apt-get install build-essential will install what you need in order to compile the original version of the php-gd library. Get the sources of the version of php that you have on your server from the php.net website. wget blabla install some extra libraries needed during the compilation apt-get install libxml2 libxml2-dev libjpeg libjpeg62 libjpeg62-dev uncompress the php tar.bz2 archive tar xjvf php-5.2.4.tar.bz2 cd php5.2.4 run the configure script and make sure you enable gd as a shared library ./configure --enable-shared=gd --with-jpeg-dir compile make wait some time... locate gd.so If you don't get any answer try refreshing your locate database with updatedb In order to check if the new functions are working you can type this:
php -r "var_dump(function_exists('imagerotate'));"
php -r "var_dump(function_exists('imagecreatefromjpeg'));"
You can try with several other functions.
|
blabla
wget blabla? well that's very helpful. not everyone knows whatever you're assuming they know.
Sorry about that. I don't
Sorry about that. I don't just write for everyone. I assume you know where to download php sources if you are trying to fiddle with the said sources...
My configure line varied...
Just thought I would share my results:
--enable-shared=gd did not work for me, however --with-gd=shared did.
Ubuntu 8.10 - PHP 5.2.6 (ubuntu)