hohohoho…………………….. i finally found how to solve error in GD + php.Useally, when we try to install php + gd enabled, we will get some error, not error when we complie php or gd, but error in your web. like your image won’t display properly in your web.. why i wrote this article, because i’ve got experience. when i migrate my system from linux to freebsd, because the HD error T_T, i install php with gd. i think, it will same from the old system. but, when i finished installing php+ gd, iv got the problem. jpeg or jpg image wont display properly. my expericence is, when i try to upload a jpeg or jpg image, i ve got some error, altough the web is normal, work properly. jpeg or jpg image thumbnail view wont displayed. damn!!!!!!! i’ve install gd from the freebsd ports and compile php from source manually. hooooooooooo, then my partner check the php info. shit!!!! jpeg not enabled in php……waaaaaaaaaaaaaaaa.. what happen???? my friend told me, gd in freebsd still got some error. beuuuuuu….. ive try many times with different options in php, but still got same problem, jpeg/jpg image wont display properly. T_T…………. i finally realize i must install libpng + libjpeg manually, not from the bsd ports….. ckckcckkcckckk, just waste my time (almost 2 monhts, ive got this problem T_T). hmmmm. i must solve it!!!!! then, i remember, my students mirror still up ^_^. i try to install libjpeg and libpng manualy and gd from ports. first still error, those packets got error when i compile it. and the second. hoohohoho it works (my friend said that)….. almost 8 hours with my daemon ^_^ just to enabling GD in php in freebsd. but how i solve it??????
hmmmm……………… frist you should fetch it manually thoose packets (i install thoose packets in freebsd fresh install ^_^), here there are :
after you fetched it follow this steps :
1. you should install mysql first, if you plan your web using databases
make WITH_LINUXTHREADS=yes install clean (and so on….. i wont explain in here)
2.install httpd. im using httpd-2.x.x…….. just up to you (using httpd-2.x.x versions). i think you know how to install httpd apache server from source. i’ve explained it before
3. install your libxml2 first
tar xzvf libxml2-2.6.22.tar.gz
4. install your zlib.
tar xzvf zlib-1.2.3.tar.gz
tar xzvf libpng-1.2.9.tar.gz
cp scripts/makefile.std makefile
edit your makefile, find “prefix= ………..” (i dont remember it), change it to
6. install your jpeg library.
tar -zxvf jpegsrc.v6b.tar.gz
./configure –prefix=/usr/local/jpeg6 –enable-shared
7. install GD
make install clean
huhhhhh……… finished installing library GD support.. then, finally install your php.
just follow this steps..
tar xzvf php-5.x.x.tar.gz
./configure –prefix=/usr/local/httpd/php –with-gd –with-apxs2=/usr/local/httpd/bin/apxs –with-xml –with-mysql –with-zlib –with-jpeg-dir=/usr/local/jpeg6 –with-png-dir=/usr/local/libpng2 –disable-debug –enable-trans-sid –enable-sockets –enable-memory-limit (one line of course, i assume that you install your httpd apache server in /usr/local/httpd, and php in /usr/local/httpd/php)
then copy your php.ini in /usr/local/httpd/php/lib/
next step just adding “AddType application/x-httpd-php .php” in your httpd.conf….
just wait and see the difference……….. i check my web, hmmmm looks fine. then i asked my partner (web programer), “did the GD still error????” my partner told me “hoho, thats worksss”………….huaaahhhhhahahaha finally finish it !!!!!!!
hmmmmm……… just share my experience with the daemon ^_^ thanks to allDelta for the team works ^_^. solved one problem, another problem still wait. like Indonesian peole said, “derita tiada akhir” hahahahahhaahha.. just kidding. hope it will help you too…………